release
This commit is contained in:
parent
27af87cf7e
commit
b60030173b
12
deployment/manifest/configmap/frontend-configmap.yaml
Normal file
12
deployment/manifest/configmap/frontend-configmap.yaml
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: ConfigMap
|
||||||
|
metadata:
|
||||||
|
name: frontend-config
|
||||||
|
namespace: dg0400-lifesub-ns
|
||||||
|
data:
|
||||||
|
runtime-env.js: |
|
||||||
|
window.__runtime_config__ = {
|
||||||
|
MEMBER_URL: 'http://dg0400.20.214.196.128.nip.io/api/auth',
|
||||||
|
MYSUB_URL: 'http://dg0400.20.214.196.128.nip.io/api/mysub',
|
||||||
|
RECOMMEND_URL: 'http://dg0400.20.214.196.128.nip.io/api/recommend'
|
||||||
|
};
|
||||||
96
deployment/manifest/deploy.yaml
Normal file
96
deployment/manifest/deploy.yaml
Normal file
@ -0,0 +1,96 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: ConfigMap
|
||||||
|
metadata:
|
||||||
|
name: frontend-config
|
||||||
|
namespace: dg0400-lifesub-ns
|
||||||
|
data:
|
||||||
|
runtime-env.js: |
|
||||||
|
window.__runtime_config__ = {
|
||||||
|
MEMBER_URL: 'http://dg0400.20.214.196.128.nip.io/api/auth',
|
||||||
|
MYSUB_URL: 'http://dg0400.20.214.196.128.nip.io/api/mysub',
|
||||||
|
RECOMMEND_URL: 'http://dg0400.20.214.196.128.nip.io/api/recommend'
|
||||||
|
};
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: lifesub-web
|
||||||
|
namespace: dg0400-lifesub-ns
|
||||||
|
labels:
|
||||||
|
app: lifesub-web
|
||||||
|
spec:
|
||||||
|
replicas: 2
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
app: lifesub-web
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
app: lifesub-web
|
||||||
|
spec:
|
||||||
|
imagePullSecrets:
|
||||||
|
- name: acr-secret
|
||||||
|
containers:
|
||||||
|
- name: lifesub-web
|
||||||
|
image: dg0400cr.azurecr.io/dg0400/lifesub-web:1.0.0
|
||||||
|
imagePullPolicy: Always
|
||||||
|
ports:
|
||||||
|
- containerPort: 18080
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
cpu: 256m
|
||||||
|
memory: 256Mi
|
||||||
|
limits:
|
||||||
|
cpu: 1024m
|
||||||
|
memory: 1024Mi
|
||||||
|
volumeMounts:
|
||||||
|
- name: runtime-config
|
||||||
|
mountPath: /usr/share/nginx/html/runtime-env.js
|
||||||
|
subPath: runtime-env.js
|
||||||
|
volumes:
|
||||||
|
- name: runtime-config
|
||||||
|
configMap:
|
||||||
|
name: frontend-config
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: lifesub-web-service
|
||||||
|
namespace: dg0400-lifesub-ns
|
||||||
|
labels:
|
||||||
|
app: lifesub-web
|
||||||
|
spec:
|
||||||
|
type: ClusterIP
|
||||||
|
ports:
|
||||||
|
- port: 80
|
||||||
|
targetPort: 18080
|
||||||
|
protocol: TCP
|
||||||
|
selector:
|
||||||
|
app: lifesub-web
|
||||||
|
|
||||||
|
---
|
||||||
|
apiVersion: networking.k8s.io/v1
|
||||||
|
kind: Ingress
|
||||||
|
metadata:
|
||||||
|
name: frontend-ingress
|
||||||
|
namespace: dg0400-lifesub-ns
|
||||||
|
annotations:
|
||||||
|
kubernetes.io/ingress.class: nginx
|
||||||
|
nginx.ingress.kubernetes.io/rewrite-target: /
|
||||||
|
spec:
|
||||||
|
rules:
|
||||||
|
- host: dg0400.20.249.113.122.nip.io
|
||||||
|
http:
|
||||||
|
paths:
|
||||||
|
- path: /
|
||||||
|
pathType: Prefix
|
||||||
|
backend:
|
||||||
|
service:
|
||||||
|
name: lifesub-web-service
|
||||||
|
port:
|
||||||
|
number: 80
|
||||||
|
|
||||||
@ -1,8 +1,10 @@
|
|||||||
# lifesub-web/deployment/manifest/deployments/hiondal-web-deployment.yaml
|
|
||||||
apiVersion: apps/v1
|
apiVersion: apps/v1
|
||||||
kind: Deployment
|
kind: Deployment
|
||||||
metadata:
|
metadata:
|
||||||
name: lifesub-web
|
name: lifesub-web
|
||||||
|
namespace: dg0400-lifesub-ns
|
||||||
|
labels:
|
||||||
|
app: lifesub-web
|
||||||
spec:
|
spec:
|
||||||
replicas: 1
|
replicas: 1
|
||||||
selector:
|
selector:
|
||||||
@ -14,10 +16,10 @@ spec:
|
|||||||
app: lifesub-web
|
app: lifesub-web
|
||||||
spec:
|
spec:
|
||||||
imagePullSecrets:
|
imagePullSecrets:
|
||||||
- name: dockerhub
|
- name: acr-secret
|
||||||
containers:
|
containers:
|
||||||
- name: lifesub-web
|
- name: lifesub-web
|
||||||
image: dg0200cr.azurecr.io/lifesub/lifesub-web:1.0.0
|
image: acrdigitalgarage01.azurecr.io/dg0400/lifesub-web:1.0.0
|
||||||
imagePullPolicy: Always
|
imagePullPolicy: Always
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 18080
|
- containerPort: 18080
|
||||||
@ -28,4 +30,11 @@ spec:
|
|||||||
limits:
|
limits:
|
||||||
cpu: 1024m
|
cpu: 1024m
|
||||||
memory: 1024Mi
|
memory: 1024Mi
|
||||||
|
volumeMounts:
|
||||||
|
- name: runtime-config
|
||||||
|
mountPath: /usr/share/nginx/html/runtime-env.js
|
||||||
|
subPath: runtime-env.js
|
||||||
|
volumes:
|
||||||
|
- name: runtime-config
|
||||||
|
configMap:
|
||||||
|
name: frontend-config
|
||||||
15
deployment/manifest/service/frontend-service.yaml
Normal file
15
deployment/manifest/service/frontend-service.yaml
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: lifesub-web-service
|
||||||
|
namespace: dg0400-lifesub-ns
|
||||||
|
labels:
|
||||||
|
app: lifesub-web
|
||||||
|
spec:
|
||||||
|
type: LoadBalancer
|
||||||
|
ports:
|
||||||
|
- port: 80
|
||||||
|
targetPort: 18080
|
||||||
|
protocol: TCP
|
||||||
|
selector:
|
||||||
|
app: lifesub-web
|
||||||
@ -1,12 +0,0 @@
|
|||||||
# lifesub-web/deployment/manifest/services/lifesub-web-service.yaml
|
|
||||||
apiVersion: v1
|
|
||||||
kind: Service
|
|
||||||
metadata:
|
|
||||||
name: lifesub-web
|
|
||||||
spec:
|
|
||||||
selector:
|
|
||||||
app: lifesub-web
|
|
||||||
ports:
|
|
||||||
- port: 80
|
|
||||||
targetPort: 18080
|
|
||||||
type: LoadBalancer
|
|
||||||
Loading…
x
Reference in New Issue
Block a user