-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
125 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
repository: great-core-cms | ||
builder: | ||
name: paketobuildpacks/builder-jammy-full | ||
version: 0.3.339 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
#!/usr/bin/env bash | ||
|
||
# Exit early if something goes wrong | ||
set -e | ||
|
||
# Add commands below to run inside the container after all the other buildpacks have been applied | ||
|
||
export BUILD_STEP='true' | ||
|
||
# shellcheck disable=SC2046 | ||
export $(grep -v '^#' ./config/env/test | xargs) | ||
export APP_ENVIRONMENT='local' | ||
export REDIS_URL='redis://localhost:6379' | ||
export BASE_URL='http://greatcms.trade.great:8020' | ||
export WAGTAILADMIN_BASE_URL='http://greatcms.trade.great:8020' | ||
export OPENSEARCH_PROVIDER='localhost' | ||
export STAFF_SSO_AUTHBROKER_URL='https://www.examole.com' | ||
export AUTHBROKER_CLIENT_ID='debug' | ||
export AUTHBROKER_CLIENT_SECRET='debug' | ||
export SSO_PROXY_LOGIN_URL='http://sso.proxy.trade.great:8004/sso/accounts/login/' | ||
export SSO_PROXY_LOGOUT_URL='http://sso.proxy.trade.great:8004/sso/accounts/logout/?next=http://greatcms.trade.great:8020/thing/' | ||
export SSO_PROXY_SIGNUP_URL='http://sso.proxy.trade.great:8004/sso/accounts/signup/?next=http://greatcms.trade.great:8020/thing/' | ||
export SSO_PROXY_PASSWORD_RESET_URL='http://sso.proxy.trade.great:8004/sso/accounts/password/reset/' | ||
export SSO_PROXY_REDIRECT_FIELD_NAME='next' | ||
export SSO_SESSION_COOKIE='debug_sso_session_cookie' | ||
export SSO_OAUTH2_LINKEDIN_URL='http://sso.proxy.trade.great:8004/sso/accounts/login/via-linkedin/' | ||
export SSO_OAUTH2_GOOGLE_URL='debug' | ||
export GOOGLE_TAG_MANAGER_ID='GTM-1234567' | ||
export UTM_COOKIE_DOMAIN='.trade.great' | ||
export RECAPTCHA_PUBLIC_KEY='test_key' | ||
export RECAPTCHA_PRIVATE_KEY='test_key' | ||
export DIRECTORY_FORMS_API_BASE_URL='http://forms.trade.great:8011' | ||
export DIRECTORY_FORMS_DEFAULT_TIMEOUT='30' | ||
export DIRECTORY_API_CLIENT_BASE_URL='http://api.trade.great:8000' | ||
export DIRECTORY_API_CLIENT_API_KEY='debug' | ||
export DIRECTORY_FORMS_API_API_KEY='01234567890123456789012345678912' | ||
export DIRECTORY_FORMS_API_SENDER_ID='12345678-1234-1234-1234-123456789012' | ||
export EU_EXIT_ZENDESK_SUBDOMAIN='debug' | ||
export CONTACT_ENQUIRIES_AGENT_EMAIL_ADDRESS='[email protected]' | ||
export CONTACT_ECOMMERCE_EXPORT_SUPPORT_AGENT_EMAIL_ADDRESS='[email protected]' | ||
export CONTACT_DIT_AGENT_EMAIL_ADDRESS='[email protected]' | ||
export CONTACT_EVENTS_AGENT_EMAIL_ADDRESS='[email protected]' | ||
export CONTACT_DSO_AGENT_EMAIL_ADDRESS='[email protected]' | ||
export CONTACT_INTERNATIONAL_AGENT_EMAIL_ADDRESS='[email protected]' | ||
export UKEF_CONTACT_AGENT_EMAIL_ADDRESS='[email protected]' | ||
export UKEF_FORM_SUBMIT_TRACKER_URL='http://go.pardot.com/l/590031/2018-08-16/5kj25l' | ||
export MAXMIND_LICENCE_KEY='debug' | ||
export WAGTAILTRANSFER_SECRET_KEY='local-one' | ||
export WAGTAIL_TRANSFER_LOCAL_DEV='False' | ||
export HEALTH_CHECK_TOKEN='debug' | ||
|
||
echo "Running image_build_run.sh" | ||
|
||
echo "Running collectstatic" | ||
python manage.py collectstatic --noinput |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
#!/usr/bin/env bash | ||
|
||
# Exit early if something goes wrong | ||
set -e | ||
|
||
# Add commands below to run as part of the build phase |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
#!/usr/bin/env bash | ||
|
||
# Exit early if something goes wrong | ||
set -e | ||
|
||
# Add commands below to run as part of the install phase |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
#!/usr/bin/env bash | ||
|
||
# Exit early if something goes wrong | ||
set -e | ||
|
||
# Add commands below to run as part of the post_build phase |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
#!/usr/bin/env bash | ||
|
||
# Exit early if something goes wrong | ||
set -e | ||
|
||
if [ -f "./.gitmodules" ]; then | ||
echo ".gitmodules file exists. Modifying URLs..." | ||
account_id=$(echo $CODESTAR_CONNECTION_ARN | cut -d':' -f5) | ||
connection_id=$(echo $CODESTAR_CONNECTION_ARN | cut -d'/' -f2) | ||
git_clone_base_url="https://codestar-connections.eu-west-2.amazonaws.com/git-http/$account_id/eu-west-2/$connection_id/uktrade" | ||
|
||
git config --global credential.helper '!aws codecommit credential-helper $@' | ||
git config --global credential.UseHttpPath true | ||
|
||
sed -i "s|url = [email protected]:uktrade/\(.*\).git|url = $git_clone_base_url/\1.git|g" ./.gitmodules | ||
|
||
git submodule update --init --remote --recursive | ||
|
||
else | ||
echo ".gitmodules file does not exist. No URLs to update." | ||
fi | ||
|
||
# Add commands below to run as part of the pre_build phase | ||
|
||
rm ./.python-version |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
web: python manage.py collectstatic --noinput && python manage.py migrate --noinput && gunicorn config.wsgi --bind 0.0.0.0:$PORT | ||
web: python manage.py migrate --noinput && gunicorn config.wsgi --bind 0.0.0.0:$PORT | ||
app: python manage.py migrate --noinput && gunicorn config.wsgi --bind 0.0.0.0:$PORT | ||
celery_worker: celery -A config worker -l DEBUG | ||
celery_beat: celery -A config beat -l info -S django |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters