forked from zaanposni/discord-masz
-
Notifications
You must be signed in to change notification settings - Fork 2
40 lines (33 loc) · 1.12 KB
/
docker-publish.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
name: Docker
on:
push:
branches: [ main ]
jobs:
build:
if: github.repository_owner == 'FeroxFoxxo'
runs-on: [self-hosted, linux]
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Build backend
run: |
cd backend
docker build -t ghcr.io/feroxfoxxo/dexter_backend:latest .
- name: Push backend
run: |
echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u FeroxFoxxo --password-stdin
docker push ghcr.io/feroxfoxxo/dexter_backend:latest
- name: Build frontend
run: |
cd frontend
docker build -t ghcr.io/feroxfoxxo/dexter_frontend:latest .
- name: Push frontend
run: |
echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u FeroxFoxxo --password-stdin
docker push ghcr.io/feroxfoxxo/dexter_frontend:latest
- name: Send discord notification
env:
DISCORD_WEBHOOK: ${{ secrets.DISCORD_WEBHOOK }}
uses: Ilshidur/action-discord@master
with:
args: "🚀 Published 🚀"