Skip to content

add github actions #117

add github actions

add github actions #117

Workflow file for this run

name: build completion
on:
pull_request:
branches: ["main"]
workflow_dispatch:
inputs:
environment:
description: 'Environment to deploy to'
required : true
type: choice
default: dev
options:
- dev
- test
- prod
permissions:
id-token: write
contents: read
jobs:
setup_env:
uses: equinor/procosys-completion-api/.github/workflows/environment.yaml@github-action-pipeline
secrets:
AZURE_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }}
AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }}
AZURE_SUBSCRIPTION_ID: ${{ secrets.AZURE_SUBSCRIPTION_ID }}
with:
environment: 'dev'
runtests:
needs: setup_env
uses: equinor/procosys-completion-api/.github/workflows/runtests.yaml@github-action-pipeline
secrets:
FEED_ACCESSTOKEN: ${{ $GITHUB_ENV.FEED_ACCESSTOKEN }}

Check failure on line 37 in .github/workflows/api-build.yaml

View workflow run for this annotation

GitHub Actions / build completion

Invalid workflow file

The workflow is not valid. .github/workflows/api-build.yaml (Line: 37, Col: 25): Unexpected symbol: '$GITHUB_ENV'. Located at position 1 within expression: $GITHUB_ENV.FEED_ACCESSTOKEN
# AZURE_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }}
# AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }}
# AZURE_SUBSCRIPTION_ID: ${{ secrets.AZURE_SUBSCRIPTION_ID }}
with:
deployment: 'runtests'
environment: 'dev'
testPath: './Equinor.ProCoSys.Completion.sln'
# build-and-push-docker:
# needs: runtests
# uses: equinor/procosys-completion-api/.github/workflows/build-and-push-docker.yaml@github-action-pipeline
# secrets:
# AZURE_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }}
# AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }}
# AZURE_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }}
# AZURE_SUBSCRIPTION_ID: ${{ secrets.AZURE_SUBSCRIPTION_ID }}
# with:
# repositoryName: procosys-completion
# dockerFilePath: ./src/Dockerfile
# environment: dev
# version: 1.000.0.${{github.run_id}}
# deploy-to-radix:
# needs: build-and-push-docker
# uses: equinor/procosys-completion-api/.github/workflows/deploy-to-radix.yaml@github-action-pipeline
# secrets:
# AZURE_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }}
# AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }}
# AZURE_SUBSCRIPTION_ID: ${{ secrets.AZURE_SUBSCRIPTION_ID }}
# with:
# applicationName: procosys-completion-api
# componentName: backend
# imageTag: 1.000.0.${{github.run_id}}
# environment: dev
# promote-to-test:
# needs: deploy-to-radix
# uses: equinor/procosys-completion-api/.github/workflows/promote-radix.yaml@github-action-pipeline
# secrets:
# AZURE_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }}
# AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }}
# AZURE_SUBSCRIPTION_ID: ${{ secrets.AZURE_SUBSCRIPTION_ID }}
# with:
# applicationName: procosys-completion-api
# toEnvironment: test
# fromEnvironment: dev