Update UI and US versions #29
Workflow file for this run
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
on: | |
pull_request: | |
name: Update docker-compose.yml docker-compose-dev.yml | |
permissions: | |
contents: write | |
jobs: | |
update_compose_files: | |
name: build files | |
runs-on: ubuntu-latest | |
steps: | |
- name: checkout | |
uses: actions/checkout@v4 | |
with: | |
ref: ${{ github.event.pull_request.head.ref }} | |
- name: setup python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: 3.9 | |
- name: install jinja2 | |
run: | | |
pip3 install --user --upgrade j2cli | |
j2 --version | |
- name: build docker-compose.yml & docker-compose-dev.yml | |
run: | | |
j2 ./templates/docker-compose.j2 versions-config.json --format=json > ./docker-compose.yml | |
DEV_MODE=true j2 ./templates/docker-compose.j2 versions-config.json --format=json > ./docker-compose-dev.yml | |
- name: Initialize mandatory git config | |
run: | | |
git config user.name "GitHub Actions" | |
git config user.email [email protected] | |
- name: Commit compose files | |
id: make-commit | |
run: | | |
git add docker-compose.yml docker-compose-dev.yml | |
if ! git diff-index --quiet HEAD; then | |
git commit --message "update docker-compose.yml docker-compose-dev.yml" | |
git push | |
fi |