mirror of
https://github.com/Dannecron/netology-devops-gw-infra.git
synced 2025-12-25 15:22:36 +03:00
[stage-3] fix values for simple-app and atlantis
This commit is contained in:
@@ -7,7 +7,7 @@ metadata:
|
|||||||
service: atlantis
|
service: atlantis
|
||||||
name: {{ .Chart.Name }}-{{ .Values.environment }}
|
name: {{ .Chart.Name }}-{{ .Values.environment }}
|
||||||
spec:
|
spec:
|
||||||
replicas: {{ .Values.atlantis.replicasCount }}
|
replicas: {{ .Values.replicasCount }}
|
||||||
selector:
|
selector:
|
||||||
matchLabels:
|
matchLabels:
|
||||||
app: {{ .Chart.Name }}-{{ .Values.environment }}
|
app: {{ .Chart.Name }}-{{ .Values.environment }}
|
||||||
@@ -27,7 +27,7 @@ spec:
|
|||||||
containerPort: 4141
|
containerPort: 4141
|
||||||
env:
|
env:
|
||||||
- name: ATLANTIS_GH_USER
|
- name: ATLANTIS_GH_USER
|
||||||
value: {{ .Values.atlantis.config.github.user }}
|
value: {{ .Values.config.github.user }}
|
||||||
- name: ATLANTIS_GH_TOKEN
|
- name: ATLANTIS_GH_TOKEN
|
||||||
valueFrom:
|
valueFrom:
|
||||||
secretKeyRef:
|
secretKeyRef:
|
||||||
@@ -39,11 +39,11 @@ spec:
|
|||||||
name: {{ .Chart.Name }}-{{ .Values.environment }}
|
name: {{ .Chart.Name }}-{{ .Values.environment }}
|
||||||
key: github_secret
|
key: github_secret
|
||||||
- name: ATLANTIS_REPO_ALLOWLIST
|
- name: ATLANTIS_REPO_ALLOWLIST
|
||||||
value: {{ toYaml (.Values.atlantis.config.orgAllowlist) }}
|
value: {{ toYaml (.Values.config.orgAllowlist) }}
|
||||||
- name: ATLANTIS_ALLOW_COMMANDS
|
- name: ATLANTIS_ALLOW_COMMANDS
|
||||||
value: {{ .Values.atlantis.config.allowCommands }}
|
value: {{ .Values.config.allowCommands }}
|
||||||
resources:
|
resources:
|
||||||
{{- toYaml .Values.atlantis.resources | nindent 12 }}
|
{{- toYaml .Values.resources | nindent 12 }}
|
||||||
livenessProbe:
|
livenessProbe:
|
||||||
httpGet:
|
httpGet:
|
||||||
path: /healthz
|
path: /healthz
|
||||||
|
|||||||
@@ -4,5 +4,5 @@ kind: Secret
|
|||||||
metadata:
|
metadata:
|
||||||
name: {{ .Chart.Name }}-{{ .Values.environment }}
|
name: {{ .Chart.Name }}-{{ .Values.environment }}
|
||||||
data:
|
data:
|
||||||
github_token: {{ .Values.atlantis.config.github.token | b64enc }}
|
github_token: {{ .Values.config.github.token | b64enc }}
|
||||||
github_secret: {{ .Values.atlantis.config.github.secret | b64enc }}
|
github_secret: {{ .Values.config.github.secret | b64enc }}
|
||||||
|
|||||||
@@ -3,16 +3,8 @@ environment: production
|
|||||||
image:
|
image:
|
||||||
name: ghcr.io/runatlantis/atlantis
|
name: ghcr.io/runatlantis/atlantis
|
||||||
|
|
||||||
atlantis:
|
|
||||||
config:
|
|
||||||
orgAllowlist: github.com/Dannecron/*
|
|
||||||
github:
|
|
||||||
user: personal-access-token-name
|
|
||||||
token: personal-access-token-secret
|
|
||||||
secret: webhook-secret
|
|
||||||
allowCommands: "version,plan,state"
|
|
||||||
|
|
||||||
replicasCount: 1
|
replicasCount: 1
|
||||||
|
|
||||||
resources:
|
resources:
|
||||||
requests:
|
requests:
|
||||||
memory: 512Mi
|
memory: 512Mi
|
||||||
@@ -20,3 +12,11 @@ atlantis:
|
|||||||
limits:
|
limits:
|
||||||
memory: 1Gi
|
memory: 1Gi
|
||||||
cpu: 100m
|
cpu: 100m
|
||||||
|
|
||||||
|
config:
|
||||||
|
orgAllowlist: github.com/Dannecron/*
|
||||||
|
github:
|
||||||
|
user: personal-access-token-name
|
||||||
|
token: personal-access-token-secret
|
||||||
|
secret: webhook-secret
|
||||||
|
allowCommands: "version,plan,state"
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
---------------------------------------------------------
|
---------------------------------------------------------
|
||||||
|
|
||||||
Content of NOTES.txt appears after deploy.
|
Test application.
|
||||||
Deployed version {{ .Chart.AppVersion }}.
|
Deployed version {{ .Values.image.tag | default .Chart.AppVersion }}.
|
||||||
|
|
||||||
---------------------------------------------------------
|
---------------------------------------------------------
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ metadata:
|
|||||||
service: application
|
service: application
|
||||||
name: {{ .Chart.Name }}-{{ .Values.environment }}-application
|
name: {{ .Chart.Name }}-{{ .Values.environment }}-application
|
||||||
spec:
|
spec:
|
||||||
replicas: {{ .Values.application.replicasCount }}
|
replicas: {{ .Values.replicasCount }}
|
||||||
selector:
|
selector:
|
||||||
matchLabels:
|
matchLabels:
|
||||||
app: {{ .Chart.Name }}-{{ .Values.environment }}
|
app: {{ .Chart.Name }}-{{ .Values.environment }}
|
||||||
@@ -19,12 +19,12 @@ spec:
|
|||||||
service: application
|
service: application
|
||||||
spec:
|
spec:
|
||||||
containers:
|
containers:
|
||||||
- image: {{ .Values.image.name }}:{{ .Chart.AppVersion }}
|
- image: {{ .Values.image.name }}:{{ .Values.image.tag | default .Chart.AppVersion }}
|
||||||
imagePullPolicy: Always
|
imagePullPolicy: Always
|
||||||
name: application
|
name: application
|
||||||
ports:
|
ports:
|
||||||
- name: web
|
- name: web
|
||||||
containerPort: 80
|
containerPort: 80
|
||||||
resources:
|
resources:
|
||||||
{{- toYaml .Values.application.resources | nindent 12 }}
|
{{- toYaml .Values.resources | nindent 12 }}
|
||||||
terminationGracePeriodSeconds: 30
|
terminationGracePeriodSeconds: 30
|
||||||
|
|||||||
@@ -2,8 +2,8 @@ environment: production
|
|||||||
|
|
||||||
image:
|
image:
|
||||||
name: dannecron/parcel-example-neko
|
name: dannecron/parcel-example-neko
|
||||||
|
tag:
|
||||||
|
|
||||||
application:
|
|
||||||
replicasCount: 1
|
replicasCount: 1
|
||||||
resources:
|
resources:
|
||||||
limits:
|
limits:
|
||||||
|
|||||||
@@ -84,7 +84,7 @@ ansible-playbook -i ansible/kubectl_init kubectl_init.yml
|
|||||||
* [atlantis](https://www.runatlantis.io)
|
* [atlantis](https://www.runatlantis.io)
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
helm upgrade --set "atlantis.config.github.user=<access_token>" --set "atlantis.config.github.token=<token_secret>" --set "atlantis.config.github.secret=<webhook_secret>" atlantis k8s/helm/atlantis
|
helm install --set "atlantis.config.github.user=<access_token>" --set "atlantis.config.github.token=<token_secret>" --set "atlantis.config.github.secret=<webhook_secret>" atlantis k8s/helm/atlantis
|
||||||
```
|
```
|
||||||
|
|
||||||
где `<access_token>`, `<token_secret>` - это данные персонального access-токена, созданного на github,
|
где `<access_token>`, `<token_secret>` - это данные персонального access-токена, созданного на github,
|
||||||
|
|||||||
Reference in New Issue
Block a user