Skip to content

Commit 95da540

Browse files
committed
Add kubernetes deployment
1 parent db80625 commit 95da540

File tree

1 file changed

+55
-0
lines changed

1 file changed

+55
-0
lines changed

deployment/k8s/shiny-service.yml

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
kind: Service
2+
apiVersion: v1
3+
metadata:
4+
name: shiny-service
5+
namespace: eoda
6+
labels:
7+
app: shiny-app
8+
spec:
9+
selector:
10+
app: shiny-app
11+
ports:
12+
- port: 80
13+
protocol: TCP
14+
targetPort: 3333
15+
type: ClusterIP
16+
---
17+
apiVersion: apps/v1
18+
kind: Deployment
19+
metadata:
20+
name: shiny-deployment
21+
namespace: eoda
22+
spec:
23+
selector:
24+
matchLabels:
25+
app: shiny-app
26+
replicas: 2
27+
template:
28+
metadata:
29+
labels:
30+
app: shiny-app
31+
spec:
32+
containers:
33+
- name: shiny-app
34+
image: ghcr.io/eoda-dev/shiny-meets-fastapi:latest
35+
# command: [".venv/bin/uvicorn"]
36+
# args: ["--host", "0.0.0.0", "--port", "3333" , "app:app"]
37+
ports:
38+
- containerPort: 3333
39+
---
40+
apiVersion: networking.k8s.io/v1
41+
kind: Ingress
42+
metadata:
43+
namespace: eoda
44+
name: shiny-ingress
45+
spec:
46+
rules:
47+
- http:
48+
paths:
49+
- path: /
50+
pathType: Prefix
51+
backend:
52+
service:
53+
name: shiny-service
54+
port:
55+
number: 80

0 commit comments

Comments
 (0)