diff --git a/Dockerfile b/Dockerfile index 0491a430..f708364e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -42,7 +42,6 @@ ENV PYTHONDONTWRITEBYTECODE 1 ENV BUILD_ENV ${BUILD_ENVIRONMENT} WORKDIR ${APP_HOME} - # Install required system dependencies RUN apt-get update && apt-get install --no-install-recommends -y \ # psycopg2 dependencies diff --git a/bin/post_compile b/bin/post_compile deleted file mode 100644 index a9c94b39..00000000 --- a/bin/post_compile +++ /dev/null @@ -1,22 +0,0 @@ -#!/usr/bin/env bash - -compress_enabled() { -python << END -import sys - -from environ import Env - -env = Env(COMPRESS_ENABLED=(bool, True)) -if env('COMPRESS_ENABLED'): - sys.exit(0) -else: - sys.exit(1) - -END -} - -if compress_enabled -then - python manage.py compress -fi -python manage.py collectstatic --noinput diff --git a/cloudbuild.yaml b/cloudbuild.yaml index fec6df45..cc099175 100644 --- a/cloudbuild.yaml +++ b/cloudbuild.yaml @@ -26,7 +26,11 @@ steps: '--allow-unauthenticated', '--add-cloudsql-instances', '${_CLOUDSQL_INSTANCE_CONNECTION_NAME}', '--set-env-vars', 'GOOGLE_CLOUD_PROJECT=$PROJECT_ID,SETTINGS_NAME=mle_django_settings,DJANGO_SETTINGS_MODULE=config.settings.production', - '--min-instances', '1' + '--min-instances', '1', + '--max-instances', '4', + '--memory', '256M', + '--cpu', '1', + '-update-secrets', '/app/.env=mle_django_settings:latest' ] images: