Release container images #104
This file contains hidden or 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: Release container images | |
| on: | |
| workflow_dispatch: | |
| inputs: | |
| version: | |
| description: 'Version to release' | |
| required: true | |
| env: | |
| AWS_ECR_ROLE_NAME: "ECR_push_pull_images" | |
| AWS_ECR_REGION: "eu-west-1" | |
| AWS_ECR_NODE_RED_REPOSITORY_NAME: "flowforge/node-red" | |
| jobs: | |
| build_application_container: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
| with: | |
| repository: 'flowfuse/helm' | |
| path: 'helm' | |
| # sets options for Docker build | |
| # will tag contianers with ${{ github.event.inputs.version }} and latest | |
| - name: Docker Meta Data | |
| id: meta | |
| uses: docker/metadata-action@902fa8ec7d6ecbf8d84d538b9b233a880e428804 # v5.7.0 | |
| with: | |
| tags: | | |
| type=raw,enable=true,priority=200,prefix=,suffix=,value=${{ github.event.inputs.version }} | |
| flavor: | | |
| latest=true | |
| images: | | |
| flowforge/forge-k8s | |
| flowfuse/forge-k8s | |
| # sets up multi platform emulators | |
| - name: Setup QEMU | |
| uses: docker/setup-qemu-action@29109295f81e9208d7d86ff1c6c12d2833863392 # v3.6.0 | |
| # sets up docker buildx | |
| - name: Setup Docker buildx | |
| uses: docker/setup-buildx-action@b5ca514318bd6ebac0fb2aedd5d36ec1b5c232a2 # v3.10.0 | |
| # logs into docker hub | |
| - name: docker login | |
| uses: docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772 # v3.4.0 | |
| with: | |
| username: flowforge | |
| password: ${{ secrets.DOCKER_HUB_PASSWORD }} | |
| # builds container | |
| - name: Build and push FlowForge Application container | |
| uses: docker/build-push-action@263435318d21b8e681c14492fe198d362a7d2c83 # v6.18.0 | |
| with: | |
| context: helm/flowforge-container | |
| file: helm/flowforge-container/Dockerfile | |
| platforms: linux/amd64, linux/arm64, linux/arm/v7 | |
| tags: ${{ steps.meta.outputs.tags }} | |
| push: true | |
| - name: Push README | |
| uses: peter-evans/dockerhub-description@432a30c9e07499fd01da9f8a49f0faf9e0ca5b77 # v4.0.2 | |
| with: | |
| repository: flowforge/forge-k8s | |
| username: flowforge | |
| password: ${{ secrets.DOCKER_HUB_PASSWORD }} | |
| readme-filepath: ./helm/flowforge-container/README.md | |
| - name: Push README flowfuse | |
| uses: peter-evans/dockerhub-description@432a30c9e07499fd01da9f8a49f0faf9e0ca5b77 # v4.0.2 | |
| with: | |
| repository: flowfuse/forge-k8s | |
| username: flowfuse | |
| password: ${{ secrets.DOCKER_HUB_PASSWORD_FLOWFUSE }} | |
| readme-filepath: ./helm/flowforge-container/README.md | |
| build_nodered_container: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| id-token: write | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
| with: | |
| repository: 'flowfuse/helm' | |
| path: 'helm' | |
| - name: Configure AWS credentials | |
| uses: aws-actions/configure-aws-credentials@b47578312673ae6fa5b5096b330d9fbac3d116df # v4.2.1 | |
| with: | |
| aws-region: ${{ env.AWS_ECR_REGION }} | |
| role-to-assume: arn:aws:iam::${{ secrets.PRODUCTION_AWS_ACCOUNT_ID }}:role/${{ env.AWS_ECR_ROLE_NAME }} | |
| role-session-name: GithubActionsRoleSession | |
| role-duration-seconds: 900 | |
| - name: Login to AWS ECR | |
| id: login-ecr | |
| uses: aws-actions/amazon-ecr-login@062b18b96a7aff071d4dc91bc00c4c1a7945b076 # v2.0.1 | |
| with: | |
| registries: "${{ secrets.PRODUCTION_AWS_ACCOUNT_ID }}" | |
| - name: Login to Docker Hub | |
| uses: docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772 # v3.4.0 | |
| with: | |
| username: flowforge | |
| password: ${{ secrets.DOCKER_HUB_PASSWORD }} | |
| - name: Docker Meta Data | |
| id: meta | |
| uses: docker/metadata-action@902fa8ec7d6ecbf8d84d538b9b233a880e428804 # v5.7.0 | |
| with: | |
| tags: | | |
| type=raw,enable=true,priority=200,prefix=,suffix=,value=${{ github.event.inputs.version }} | |
| type=raw,enable=true,priority=200,prefix=latest-,suffix=,value=3.0.x | |
| flavor: | | |
| latest=false | |
| images: | | |
| flowforge/node-red | |
| flowfuse/node-red | |
| ${{ steps.login-ecr.outputs.registry}}/${{ env.AWS_ECR_NODE_RED_REPOSITORY_NAME }} | |
| - name: Setup QEMU | |
| uses: docker/setup-qemu-action@29109295f81e9208d7d86ff1c6c12d2833863392 # v3.6.0 | |
| - name: Setup Docker buildx | |
| uses: docker/setup-buildx-action@b5ca514318bd6ebac0fb2aedd5d36ec1b5c232a2 # v3.10.0 | |
| - name: Build and push Node-RED container | |
| uses: docker/build-push-action@263435318d21b8e681c14492fe198d362a7d2c83 # v6.18.0 | |
| with: | |
| context: helm/node-red-container | |
| file: helm/node-red-container/Dockerfile | |
| platforms: linux/amd64, linux/arm64, linux/arm/v7 | |
| tags: ${{ steps.meta.outputs.tags }} | |
| push: true | |
| - name: Push README | |
| uses: peter-evans/dockerhub-description@432a30c9e07499fd01da9f8a49f0faf9e0ca5b77 # v4.0.2 | |
| with: | |
| repository: flowforge/node-red | |
| username: flowforge | |
| password: ${{ secrets.DOCKER_HUB_PASSWORD }} | |
| readme-filepath: ./helm/node-red-container/README.md | |
| - name: Push README flowfuse | |
| uses: peter-evans/dockerhub-description@432a30c9e07499fd01da9f8a49f0faf9e0ca5b77 # v4.0.2 | |
| with: | |
| repository: flowfuse/node-red | |
| username: flowfuse | |
| password: ${{ secrets.DOCKER_HUB_PASSWORD_FLOWFUSE }} | |
| readme-filepath: ./helm/node-red-container/README.md | |
| build_nodered_container_223: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| id-token: write | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
| with: | |
| repository: 'flowfuse/helm' | |
| path: 'helm' | |
| - name: Configure AWS credentials | |
| uses: aws-actions/configure-aws-credentials@b47578312673ae6fa5b5096b330d9fbac3d116df # v4.2.1 | |
| with: | |
| aws-region: ${{ env.AWS_ECR_REGION }} | |
| role-to-assume: arn:aws:iam::${{ secrets.PRODUCTION_AWS_ACCOUNT_ID }}:role/${{ env.AWS_ECR_ROLE_NAME }} | |
| role-session-name: GithubActionsRoleSession | |
| role-duration-seconds: 900 | |
| - name: Login to AWS ECR | |
| id: login-ecr | |
| uses: aws-actions/amazon-ecr-login@062b18b96a7aff071d4dc91bc00c4c1a7945b076 # v2.0.1 | |
| with: | |
| registries: "${{ secrets.PRODUCTION_AWS_ACCOUNT_ID }}" | |
| - name: Login to Docker Hub | |
| uses: docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772 # v3.4.0 | |
| with: | |
| username: flowforge | |
| password: ${{ secrets.DOCKER_HUB_PASSWORD }} | |
| - name: Docker Meta Data | |
| id: meta | |
| uses: docker/metadata-action@902fa8ec7d6ecbf8d84d538b9b233a880e428804 # v5.7.0 | |
| with: | |
| tags: | | |
| type=raw,enable=true,priority=200,prefix=,suffix=-2.2.3,value=${{ github.event.inputs.version }} | |
| type=raw,enable=true,priority=200,prefix=latest-,suffix=,value=2.2.x | |
| flavor: | | |
| latest=false | |
| images: | | |
| flowforge/node-red | |
| flowfuse/node-red | |
| ${{ steps.login-ecr.outputs.registry}}/${{ env.AWS_ECR_NODE_RED_REPOSITORY_NAME }} | |
| - name: Setup QEMU | |
| uses: docker/setup-qemu-action@29109295f81e9208d7d86ff1c6c12d2833863392 # v3.6.0 | |
| - name: Setup Docker buildx | |
| uses: docker/setup-buildx-action@b5ca514318bd6ebac0fb2aedd5d36ec1b5c232a2 # v3.10.0 | |
| - name: Build and push Node-RED container | |
| uses: docker/build-push-action@263435318d21b8e681c14492fe198d362a7d2c83 # v6.18.0 | |
| with: | |
| context: helm/node-red-container | |
| file: helm/node-red-container/Dockerfile-2.2.x | |
| platforms: linux/amd64, linux/arm64, linux/arm/v7 | |
| tags: ${{ steps.meta.outputs.tags }} | |
| push: true | |
| build_nodered_container_31: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| id-token: write | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
| with: | |
| repository: 'flowfuse/helm' | |
| path: 'helm' | |
| - name: Configure AWS credentials | |
| uses: aws-actions/configure-aws-credentials@b47578312673ae6fa5b5096b330d9fbac3d116df # v4.2.1 | |
| with: | |
| aws-region: ${{ env.AWS_ECR_REGION }} | |
| role-to-assume: arn:aws:iam::${{ secrets.PRODUCTION_AWS_ACCOUNT_ID }}:role/${{ env.AWS_ECR_ROLE_NAME }} | |
| role-session-name: GithubActionsRoleSession | |
| role-duration-seconds: 900 | |
| - name: Login to AWS ECR | |
| id: login-ecr | |
| uses: aws-actions/amazon-ecr-login@062b18b96a7aff071d4dc91bc00c4c1a7945b076 # v2.0.1 | |
| with: | |
| registries: "${{ secrets.PRODUCTION_AWS_ACCOUNT_ID }}" | |
| - name: Login to Docker Hub | |
| uses: docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772 # v3.4.0 | |
| with: | |
| username: flowforge | |
| password: ${{ secrets.DOCKER_HUB_PASSWORD }} | |
| - name: Docker Meta Data | |
| id: meta | |
| uses: docker/metadata-action@902fa8ec7d6ecbf8d84d538b9b233a880e428804 # v5.7.0 | |
| with: | |
| tags: | | |
| type=raw,enable=true,priority=200,prefix=,suffix=-3.1.x,value=${{ github.event.inputs.version }} | |
| type=raw,enable=true,priority=200,prefix=latest-,suffix=,value=3.1.x | |
| flavor: | | |
| latest=false | |
| images: | | |
| flowforge/node-red | |
| flowfuse/node-red | |
| ${{ steps.login-ecr.outputs.registry}}/${{ env.AWS_ECR_NODE_RED_REPOSITORY_NAME }} | |
| - name: Setup QEMU | |
| uses: docker/setup-qemu-action@29109295f81e9208d7d86ff1c6c12d2833863392 # v3.6.0 | |
| - name: Setup Docker buildx | |
| uses: docker/setup-buildx-action@b5ca514318bd6ebac0fb2aedd5d36ec1b5c232a2 # v3.10.0 | |
| - name: Build and push Node-RED container | |
| uses: docker/build-push-action@263435318d21b8e681c14492fe198d362a7d2c83 # v6.18.0 | |
| with: | |
| context: helm/node-red-container | |
| file: helm/node-red-container/Dockerfile-3.1 | |
| platforms: linux/amd64, linux/arm64, linux/arm/v7 | |
| tags: ${{ steps.meta.outputs.tags }} | |
| push: true | |
| build_nodered_container_40: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| id-token: write | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
| with: | |
| repository: 'flowfuse/helm' | |
| path: 'helm' | |
| - name: Configure AWS credentials | |
| uses: aws-actions/configure-aws-credentials@b47578312673ae6fa5b5096b330d9fbac3d116df # v4.2.1 | |
| with: | |
| aws-region: ${{ env.AWS_ECR_REGION }} | |
| role-to-assume: arn:aws:iam::${{ secrets.PRODUCTION_AWS_ACCOUNT_ID }}:role/${{ env.AWS_ECR_ROLE_NAME }} | |
| role-session-name: GithubActionsRoleSession | |
| role-duration-seconds: 900 | |
| - name: Login to AWS ECR | |
| id: login-ecr | |
| uses: aws-actions/amazon-ecr-login@062b18b96a7aff071d4dc91bc00c4c1a7945b076 # v2.0.1 | |
| with: | |
| registries: "${{ secrets.PRODUCTION_AWS_ACCOUNT_ID }}" | |
| - name: Login to Docker Hub | |
| uses: docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772 # v3.4.0 | |
| with: | |
| username: flowforge | |
| password: ${{ secrets.DOCKER_HUB_PASSWORD }} | |
| - name: Docker Meta Data | |
| id: meta | |
| uses: docker/metadata-action@902fa8ec7d6ecbf8d84d538b9b233a880e428804 # v5.7.0 | |
| with: | |
| tags: | | |
| type=raw,enable=true,priority=200,prefix=,suffix=-4.0.x,value=${{ github.event.inputs.version }} | |
| type=raw,enable=true,priority=200,prefix=latest-,suffix=,value=4.0.x | |
| flavor: | | |
| latest=true | |
| images: | | |
| flowforge/node-red | |
| flowfuse/node-red | |
| ${{ steps.login-ecr.outputs.registry}}/${{ env.AWS_ECR_NODE_RED_REPOSITORY_NAME }} | |
| - name: Setup QEMU | |
| uses: docker/setup-qemu-action@29109295f81e9208d7d86ff1c6c12d2833863392 # v3.6.0 | |
| - name: Setup Docker buildx | |
| uses: docker/setup-buildx-action@b5ca514318bd6ebac0fb2aedd5d36ec1b5c232a2 # v3.10.0 | |
| - name: Build and push Node-RED container | |
| uses: docker/build-push-action@263435318d21b8e681c14492fe198d362a7d2c83 # v6.18.0 | |
| with: | |
| context: helm/node-red-container | |
| file: helm/node-red-container/Dockerfile-4.0 | |
| platforms: linux/amd64, linux/arm64 | |
| tags: ${{ steps.meta.outputs.tags }} | |
| push: true | |
| build_file_server_container: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
| with: | |
| repository: 'flowfuse/helm' | |
| path: 'helm' | |
| - name: Docker Meta Data | |
| id: meta | |
| uses: docker/metadata-action@902fa8ec7d6ecbf8d84d538b9b233a880e428804 # v5.7.0 | |
| with: | |
| tags: | | |
| type=raw,enable=true,priority=200,prefix=,suffix=,value=${{ github.event.inputs.version }} | |
| flavor: | | |
| latest=true | |
| images: | | |
| flowforge/file-server | |
| flowfuse/file-server | |
| - name: Setup QEMU | |
| uses: docker/setup-qemu-action@29109295f81e9208d7d86ff1c6c12d2833863392 # v3.6.0 | |
| - name: Setup Docker buildx | |
| uses: docker/setup-buildx-action@b5ca514318bd6ebac0fb2aedd5d36ec1b5c232a2 # v3.10.0 | |
| - name: docker login | |
| uses: docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772 # v3.4.0 | |
| with: | |
| username: flowforge | |
| password: ${{ secrets.DOCKER_HUB_PASSWORD }} | |
| - name: Build and push FlowForge File Server container | |
| uses: docker/build-push-action@263435318d21b8e681c14492fe198d362a7d2c83 # v6.18.0 | |
| with: | |
| context: helm/file-server | |
| file: helm/file-server/Dockerfile | |
| platforms: linux/amd64, linux/arm64, linux/arm/v7 | |
| tags: ${{ steps.meta.outputs.tags }} | |
| push: true | |
| - name: Push README | |
| uses: peter-evans/dockerhub-description@432a30c9e07499fd01da9f8a49f0faf9e0ca5b77 # v4.0.2 | |
| with: | |
| repository: flowforge/file-server | |
| username: flowforge | |
| password: ${{ secrets.DOCKER_HUB_PASSWORD }} | |
| readme-filepath: ./helm/file-server/README.md | |
| - name: Push README flowfuse | |
| uses: peter-evans/dockerhub-description@432a30c9e07499fd01da9f8a49f0faf9e0ca5b77 # v4.0.2 | |
| with: | |
| repository: flowfuse/file-server | |
| username: flowfuse | |
| password: ${{ secrets.DOCKER_HUB_PASSWORD_FLOWFUSE }} | |
| readme-filepath: ./helm/file-server/README.md |