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])
status code if code.between? 100, 599
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
kind: ConfigMap
metadata:
name: toy-configmap
namespace: toy
name: kipunji-configmap
namespace: kipunji
annotations:
reloader.stakater.com/match: "true"
data:

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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