2024-07-30 14:55:15 -04:00
|
|
|
name: Docker Build
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- master
|
|
|
|
workflow_dispatch:
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
Build and Push Images:
|
|
|
|
runs-on: docker
|
|
|
|
container: catthehacker/ubuntu:act-latest
|
|
|
|
steps:
|
|
|
|
- name: Checkout code
|
|
|
|
uses: actions/checkout@v3
|
|
|
|
with:
|
|
|
|
token: ${{ secrets.COASTALCOMMITSTOKEN }}
|
|
|
|
- name: Login to CoastalCommits
|
|
|
|
uses: actions/docker-login@v3
|
|
|
|
with:
|
|
|
|
registry: www.coastalcommits.com
|
|
|
|
username: Seaswimmer
|
|
|
|
password: ${{ secrets.COASTALCOMMITSTOKEN }}
|
2024-07-30 15:02:29 -04:00
|
|
|
- name: Build and push MediaWiki image
|
2024-07-30 14:55:15 -04:00
|
|
|
uses: actions/docker-build-push@v5
|
|
|
|
with:
|
2024-07-31 16:05:32 -04:00
|
|
|
context: ./mediawiki/
|
2024-07-30 14:55:15 -04:00
|
|
|
file: ./mediawiki/Dockerfile
|
|
|
|
push: true
|
|
|
|
tags: www.coastalcommits.com/zenith/mediawiki:latest
|
2024-08-01 14:35:33 -04:00
|
|
|
- name: Restart the MediaWiki stack
|
2024-08-01 14:05:38 -04:00
|
|
|
run: |
|
2024-08-01 14:35:33 -04:00
|
|
|
echo "Sending request to Portainer to restart the MediaWiki stack and pull the latest image"
|
2024-08-01 14:05:38 -04:00
|
|
|
curl -X POST --insecure ${{ secrets.BUILDWEBHOOK }}
|