Skip to content
This repository has been archived by the owner on Feb 15, 2024. It is now read-only.

[pre-commit.ci] pre-commit autoupdate (#29) #9

[pre-commit.ci] pre-commit autoupdate (#29)

[pre-commit.ci] pre-commit autoupdate (#29) #9

Workflow file for this run

name: push-to-main
on:
push:
branches:
- main
jobs:
cicd:
name: CICD
runs-on: ubuntu-latest
env:
ENVIRONMENT: prod
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: 3.12
- name: Poetry cache
uses: actions/cache@v3
with:
path: |
~/.cache/pip
~/.cache/pypoetry
key: ${{ runner.os }}-pypoetry-${{ hashFiles('**/poetry.lock') }}
restore-keys: |
${{ runner.os }}-pypoetry-${{ hashFiles('**/poetry.lock') }}
${{ runner.os }}-pypoetry-
- name: Create env file
run: |
touch .env
echo ENVIRONMENT=ci >> .env
cat .env
- name: Run CI
run: make run-ci
- name: Login to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USER }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Docker build
run: make dc-build
- name: Docker CI
run: make dc-ci
- name: Docker push
run: make dc-push