Skip to content

Commit

Permalink
Adding deployment structure
Browse files Browse the repository at this point in the history
  • Loading branch information
soaand01 committed Mar 8, 2023
1 parent 1e1ad12 commit 42bf4bb
Show file tree
Hide file tree
Showing 3 changed files with 49 additions and 0 deletions.
21 changes: 21 additions & 0 deletions deployment/nginx-deployment.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: nginx-deployment
labels:
app: nginx
spec:
replicas: 5
selector:
matchLabels:
app: nginx
template:
metadata:
labels:
app: nginx
spec:
containers:
- name: nginx
image: nginx:latest
ports:
- containerPort: 80
17 changes: 17 additions & 0 deletions deployment/nginx-ingress.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: nginx-ingress
annotations:
kubernetes.io/ingress.class: azure/application-gateway
spec:
rules:
- http:
paths:
- path: /
backend:
service:
name: nginx-service
port:
number: 80
pathType: Prefix
11 changes: 11 additions & 0 deletions deployment/nginx-service.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
apiVersion: v1
kind: Service
metadata:
name: nginx-service
spec:
selector:
app: nginx
ports:
- protocol: TCP
port: 8080
targetPort: 80

0 comments on commit 42bf4bb

Please sign in to comment.