Skip to content

Merge pull request #143 from Datenschule/berlin-4326 #59

Merge pull request #143 from Datenschule/berlin-4326

Merge pull request #143 from Datenschule/berlin-4326 #59

Workflow file for this run

name: Publish Docker Image
on:
push:
branches:
- master
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Publish to Registry
uses: elgohr/[email protected]
with:
name: knuthuehne/jedeschule-scrapers
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
deploy:
needs: build
runs-on: ubuntu-latest
environment: server
steps:
- name: Pull latest docker images and restart
uses: appleboy/[email protected]
with:
host: ${{ secrets.HOST }}
username: ${{ secrets.USERNAME }}
key: ${{ secrets.KEY }}
port: ${{ secrets.PORT }}
script: |
cd /home/jedeschule/
sudo docker-compose pull scrapers
sudo docker-compose up --detach --build scrapers
sudo docker image prune -f