Skip to content

Commit

Permalink
Merge pull request teamhephy#51 from jianxiaoguo/main
Browse files Browse the repository at this point in the history
chore(chart): modify the problem of using buildpack and pretty pods list print
  • Loading branch information
duanhongyi authored Jul 26, 2021
2 parents 8ed2860 + cdea890 commit 2ee14b3
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 12 deletions.
4 changes: 0 additions & 4 deletions charts/controller/templates/controller-celery.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ spec:
- celery -A api worker -Q priority.high --autoscale=32,1 --loglevel=WARNING
{{- include "controller.limits" . | indent 10 }}
{{- include "controller.envs" . | indent 10 }}
{{- include "controller.volumeMounts" . | indent 10 }}
- name: drycc-controller-celery-middle
image: {{.Values.image_registry}}/{{.Values.org}}/controller:{{.Values.image_tag}}
imagePullPolicy: {{.Values.image_pull_policy}}
Expand All @@ -44,7 +43,6 @@ spec:
- celery -A api worker -Q priority.middle --autoscale=16,1 --loglevel=WARNING
{{- include "controller.limits" . | indent 10 }}
{{- include "controller.envs" . | indent 10 }}
{{- include "controller.volumeMounts" . | indent 10 }}
- name: drycc-controller-celery-low
image: {{.Values.image_registry}}/{{.Values.org}}/controller:{{.Values.image_tag}}
imagePullPolicy: {{.Values.image_pull_policy}}
Expand All @@ -55,5 +53,3 @@ spec:
- celery -A api worker -Q priority.low --autoscale=8,1 --loglevel=WARNING
{{- include "controller.limits" . | indent 10 }}
{{- include "controller.envs" . | indent 10 }}
{{- include "controller.volumeMounts" . | indent 10 }}
{{- include "controller.volumes" . | indent 6 }}
6 changes: 0 additions & 6 deletions charts/controller/templates/controller-cronjob-daily.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ spec:
args:
- python /app/manage.py load_db_state_to_k8s
{{- include "controller.envs" . | indent 12 }}
{{- include "controller.volumeMounts" . | indent 12 }}
- image: {{.Values.image_registry}}/{{.Values.org}}/controller:{{.Values.image_tag}}
imagePullPolicy: {{.Values.pull_policy}}
name: drycc-controller-measure-app
Expand All @@ -36,7 +35,6 @@ spec:
args:
- python -u /app/manage.py measure_app
{{- include "controller.envs" . | indent 12 }}
{{- include "controller.volumeMounts" . | indent 12 }}
- image: {{.Values.image_registry}}/{{.Values.org}}/controller:{{.Values.image_tag}}
imagePullPolicy: {{.Values.pull_policy}}
name: drycc-controller-measure-config
Expand All @@ -46,7 +44,6 @@ spec:
args:
- python -u /app/manage.py measure_config
{{- include "controller.envs" . | indent 12 }}
{{- include "controller.volumeMounts" . | indent 12 }}
- image: {{.Values.image_registry}}/{{.Values.org}}/controller:{{.Values.image_tag}}
imagePullPolicy: {{.Values.pull_policy}}
name: drycc-controller-measure-resources
Expand All @@ -56,7 +53,6 @@ spec:
args:
- python -u /app/manage.py measure_resources
{{- include "controller.envs" . | indent 12 }}
{{- include "controller.volumeMounts" . | indent 12 }}
- image: {{.Values.image_registry}}/{{.Values.org}}/controller:{{.Values.image_tag}}
imagePullPolicy: {{.Values.pull_policy}}
name: drycc-controller-measure-volumes
Expand All @@ -66,5 +62,3 @@ spec:
args:
- python -u /app/manage.py measure_volumes
{{- include "controller.envs" . | indent 12 }}
{{- include "controller.volumeMounts" . | indent 12 }}
{{- include "controller.volumes" . | indent 10 }}
2 changes: 0 additions & 2 deletions charts/controller/templates/controller-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -44,5 +44,3 @@ spec:
name: http
{{- include "controller.limits" . | indent 10 }}
{{- include "controller.envs" . | indent 10 }}
{{- include "controller.volumeMounts" . | indent 10 }}
{{- include "controller.volumes" . | indent 6 }}
2 changes: 2 additions & 0 deletions rootfs/api/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -352,6 +352,8 @@ def list(self, *args, **kwargs):
exist_pod_type = list(set([_["type"] for _ in data if _["type"]]))
structure = self.get_app().structure
procfile_structure = self.get_app().procfile_structure
# remove prev release container type
structure = {k: v for k, v in structure.items() if (v != 0 or k in procfile_structure)} # noqa
for _ in structure.keys():
if _ not in exist_pod_type:
replicas = str(autoscale[_]['min']) + '-' + str(autoscale[_]['max']) \
Expand Down

0 comments on commit 2ee14b3

Please sign in to comment.