Add npm_registry_auth_token
input
#22
Workflow file for this run
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: Build Flowforge container | ||
on: | ||
workflow_dispatch: | ||
inputs: | ||
flowforge_release_name: | ||
description: 'flowforge package version' | ||
required: false | ||
default: 'nightly' | ||
flowforge_ref: | ||
description: 'flowforge package ref' | ||
required: false | ||
schedule: | ||
- cron: '30 5 * * *' | ||
push: | ||
branches: | ||
- 'feat-*' | ||
pull_request: | ||
branches: | ||
- main | ||
jobs: | ||
build: | ||
uses: flowforge/github-actions-workflows/.github/workflows/build_container_image.yml@feat-container-build | ||
with: | ||
image_name: 'forge-k8s' | ||
package_dependencies: | | ||
@flowforge/flowforge | ||
@flowforge/kubernetes | ||
build_context: 'flowforge-container' | ||
push_image: false | ||
npm_registry_auth_token: ${{ secrets.GITHUB_TOKEN }} | ||
Check failure on line 31 in .github/workflows/flowforge-container.yml GitHub Actions / Build Flowforge containerInvalid workflow file
|
||
# - name: Checkout | ||
# uses: actions/checkout@v3 | ||
# - name: Setup Docker buildx | ||
# uses: docker/setup-buildx-action@v2 | ||
# - name: Set release name and image tag | ||
# # if: ${{ github.event_name == 'schedule' }} | ||
# run: | | ||
# echo "release_name=nightly" >> $GITHUB_ENV | ||
# echo "image_tag=nightly-$(date +%Y%m%d%H%m%S)" >> $GITHUB_ENV | ||
# - name: "Set dependencies versions" | ||
# run: | | ||
# cat flowforge-container/package.json | jq '.dependencies["@flowforge/flowforge"] = "${{ env.release_name }}" | .dependencies["@flowforge/kubernetes"] = "${{ env.release_name }}" ' > flowforge-container/package.json-patched | ||
# mv flowforge-container/package.json-patched flowforge-container/package.json | ||
# - name: Configure AWS credentials | ||
# if: ${{ env.release_name == 'nightly' }} | ||
# uses: aws-actions/configure-aws-credentials@v2 | ||
# with: | ||
# aws-access-key-id: ${{ secrets.STAGING_AWS_ID }} | ||
# aws-secret-access-key: ${{ secrets.STAGING_AWS_KEY }} | ||
# aws-region: eu-west-1 | ||
# - name: "Login to Staging ECR" | ||
# if: ${{ env.release_name == 'nightly' }} | ||
# id: login-ecr | ||
# uses: aws-actions/amazon-ecr-login@v1 | ||
# - name: Get image metadata | ||
# id: image_metadata | ||
# uses: docker/metadata-action@v4 | ||
# with: | ||
# images: | | ||
# ${{ steps.login-ecr.outputs.registry }}/flowforge/forge-k8s | ||
# tags: | | ||
# type=raw,value=${{ env.image_tag }} | ||
# flavor: | | ||
# latest=false | ||
# - name: Build and push Forge container | ||
# uses: docker/[email protected] | ||
# with: | ||
# context: flowforge-container | ||
# file: flowforge-container/Dockerfile | ||
# tags: ${{ steps.image_metadata.outputs.tags }} | ||
# platforms: | | ||
# linux/amd64 | ||
# linux/arm64 | ||
# build-args: | | ||
# REGISTRY=npm.pkg.github.com | ||
# REGISTRY_TOKEN=${{ secrets.GITHUB_TOKEN }} | ||
# push: true | ||
dispatch: | ||
runs-on: ubuntu-latest | ||
needs: [build] | ||
if: false | ||
steps: | ||
- name: Generate a token | ||
id: generate_token | ||
uses: tibdex/github-app-token@v1 | ||
with: | ||
app_id: ${{ secrets.GH_BOT_APP_ID }} | ||
private_key: ${{ secrets.GH_BOT_APP_KEY }} | ||
- name: Trigger cloud deployment | ||
uses: benc-uk/workflow-dispatch@v1 | ||
with: | ||
workflow: deploy.yml | ||
repo: flowforge/CloudProject | ||
ref: feat-deployment-poc | ||
token: ${{ steps.generate_token.outputs.token }} | ||
inputs: '{"flowforge_image_tag": "${{ env.image_tag }}"}' | ||