Compare commits

..

2 Commits

Author SHA1 Message Date
274086358e
Rename project to kipunji
Some checks failed
Gitea Actions Demo / test (push) Blocked by required conditions
Gitea Actions Demo / release-image (push) Blocked by required conditions
Gitea Actions Demo / lint (push) Has been cancelled
2024-08-24 10:40:49 -05:00
e570a2e3c8
Add endpoint for chunked transfer
All checks were successful
Gitea Actions Demo / lint (push) Successful in 1m22s
Gitea Actions Demo / test (push) Successful in 1m20s
Gitea Actions Demo / release-image (push) Successful in 1m14s
2024-08-20 20:02:21 -05:00
12 changed files with 36 additions and 27 deletions

9
app.rb
View File

@ -363,3 +363,12 @@ route :delete, :get, :patch, :post, :put, "/status/:code" do
code = Integer(params[:code]) code = Integer(params[:code])
status code if code.between? 100, 599 status code if code.between? 100, 599
end end
get "/chunked/:delay" do
delay = Float(params[:delay])
stream do |out|
out << "Hello, world!\n"
sleep delay
out << "Hello, world!\n"
end
end

View File

@ -2,8 +2,8 @@
apiVersion: v1 apiVersion: v1
kind: ConfigMap kind: ConfigMap
metadata: metadata:
name: toy-configmap name: kipunji-configmap
namespace: toy namespace: kipunji
annotations: annotations:
reloader.stakater.com/match: "true" reloader.stakater.com/match: "true"
data: data:

View File

@ -2,7 +2,7 @@
apiVersion: networking.k8s.io/v1 apiVersion: networking.k8s.io/v1
kind: Ingress kind: Ingress
metadata: metadata:
name: toy-ingress name: kipunji-ingress
spec: spec:
rules: rules:
- http: - http:
@ -11,6 +11,6 @@ spec:
pathType: Prefix pathType: Prefix
backend: backend:
service: service:
name: toy name: kipunji
port: port:
name: web name: web

View File

@ -1,7 +1,7 @@
--- ---
apiVersion: kustomize.config.k8s.io/v1beta1 apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization kind: Kustomization
namespace: toy namespace: kipunji
resources: resources:
- secret.yaml - secret.yaml
- configmap.yaml - configmap.yaml

View File

@ -2,7 +2,7 @@
apiVersion: argoproj.io/v1alpha1 apiVersion: argoproj.io/v1alpha1
kind: Rollout kind: Rollout
metadata: metadata:
name: toy name: kipunji
annotations: annotations:
reloader.stakater.com/auto: "true" reloader.stakater.com/auto: "true"
spec: spec:
@ -21,15 +21,15 @@ spec:
revisionHistoryLimit: 2 revisionHistoryLimit: 2
selector: selector:
matchLabels: matchLabels:
app: toy app: kipunji
template: template:
metadata: metadata:
labels: labels:
app: toy app: kipunji
spec: spec:
containers: containers:
- name: toy - name: kipunji
image: git.kill0.net/ryanc/toy:latest image: git.kill0.net/ryanc/kipunji:latest
imagePullPolicy: Always imagePullPolicy: Always
ports: ports:
- name: web - name: web
@ -38,12 +38,12 @@ spec:
- name: SESSION_SECRET - name: SESSION_SECRET
valueFrom: valueFrom:
secretKeyRef: secretKeyRef:
name: toy-session-secret name: kipunji-session-secret
key: session_secret key: session_secret
optional: true optional: true
envFrom: envFrom:
- configMapRef: - configMapRef:
name: toy-configmap name: kipunji-configmap
livenessProbe: livenessProbe:
httpGet: httpGet:
path: /livez path: /livez

View File

@ -3,8 +3,8 @@ apiVersion: bitnami.com/v1alpha1
kind: SealedSecret kind: SealedSecret
metadata: metadata:
creationTimestamp: null creationTimestamp: null
name: toy-session-secret name: kipunji-session-secret
namespace: toy namespace: kipunji
annotations: annotations:
reloader.stakater.com/match: "true" reloader.stakater.com/match: "true"
spec: spec:
@ -13,5 +13,5 @@ spec:
template: template:
metadata: metadata:
creationTimestamp: null creationTimestamp: null
name: toy-session-secret name: kipunji-session-secret
namespace: toy namespace: kipunji

View File

@ -2,7 +2,7 @@
apiVersion: v1 apiVersion: v1
kind: Service kind: Service
metadata: metadata:
name: toy name: kipunji
spec: spec:
ports: ports:
@ -10,4 +10,4 @@ spec:
port: 80 port: 80
targetPort: web targetPort: web
selector: selector:
app: toy app: kipunji

View File

@ -1,7 +1,7 @@
--- ---
apiVersion: kustomize.config.k8s.io/v1beta1 apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization kind: Kustomization
namespace: toy namespace: kipunji
resources: resources:
- namespace.yaml - namespace.yaml
- ./app - ./app

View File

@ -2,19 +2,19 @@
kind: Deployment kind: Deployment
apiVersion: apps/v1 apiVersion: apps/v1
metadata: metadata:
name: toy-memcached name: kipunji-memcached
spec: spec:
selector: selector:
matchLabels: matchLabels:
app: toy-memcached app: kipunji-memcached
template: template:
metadata: metadata:
labels: labels:
app: toy-memcached app: kipunji-memcached
spec: spec:
containers: containers:
- name: toy-memcached - name: kipunji-memcached
image: memcached:latest image: memcached:latest
ports: ports:
- name: memcached - name: memcached

View File

@ -1,7 +1,7 @@
--- ---
apiVersion: kustomize.config.k8s.io/v1beta1 apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization kind: Kustomization
namespace: toy namespace: kipunji
resources: resources:
- deployment.yaml - deployment.yaml
- services.yaml - services.yaml

View File

@ -2,7 +2,7 @@
apiVersion: v1 apiVersion: v1
kind: Service kind: Service
metadata: metadata:
name: toy-memcached name: kipunji-memcached
spec: spec:
ports: ports:
@ -10,4 +10,4 @@ spec:
port: 11211 port: 11211
targetPort: memcached targetPort: memcached
selector: selector:
app: toy-memcached app: kipunji-memcached

View File

@ -2,5 +2,5 @@
apiVersion: v1 apiVersion: v1
kind: Namespace kind: Namespace
metadata: metadata:
name: toy name: kipunji