feature/use-buildkit #11
@@ -40,30 +40,60 @@ on:
 | 
				
			|||||||
  push:
 | 
					  push:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
jobs:
 | 
					jobs:
 | 
				
			||||||
  docker:
 | 
					  build:
 | 
				
			||||||
 | 
					    name: Build Image
 | 
				
			||||||
    runs-on: ubuntu-latest
 | 
					    runs-on: ubuntu-latest
 | 
				
			||||||
 | 
					    container:
 | 
				
			||||||
 | 
					      image: docker:dind
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    steps:
 | 
					    steps:
 | 
				
			||||||
      - name: Login to gitea.sikorski.cloud
 | 
					 | 
				
			||||||
        uses: docker/login-action@v3
 | 
					 | 
				
			||||||
        with:
 | 
					 | 
				
			||||||
          registry: gitea.sikorski.cloud
 | 
					 | 
				
			||||||
          username: rogersik
 | 
					 | 
				
			||||||
          password: ${{ secrets.REGISTRY_PASSWORD }}
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
      - name: Set up QEMU
 | 
					    - name: Set up Docker Context for Buildx
 | 
				
			||||||
        uses: docker/setup-qemu-action@v3
 | 
					      id: buildx-context
 | 
				
			||||||
 | 
					      shell: sh
 | 
				
			||||||
 | 
					      run: |
 | 
				
			||||||
 | 
					        docker context use builders || docker context create builders
 | 
				
			||||||
 | 
					        apk add nodejs
 | 
				
			||||||
 | 
					
 | 
				
			||||||
      - name: Set up Docker Buildx
 | 
					    - name: Set up Docker Buildx
 | 
				
			||||||
        uses: docker/setup-buildx-action@v3
 | 
					      uses: https://github.com/docker/setup-buildx-action@v3
 | 
				
			||||||
 | 
					      with:
 | 
				
			||||||
 | 
					        version: latest
 | 
				
			||||||
 | 
					        endpoint: builders
 | 
				
			||||||
 | 
					
 | 
				
			||||||
      - name: Create Branch Name as valid tag name
 | 
					    - name: Login to gitea.sikorski.cloud
 | 
				
			||||||
        id: clean_branch_name
 | 
					      uses: docker/login-action@v3
 | 
				
			||||||
        run: |
 | 
					      with:
 | 
				
			||||||
          CLEANED_BRANCH_NAME=$(echo "${GITHUB_REF_NAME}" | tr '[:upper:]' '[:lower:]' | tr '/_' '-')
 | 
					        registry: gitea.sikorski.cloud
 | 
				
			||||||
          echo "CLEAN_BRANCH_NAME=${CLEANED_BRANCH_NAME}" >> $GITHUB_ENV
 | 
					        username: rogersik
 | 
				
			||||||
 | 
					        password: ${{ secrets.REGISTRY_PASSWORD }}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
      - name: Build and push
 | 
					    - name: Docker Meta
 | 
				
			||||||
        uses: docker/build-push-action@v6
 | 
					      id: meta
 | 
				
			||||||
        with:
 | 
					      uses: https://github.com/docker/metadata-action@v5
 | 
				
			||||||
          push: true
 | 
					      with:
 | 
				
			||||||
          tags: gitea.sikorski.cloud/rogersik/monica:"${{ env.CLEAN_BRANCH_NAME }}"
 | 
					        images: ${{ secrets.REGISTRY_URL }}
 | 
				
			||||||
 | 
					        flavor: |
 | 
				
			||||||
 | 
					          latest=false
 | 
				
			||||||
 | 
					        tags: |
 | 
				
			||||||
 | 
					          type=sha,prefix=,format=short
 | 
				
			||||||
 | 
					          type=ref,event=tag
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    - name: Create Branch Name as valid tag name
 | 
				
			||||||
 | 
					      id: clean_branch_name
 | 
				
			||||||
 | 
					      run: |
 | 
				
			||||||
 | 
					        CLEANED_BRANCH_NAME=$(echo "${GITHUB_REF_NAME}" | tr '[:upper:]' '[:lower:]' | tr '/_' '-')
 | 
				
			||||||
 | 
					        echo "CLEAN_BRANCH_NAME=${CLEANED_BRANCH_NAME}" >> $GITHUB_ENV
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    - name: Build and Push Docker Image
 | 
				
			||||||
 | 
					      uses: https://github.com/docker/build-push-action@v6
 | 
				
			||||||
 | 
					      env:
 | 
				
			||||||
 | 
					        ACTIONS_RUNTIME_TOKEN: ''
 | 
				
			||||||
 | 
					      with:
 | 
				
			||||||
 | 
					        pull: true
 | 
				
			||||||
 | 
					        # push: ${{ github.event_name != 'pull_request' }}
 | 
				
			||||||
 | 
					        push: true
 | 
				
			||||||
 | 
					        labels: ${{ steps.meta.outputs.labels }}
 | 
				
			||||||
 | 
					        provenance: false
 | 
				
			||||||
 | 
					        tags: gitea.sikorski.cloud/rogersik/monica:"${{ env.CLEAN_BRANCH_NAME }}"
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user