chore: Update GitHub workflow to use versions.json instead of version.json
This commit is contained in:
		
							
								
								
									
										18
									
								
								.github/workflows/coolify-helper.yml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										18
									
								
								.github/workflows/coolify-helper.yml
									
									
									
									
										vendored
									
									
								
							@@ -25,6 +25,10 @@ jobs:
 | 
				
			|||||||
          registry: ${{ env.REGISTRY }}
 | 
					          registry: ${{ env.REGISTRY }}
 | 
				
			||||||
          username: ${{ github.actor }}
 | 
					          username: ${{ github.actor }}
 | 
				
			||||||
          password: ${{ secrets.GITHUB_TOKEN  }}
 | 
					          password: ${{ secrets.GITHUB_TOKEN  }}
 | 
				
			||||||
 | 
					      - name: Get Version
 | 
				
			||||||
 | 
					        id: version
 | 
				
			||||||
 | 
					        run: |
 | 
				
			||||||
 | 
					          echo "VERSION=$(jq -r '.coolify.helper.version' $(pwd)/versions.json)"|xargs >> $GITHUB_OUTPUT
 | 
				
			||||||
      - name: Build image and push to registry
 | 
					      - name: Build image and push to registry
 | 
				
			||||||
        uses: docker/build-push-action@v5
 | 
					        uses: docker/build-push-action@v5
 | 
				
			||||||
        with:
 | 
					        with:
 | 
				
			||||||
@@ -33,7 +37,7 @@ jobs:
 | 
				
			|||||||
          file: docker/coolify-helper/Dockerfile
 | 
					          file: docker/coolify-helper/Dockerfile
 | 
				
			||||||
          platforms: linux/amd64
 | 
					          platforms: linux/amd64
 | 
				
			||||||
          push: true
 | 
					          push: true
 | 
				
			||||||
          tags: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:latest
 | 
					          tags: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.version.outputs.VERSION }}
 | 
				
			||||||
  aarch64:
 | 
					  aarch64:
 | 
				
			||||||
    runs-on: [ self-hosted, arm64 ]
 | 
					    runs-on: [ self-hosted, arm64 ]
 | 
				
			||||||
    permissions:
 | 
					    permissions:
 | 
				
			||||||
@@ -47,6 +51,10 @@ jobs:
 | 
				
			|||||||
          registry: ${{ env.REGISTRY }}
 | 
					          registry: ${{ env.REGISTRY }}
 | 
				
			||||||
          username: ${{ github.actor }}
 | 
					          username: ${{ github.actor }}
 | 
				
			||||||
          password: ${{ secrets.GITHUB_TOKEN  }}
 | 
					          password: ${{ secrets.GITHUB_TOKEN  }}
 | 
				
			||||||
 | 
					      - name: Get Version
 | 
				
			||||||
 | 
					        id: version
 | 
				
			||||||
 | 
					        run: |
 | 
				
			||||||
 | 
					          echo "VERSION=$(jq -r '.coolify.helper.version' $(pwd)/versions.json)"|xargs >> $GITHUB_OUTPUT
 | 
				
			||||||
      - name: Build image and push to registry
 | 
					      - name: Build image and push to registry
 | 
				
			||||||
        uses: docker/build-push-action@v5
 | 
					        uses: docker/build-push-action@v5
 | 
				
			||||||
        with:
 | 
					        with:
 | 
				
			||||||
@@ -55,7 +63,7 @@ jobs:
 | 
				
			|||||||
          file: docker/coolify-helper/Dockerfile
 | 
					          file: docker/coolify-helper/Dockerfile
 | 
				
			||||||
          platforms: linux/aarch64
 | 
					          platforms: linux/aarch64
 | 
				
			||||||
          push: true
 | 
					          push: true
 | 
				
			||||||
          tags: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:latest-aarch64
 | 
					          tags: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.version.outputs.VERSION }}-aarch64
 | 
				
			||||||
  merge-manifest:
 | 
					  merge-manifest:
 | 
				
			||||||
    runs-on: ubuntu-latest
 | 
					    runs-on: ubuntu-latest
 | 
				
			||||||
    permissions:
 | 
					    permissions:
 | 
				
			||||||
@@ -75,9 +83,13 @@ jobs:
 | 
				
			|||||||
          registry: ${{ env.REGISTRY }}
 | 
					          registry: ${{ env.REGISTRY }}
 | 
				
			||||||
          username: ${{ github.actor }}
 | 
					          username: ${{ github.actor }}
 | 
				
			||||||
          password: ${{ secrets.GITHUB_TOKEN  }}
 | 
					          password: ${{ secrets.GITHUB_TOKEN  }}
 | 
				
			||||||
 | 
					      - name: Get Version
 | 
				
			||||||
 | 
					        id: version
 | 
				
			||||||
 | 
					        run: |
 | 
				
			||||||
 | 
					          echo "VERSION=$(jq -r '.coolify.helper.version' $(pwd)/versions.json)"|xargs >> $GITHUB_OUTPUT
 | 
				
			||||||
      - name: Create & publish manifest
 | 
					      - name: Create & publish manifest
 | 
				
			||||||
        run: |
 | 
					        run: |
 | 
				
			||||||
          docker buildx imagetools create --append ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:latest-aarch64 --tag ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:latest
 | 
					          docker buildx imagetools create --append ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.version.outputs.VERSION }}-aarch64 --tag ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.version.outputs.VERSION }} --tag ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:latest
 | 
				
			||||||
      - uses: sarisia/actions-status-discord@v1
 | 
					      - uses: sarisia/actions-status-discord@v1
 | 
				
			||||||
        if: always()
 | 
					        if: always()
 | 
				
			||||||
        with:
 | 
					        with:
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -7,7 +7,7 @@
 | 
				
			|||||||
            "version": "4.0.0-beta.331"
 | 
					            "version": "4.0.0-beta.331"
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
        "helper": {
 | 
					        "helper": {
 | 
				
			||||||
            "version": "0.0.1"
 | 
					            "version": "1.0.0"
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user