An open-source, self-hostable PaaS alternative to Vercel, Heroku & Netlify that lets you easily deploy static sites, databases, full-stack applications and 360+ one-click services on your own servers.
PHP coolifydatabasesdeploymentdockerdocker-composeinertiajslaravelmariadbmysqlnextjsnodejsphppostgresredisself-hostedself-hostingserverstatic-sitesveltesvelte5
fix(ci): sanitize branch names for Docker tag compatibility
Andras Bacsaic009c97eb10a
diff --git a/.github/workflows/coolify-staging-build.yml b/.github/workflows/coolify-staging-build.ymlindex 09b1e94214..c6aa2dd908 100644--- a/.github/workflows/coolify-staging-build.yml+++ b/.github/workflows/coolify-staging-build.yml@@ -28,6 +28,13 @@ jobs:steps:- uses: actions/checkout@v4+ - name: Sanitize branch name for Docker tag+ id: sanitize+ run: |+ # Replace slashes and other invalid characters with dashes+ SANITIZED_NAME=$(echo "${{ github.ref_name }}" | sed 's/[\/]/-/g')+ echo "tag=${SANITIZED_NAME}" >> $GITHUB_OUTPUT+- name: Login to ${{ env.GITHUB_REGISTRY }}uses: docker/login-action@v3with:@@ -50,8 +57,8 @@ jobs:platforms: linux/amd64push: truetags: |- ${{ env.DOCKER_REGISTRY }}/${{ env.IMAGE_NAME }}:${{ github.ref_name }}- ${{ env.GITHUB_REGISTRY }}/${{ env.IMAGE_NAME }}:${{ github.ref_name }}+ ${{ env.DOCKER_REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.sanitize.outputs.tag }}+ ${{ env.GITHUB_REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.sanitize.outputs.tag }}aarch64:runs-on: [self-hosted, arm64]@@ -61,6 +68,13 @@ jobs:steps:- uses: actions/checkout@v4+ - name: Sanitize branch name for Docker tag+ id: sanitize+ run: |+ # Replace slashes and other invalid characters with dashes+ SANITIZED_NAME=$(echo "${{ github.ref_name }}" | sed 's/[\/]/-/g')+ echo "tag=${SANITIZED_NAME}" >> $GITHUB_OUTPUT+- name: Login to ${{ env.GITHUB_REGISTRY }}uses: docker/login-action@v3with:@@ -83,8 +97,8 @@ jobs:platforms: linux/aarch64push: truetags: |- ${{ env.DOCKER_REGISTRY }}/${{ env.IMAGE_NAME }}:${{ github.ref_name }}-aarch64- ${{ env.GITHUB_REGISTRY }}/${{ env.IMAGE_NAME }}:${{ github.ref_name }}-aarch64+ ${{ env.DOCKER_REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.sanitize.outputs.tag }}-aarch64+ ${{ env.GITHUB_REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.sanitize.outputs.tag }}-aarch64merge-manifest:runs-on: ubuntu-latest@@ -95,6 +109,13 @@ jobs:steps:- uses: actions/checkout@v4+ - name: Sanitize branch name for Docker tag+ id: sanitize+ run: |+ # Replace slashes and other invalid characters with dashes+ SANITIZED_NAME=$(echo "${{ github.ref_name }}" | sed 's/[\/]/-/g')+ echo "tag=${SANITIZED_NAME}" >> $GITHUB_OUTPUT+- uses: docker/setup-buildx-action@v3- name: Login to ${{ env.GITHUB_REGISTRY }}@@ -114,14 +135,14 @@ jobs:- name: Create & publish manifest on ${{ env.GITHUB_REGISTRY }}run: |docker buildx imagetools create \- --append ${{ env.GITHUB_REGISTRY }}/${{ env.IMAGE_NAME }}:${{ github.ref_name }}-aarch64 \- --tag ${{ env.GITHUB_REGISTRY }}/${{ env.IMAGE_NAME }}:${{ github.ref_name }}+ --append ${{ env.GITHUB_REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.sanitize.outputs.tag }}-aarch64 \+ --tag ${{ env.GITHUB_REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.sanitize.outputs.tag }}- name: Create & publish manifest on ${{ env.DOCKER_REGISTRY }}run: |docker buildx imagetools create \- --append ${{ env.DOCKER_REGISTRY }}/${{ env.IMAGE_NAME }}:${{ github.ref_name }}-aarch64 \- --tag ${{ env.DOCKER_REGISTRY }}/${{ env.IMAGE_NAME }}:${{ github.ref_name }}+ --append ${{ env.DOCKER_REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.sanitize.outputs.tag }}-aarch64 \+ --tag ${{ env.DOCKER_REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.sanitize.outputs.tag }}- uses: sarisia/actions-status-discord@v1if: always()