K8S Config init
All checks were successful
CI Pipeline for the Go API / Go Vet (basic static check) (push) Successful in 9s
CI Pipeline for the Go API / Kubernetes Smoke Test (push) Successful in 5s
CI Pipeline for the Go API / Docker Image Build Test (push) Successful in 17s
CI Pipeline for the Go API / Go Build & Cross-Compile (push) Successful in 30s
All checks were successful
CI Pipeline for the Go API / Go Vet (basic static check) (push) Successful in 9s
CI Pipeline for the Go API / Kubernetes Smoke Test (push) Successful in 5s
CI Pipeline for the Go API / Docker Image Build Test (push) Successful in 17s
CI Pipeline for the Go API / Go Build & Cross-Compile (push) Successful in 30s
This commit is contained in:
32
k8s/deployment.yaml
Normal file
32
k8s/deployment.yaml
Normal file
@@ -0,0 +1,32 @@
|
||||
apiVersion: apps/v1
|
||||
|
||||
kind: Deployment
|
||||
|
||||
metadata:
|
||||
name: go-api
|
||||
labels:
|
||||
app: go-api
|
||||
|
||||
spec:
|
||||
replicas: 2
|
||||
|
||||
selector:
|
||||
matchLabels:
|
||||
app: go-api
|
||||
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: go-api
|
||||
|
||||
spec:
|
||||
containers:
|
||||
- name: go-api
|
||||
image: zomborip/go-api:latest
|
||||
ports:
|
||||
- containerPort: 8080
|
||||
resources:
|
||||
requests:
|
||||
cpu: 100m
|
||||
limits:
|
||||
cpu: 500m
|
||||
19
k8s/service.yaml
Normal file
19
k8s/service.yaml
Normal file
@@ -0,0 +1,19 @@
|
||||
apiVersion: v1
|
||||
|
||||
kind: Service
|
||||
|
||||
metadata:
|
||||
name: go-api
|
||||
|
||||
spec:
|
||||
selector:
|
||||
app: go-api
|
||||
|
||||
ports:
|
||||
- protocol: TCP
|
||||
port: 8080
|
||||
targetPort: 8080
|
||||
nodePort: 30081
|
||||
|
||||
type: NodePort
|
||||
|
||||
Reference in New Issue
Block a user