Skip to content

Commit

Permalink
ci(default-settings): defaults for azure settings to satisfy build pr…
Browse files Browse the repository at this point in the history
…ocess

additional docker build steps
  • Loading branch information
WoosterInitiative committed Apr 24, 2024
1 parent f7412ad commit 54841a3
Show file tree
Hide file tree
Showing 2 changed files with 39 additions and 2 deletions.
37 changes: 37 additions & 0 deletions .github/workflows/build_and_push_images.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,43 @@ on:

jobs:
push-django-image:
runs-on: ubuntu-latest
# defaults:
# run:
# working-directory: "./incredible_data"
steps:
- name: "Checkout GitHub Action"
uses: actions/checkout@main

- name: "Login to GitHub Container Registry"
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{github.actor}}
password: ${{secrets.GITHUB_TOKEN}}

- name: "Build and Push Django Image"
run: |
docker build . --file "compose/production/django/Dockerfile" --tag ghcr.io/woostertech/incredible_data_production_django:latest --tag ghcr.io/woostertech/incredible_data_production_celeryworker:latest
docker push ghcr.io/woostertech/incredible_data_production_django:latest
docker push ghcr.io/woostertech/incredible_data_production_celeryworker:latest
- name: "Build and Push PostgreSQL Image"
run: |
docker build . --file "compose/production/postgres/Dockerfile" --tag ghcr.io/woostertech/incredible_data_production_postgres:latest
docker push ghcr.io/woostertech/incredible_data_production_postgres:latest
- name: "Build and Push Traefik Image"
run: |
docker build . --file "compose/production/traefik/Dockerfile" --tag ghcr.io/woostertech/incredible_data_production_traefik:latest
docker push ghcr.io/woostertech/incredible_data_production_traefik:latest
- name: "Build and Push nginx Image"
run: |
docker build . --file "compose/production/nginx/Dockerfile" --tag ghcr.io/woostertech/incredible_data_local_nginx:latest
docker push ghcr.io/woostertech/incredible_data_local_nginx:latest
push-postgres-image:
runs-on: ubuntu-latest
# defaults:
# run:
Expand Down
4 changes: 2 additions & 2 deletions config/settings/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -374,5 +374,5 @@
# "AZURE_KEY": ("must set azure key", "Unique Key for receipt ML", str),
# }

AZURE_ENDPOINT = env.str("DJANGO_AZURE_ENDPOINT")
AZURE_KEY = env.str("DJANGO_AZURE_KEY")
AZURE_ENDPOINT = env.str("DJANGO_AZURE_ENDPOINT", "")
AZURE_KEY = env.str("DJANGO_AZURE_KEY", "")

0 comments on commit 54841a3

Please sign in to comment.