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: Docker Image CI | |
on: | |
push: | |
branches: ["master", "coolify-build"] | |
pull_request: | |
branches: ["master"] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: Login to ghcr | |
uses: docker/login-action@v3 | |
with: | |
registry: ghcr.io | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
# - name: Build and push | |
# uses: docker/build-push-action@v5 | |
# with: | |
# context: . | |
# push: true | |
# target: main | |
# tags: ghcr.io/<name>/<image-name>:latest | |
# cache-from: type=registry,ref=ghcr.io/<name>/<image-name>:latest | |
# cache-to: type=inline | |
- name: Build the Docker image | |
run: | | |
docker compose -f ./docker-compose.yml build | |
docker compose -f ./docker-compose.yml push |