Skip to content

Commit

Permalink
Merge pull request #85 from ballerina-platform/LakshanSS-patch-1
Browse files Browse the repository at this point in the history
Add workflow to release to staging and dev
  • Loading branch information
LakshanSS authored Apr 21, 2022
2 parents 48a491c + df9d0fc commit 5be66d1
Showing 1 changed file with 43 additions and 0 deletions.
43 changes: 43 additions & 0 deletions .github/workflows/dev-stg-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Dev/Staging BCentral Release

on:
workflow_dispatch:
inputs:
bal_central_environment:
description: Ballerina Central Environment
type: choice
options:
- STAGE
- DEV
required: true

jobs:
release:
runs-on: ubuntu-latest
env:
BALLERINA_${{ github.event.inputs.bal_central_environment }}_CENTRAL: true
steps:
- uses: actions/checkout@v2
- name: Ballerina Build
uses: ballerina-platform/ballerina-action/@master
with:
args: pack ./s3

- name: Push to Staging
if: github.event.inputs.bal_central_environment == 'STAGE'
uses: ballerina-platform/ballerina-action/@master
with:
args: push
env:
WORKING_DIR: ./s3
BALLERINA_CENTRAL_ACCESS_TOKEN: ${{ secrets.BALLERINA_CENTRAL_STAGE_ACCESS_TOKEN }}

- name: Push to Dev
if: github.event.inputs.bal_central_environment == 'DEV'
uses: ballerina-platform/ballerina-action/@master
with:
args: push
env:
WORKING_DIR: ./s3
BALLERINA_CENTRAL_ACCESS_TOKEN: ${{ secrets.BALLERINA_CENTRAL_DEV_ACCESS_TOKEN }}

0 comments on commit 5be66d1

Please sign in to comment.