Skip to content

Commit

Permalink
do not set resources in workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
jfcoz committed Sep 19, 2024
1 parent d617e96 commit 559bcc7
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 18 deletions.
14 changes: 0 additions & 14 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,6 @@ jobs:
echo 'CORS=["https://api-platform.com", "http://localhost", "https://localhost", "http://localhost:3000"]' >> "$GITHUB_ENV"
echo "NAMESPACE=prod-website" >> "$GITHUB_ENV"
echo "REPLICA=1" >> "$GITHUB_ENV"
echo "CPU_REQUEST=10m" >> "$GITHUB_ENV"
echo "MEM_REQUEST=400Mi" >> "$GITHUB_ENV"
echo "MEM_LIMIT=1400Mi" >> "$GITHUB_ENV"
else
CONTEXT=nonprod
if [ "$GITHUB_EVENT_NAME" == "pull_request" ]; then
Expand All @@ -98,9 +95,6 @@ jobs:
echo "REPLICA=1" >> "$GITHUB_ENV"
echo "NAMESPACE=nonprod-website" >> "$GITHUB_ENV"
echo 'CORS=["https://${{ env.RELEASE_NAME}}.apip.preprod-tilleuls.ovh", "http://localhost", "https://localhost", "http://localhost:3000"]' >> "$GITHUB_ENV"
echo "CPU_REQUEST=5m" >> "$GITHUB_ENV"
echo "MEM_REQUEST=100Mi" >> "$GITHUB_ENV"
echo "MEM_LIMIT=600Mi" >> "$GITHUB_ENV"
fi
- name: HELM Deploy
run: |
Expand All @@ -126,10 +120,6 @@ jobs:
--set=pwa.image.repository=eu.gcr.io/${{ secrets.gke-project }}/website/pwa \
--set=pwa.image.tag=${{ inputs.docker-images-version }} \
--set=pwa.image.pullPolicy=Always \
--set=pwa.resources.requests.cpu=${{ env.CPU_REQUEST }} \
--set=pwa.resources.requests.memory=${{ env.MEM_REQUEST }} \
--set=pwa.resources.limits.memory=${{ env.MEM_LIMIT }} \
--set=pwa.replicaCount=${{ env.REPLICA }} \
--set=bucket.s3Upstream=storage.googleapis.com \
--set=bucket.s3Name=api-platform-website-v3 \
--set=service.type=NodePort \
Expand Down Expand Up @@ -169,10 +159,6 @@ jobs:
--set=pwa.image.repository=eu.gcr.io/${{ secrets.gke-project }}/website/pwa \
--set=pwa.image.tag=${{ inputs.docker-images-version }} \
--set=pwa.image.pullPolicy=Always \
--set=pwa.resources.requests.cpu=${{ env.CPU_REQUEST }} \
--set=pwa.resources.requests.memory=${{ env.MEM_REQUEST }} \
--set=pwa.resources.limits.memory=${{ env.MEM_LIMIT }} \
--set=pwa.replicaCount=${{ env.REPLICA }} \
--set=php.corsAllowOrigin="^$(echo "${{ join(fromJSON(env.CORS), '|') }}" | sed 's/\./\\./g')$" \
--set=github.key=${{ secrets.gh-key }} \
--set=next.rootUrl=${{ env.URL }} \
Expand Down
8 changes: 4 additions & 4 deletions helm/api-platform/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ php:
- "192.168.0.0/16"
resources:
requests:
cpu: 100m
cpu: 50m
memory: 100Mi

pwa:
Expand All @@ -32,10 +32,10 @@ pwa:
tag: ""
resources:
requests:
memory: 1400Mi
cpu: 500m
memory: 150Mi
cpu: 50m
limits:
memory: 1400Mi
memory: 300Mi
podAnnotations:
instrumentation.opentelemetry.io/inject-nodejs: "true"

Expand Down

0 comments on commit 559bcc7

Please sign in to comment.