-
Notifications
You must be signed in to change notification settings - Fork 0
30 lines (27 loc) · 967 Bytes
/
build.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
name: Build and publish a Docker image to ghcr.io
on:
push:
branches:
- main
jobs:
docker_publish:
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
- uses: actions/checkout@v4
# https://github.com/marketplace/actions/push-to-ghcr
- name: Build and publish a Docker image for ${{ github.repository }}
uses: macbre/push-to-ghcr@master
with:
image_name: ${{ github.repository }} # it will be lowercased internally
github_token: ${{ secrets.GITHUB_TOKEN }}
# - name: Pull and run docker-compose on remote server
# uses: appleboy/ssh-action@v1.0.3
# with:
# host: ${{ secrets.SSH_HOST }}
# username: ${{ secrets.SSH_USERNAME }}
# key: ${{ secrets.SSH_KEY }}
# script: |
# cd Docker/nuxt-teras-zakiego-com-docker
# docker pull ghcr.io/zakiego/teras.zakiego.com:latest
# docker-compose up -d