Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions k8s/config/client-config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ apiVersion: v1
kind: ConfigMap
metadata:
name: client-config
namespace: space
data:
VITE_ENVIRONMENT: production
VITE_SPACE_BASE_URL: http://localhost/api/v1
1 change: 1 addition & 0 deletions k8s/config/mongodb-config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ apiVersion: v1
kind: ConfigMap
metadata:
name: mongodb-config
namespace: space
data:
DATABASE_NAME: space_db
DATABASE_PASSWORD: mongoPassword
Expand Down
1 change: 1 addition & 0 deletions k8s/config/server-config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ apiVersion: v1
kind: ConfigMap
metadata:
name: server-config
namespace: space
data:
ENVIRONMENT: production
JWT_EXPIRATION: 1d
Expand Down
1 change: 1 addition & 0 deletions k8s/load-balancer/ingress-ws.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: space-ws-ingress
namespace: space
annotations:
nginx.ingress.kubernetes.io/affinity: "ip_hash"
nginx.ingress.kubernetes.io/proxy-read-timeout: "3600"
Expand Down
1 change: 1 addition & 0 deletions k8s/load-balancer/ingress.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: space-main-ingress
namespace: space
annotations:
nginx.ingress.kubernetes.io/ssl-redirect: "false"
nginx.ingress.kubernetes.io/use-regex: "true"
Expand Down
8 changes: 8 additions & 0 deletions k8s/pods/client-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ metadata:
labels:
app: client
name: client-deployment
namespace: space
spec:
replicas: 1
selector:
Expand All @@ -21,4 +22,11 @@ spec:
envFrom:
- configMapRef:
name: client-config
resources:
requests:
cpu: "100m"
memory: "128Mi"
limits:
cpu: "500m"
memory: "256Mi"
restartPolicy: Always
1 change: 1 addition & 0 deletions k8s/pods/client-hpa.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ apiVersion: autoscaling/v2
kind: HorizontalPodAutoscaler
metadata:
name: client-hpa
namespace: space
spec:
scaleTargetRef:
apiVersion: apps/v1
Expand Down
1 change: 1 addition & 0 deletions k8s/pods/client-service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ metadata:
labels:
app: client
name: client-service
namespace: space
spec:
ports:
- name: http
Expand Down
1 change: 1 addition & 0 deletions k8s/pods/mongodb-cm1-configmap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ data:
echo "Mongo users created."
kind: ConfigMap
metadata:
namespace: space
annotations:
use-subpath: "true"
labels:
Expand Down
1 change: 1 addition & 0 deletions k8s/pods/mongodb-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ metadata:
labels:
app: mongodb
name: mongodb-deployment
namespace: space
spec:
replicas: 1
selector:
Expand Down
1 change: 1 addition & 0 deletions k8s/pods/mongodb-pvc.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ metadata:
labels:
app: mongodb
name: mongodb-pvc
namespace: space
spec:
accessModes:
- ReadWriteOnce
Expand Down
1 change: 1 addition & 0 deletions k8s/pods/mongodb-service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ metadata:
labels:
app: mongodb
name: mongodb-service
namespace: space
spec:
ports:
- port: 27017
Expand Down
1 change: 1 addition & 0 deletions k8s/pods/redis-data-persistentvolumeclaim.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ metadata:
labels:
io.kompose.service: redis-data
name: redis-data
namespace: space
spec:
accessModes:
- ReadWriteOnce
Expand Down
8 changes: 8 additions & 0 deletions k8s/pods/redis-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ metadata:
labels:
app: redis
name: redis-deployment
namespace: space
spec:
replicas: 1
selector:
Expand Down Expand Up @@ -33,6 +34,13 @@ spec:
volumeMounts:
- mountPath: /data
name: redis-data
resources:
requests:
cpu: "100m"
memory: "128Mi"
limits:
cpu: "500m"
memory: "256Mi"
restartPolicy: Always
volumes:
- name: redis-data
Expand Down
1 change: 1 addition & 0 deletions k8s/pods/redis-hpa.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ apiVersion: autoscaling/v2
kind: HorizontalPodAutoscaler
metadata:
name: redis-hpa
namespace: space
spec:
scaleTargetRef:
apiVersion: apps/v1
Expand Down
1 change: 1 addition & 0 deletions k8s/pods/redis-service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ metadata:
labels:
app: redis
name: redis-service
namespace: space
spec:
ports:
- port: 6379
Expand Down
8 changes: 8 additions & 0 deletions k8s/pods/server-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ metadata:
labels:
app: server
name: server-deployment
namespace: space
spec:
replicas: 3
selector:
Expand All @@ -23,6 +24,13 @@ spec:
name: server-config
image: space-api-space-server
imagePullPolicy: IfNotPresent
resources:
requests:
cpu: "100m"
memory: "128Mi"
limits:
cpu: "500m"
memory: "256Mi"
livenessProbe:
exec:
command:
Expand Down
1 change: 1 addition & 0 deletions k8s/pods/server-hpa.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ apiVersion: autoscaling/v2
kind: HorizontalPodAutoscaler
metadata:
name: api-hpa
namespace: space
spec:
scaleTargetRef:
apiVersion: apps/v1
Expand Down
1 change: 1 addition & 0 deletions k8s/pods/server-service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ metadata:
labels:
app: server
name: server-service
namespace: space
spec:
ports:
- name: http
Expand Down
1 change: 1 addition & 0 deletions k8s/pods/space-statics-persistentvolumeclaim.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ metadata:
labels:
io.kompose.service: space-statics
name: space-statics
namespace: space
spec:
accessModes:
- ReadWriteOnce
Expand Down
Loading