-
Notifications
You must be signed in to change notification settings - Fork 0
66 lines (57 loc) · 2.13 KB
/
release.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
# This is a basic workflow to help you get started with Actions
name: Deployment
# Controls when the action will run.
# Triggers the workflow on release.
on:
release:
types: [published]
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "build"
build:
# The type of runner that the job will run on
runs-on: ubuntu-latest
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2
# Set up Java Environment
- name: Set up JDK 11
uses: actions/setup-java@v1
with:
java-version: 11
# Grant execute permission to the gradlew script
- name: Grant execute permission for gradlew
run: chmod +x gradlew
# Build the project with Gradle
- name: Build with Gradle
env:
packageUser: ${{ secrets.BALLERINA_BOT_USERNAME }}
packagePAT: ${{ secrets.BALLERINA_BOT_TOKEN }}
JAVA_OPTS: -DBALLERINA_DEV_COMPILE_BALLERINA_ORG=true
run: |
./gradlew build
# Build Ballerina Project
- name: Ballerina Build
uses: ballerina-platform/ballerina-action/@2201.3.1
with:
args:
pack ./asb-ballerina
env:
JAVA_HOME: /usr/lib/jvm/default-jvm
CONNECTION_STRING: ${{ secrets.CONNECTION_STRING }}
QUEUE_NAME: ${{ secrets.QUEUE_NAME }}
TOPIC_NAME: ${{ secrets.TOPIC_NAME }}
SUBSCRIPTION_NAME1: ${{ secrets.SUBSCRIPTION_NAME1 }}
SUBSCRIPTION_NAME2: ${{ secrets.SUBSCRIPTION_NAME2 }}
SUBSCRIPTION_NAME3: ${{ secrets.SUBSCRIPTION_NAME3 }}
# Push to Ballerina Central
- name: Ballerina Push
uses: ballerina-platform/ballerina-action/@2201.3.1
with:
args:
push
env:
WORKING_DIR: ./asb-ballerina
BALLERINA_CENTRAL_ACCESS_TOKEN: ${{ secrets.BALLERINA_CENTRAL_ACCESS_TOKEN }}
JAVA_HOME: /usr/lib/jvm/default-jvm