mirror of
https://codeup.aliyun.com/64f7d6b8ce01efaafef1e678/coal/coal.git
synced 2026-01-25 07:46:40 +08:00
完善k8s文件
This commit is contained in:
@@ -17,22 +17,21 @@ commonLabels:
|
||||
nameSuffix: -master
|
||||
|
||||
|
||||
replacements:
|
||||
- source:
|
||||
kind: Service
|
||||
name: pg-master
|
||||
targets:
|
||||
- select:
|
||||
kind: Deployment
|
||||
name: coal-api
|
||||
fieldPaths:
|
||||
- spec.template.spec.containers.[name=coal-api].env.[name=PG_HOST].value
|
||||
- source:
|
||||
kind: Service
|
||||
name: redis-master
|
||||
targets:
|
||||
- select:
|
||||
kind: Deployment
|
||||
name: coal-api
|
||||
fieldPaths:
|
||||
- spec.template.spec.containers.[name=coal-api].env.[name=REDIS_HOST].value
|
||||
patchesStrategicMerge:
|
||||
- |
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: coal-api
|
||||
spec:
|
||||
template:
|
||||
spec:
|
||||
containers:
|
||||
- name: coal-api
|
||||
env:
|
||||
- name: PG_HOST
|
||||
value: "pg-master.coal.svc.cluster.local"
|
||||
- name: REDIS_HOST
|
||||
value: "redis-master.coal.svc.cluster.local"
|
||||
- name: SPRING_PROFILES_ACTIVE
|
||||
value: "master"
|
||||
|
||||
Reference in New Issue
Block a user