Merge pull request #16 from ultravioletrs/rename #3
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: Create and publish Cube Proxy Docker image | |
on: | |
push: | |
branches: | |
- main | |
tags: | |
- "v*" | |
paths: | |
- ".github/workflows/cd.yaml" | |
- "proxy/**" | |
workflow_dispatch: | |
env: | |
REGISTRY: ghcr.io | |
IMAGE_NAME: ${{ github.repository }} | |
jobs: | |
build-and-push-image: | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
packages: write | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
- name: Fetch tags for the build | |
run: | | |
git fetch --prune --unshallow --tags | |
- name: Set up Docker Build | |
uses: docker/setup-buildx-action@v3 | |
- name: Log in to the Container registry | |
uses: docker/login-action@v3 | |
with: | |
registry: ${{ env.REGISTRY }} | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- name: Build and push Docker image | |
run: | | |
cd proxy | |
make latest |