Skip to content

Instantly share code, notes, and snippets.

View rahul0208's full-sized avatar

Rahul Sharma rahul0208

View GitHub Profile
@rahul0208
rahul0208 / app.yaml
Created July 27, 2021 16:21
Conjur Configuration
apiVersion: v1
kind: Service
metadata:
name: test-app-secretless
labels:
app: test-app-secretless
spec:
ports:
- protocol: TCP
port: 8080
@rahul0208
rahul0208 / collab.md
Created January 30, 2020 08:09
collab application

Collab

We want to build a team calendar to meet the following objectives .

  • It should allow a user to create a calendar and share it with multiple users.
  • As a user I can add a calendar and control access of different users.
  • A user will have different access rights (readonly / write / full-access)
  • A user can add / delete /update events in the calendar(s) available.
  • When an event is added the calendar should validate if there are overlapping events and should alter the user.
  • Each of the calendar is available at a unique URL
  • Each calendar can be de-activated by an admin user. The deactivated calendar will not be accessible to the users.
  • The application has a browser based UI to which can show the calendar.
# Collab
We want to build a team calendar to meet the following objectives .
- It should allow a user to create a calendar and share it with multiple users.
- As a user I can add a calendar and control access of different users.
- A user will have different access rights (readonly / write / full-access)
- A user can add / delete /update events in the calendar(s) available.
- When an event is added the calendar should validate if there are overlapping events and should alter the user.
- Each of the calendar is available at a unique URL
- Each calendar can be de-activated by an admin user. The deactivated calendar will not be accessible to the users.
- The application has a browser based UI to which can show the calendar.
[2019-11-20T09:24:11.082Z] "GET / HTTP/1.1" 200 - "-" "-" 0 61 4 1 "10.1.83.1" "curl/7.58.0" "b17ca502-5c1f-93f6-bb09-f6636f0fb77e" "gs.xebia.com" "127.0.0.1:5000" inbound|80|http-gsservice|gsservice.default.svc.cluster.local - 10.1.83.52:5000 10.1.83.1:0 -
%UPSTREAM_CLUSTER% 127.0.0.1:5000
%UPSTREAM_LOCAL_ADDRESS% inbound|80|http-gsservice|gsservice.default.svc.cluster.local
%DOWNSTREAM_LOCAL_ADDRESS% -
%DOWNSTREAM_REMOTE_ADDRESS% 10.1.83.52:5000
%REQUESTED_SERVER_NAME% 10.1.83.1:0
apiVersion: v1
kind: Service
metadata:
name: gsservice
spec:
selector:
app: app
ports:
- name: http-gsservice
protocol: TCP
from flask import Flask
import datetime
import time
gs = Flask(__start__)
@app.route("/")
def service():
dt = datetime.datetime.now()
return "V1 : Hi time is " + str(dt)
if __start__ == "__service__":
gs.run(host='0.0.0.0')