Build docker images #103
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
name: Build docker images | |
on: | |
workflow_dispatch: | |
schedule: | |
# Every day at 17:30, we udpdate images | |
- cron: '30 17 * * *' | |
jobs: | |
build-and-publish: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
- name: Login to Docker Hub | |
uses: docker/login-action@v1 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- name: Publish 0.27 | |
run: | | |
npm install -g doctoc | |
export DOCKERHUB_USERNAME=${{ secrets.DOCKERHUB_USERNAME }} | |
export DECIDIM_VERSION_BRANCHES=release/0.27-stable | |
export DOCKERHUB_PUSH=true | |
./update-registery.rb | |
# - name: Publish edge | |
# run: | | |
# npm install -g doctoc | |
# export DOCKERHUB_USERNAME=${{ secrets.DOCKERHUB_USERNAME }} | |
# export DECIDIM_VERSION_BRANCHES=develop | |
# export DOCKERHUB_PUSH=true | |
# ./update-registery.rb | |
- name: Update Readme | |
run: | | |
npm install -g doctoc | |
export DOCKERHUB_USERNAME=${{ secrets.DOCKERHUB_USERNAME }} | |
export DECIDIM_VERSION_BRANCHES=release/0.27-stable,develop | |
./update-documentation.rb | |
- name: Commit and push changes | |
run: | | |
git config --global user.name "Github Actions" | |
git config --global user.email "actions@github.com" | |
git add . | |
git diff-index --quiet HEAD || git commit -m "Update files from update script" | |
git push |