8000 Testing triggering of build process on other repositories · utPLSQL/utPLSQL@71cb922 · GitHub
[go: up one dir, main page]

Skip to content

Commit 71cb922

Browse files
committed
Testing triggering of build process on other repositories
1 parent d3eb9da commit 71cb922

File tree

1 file changed

+177
-177
lines changed

1 file changed

+177
-177
lines changed

.github/workflows/build.yml

Lines changed: 177 additions & 177 deletions
< 1E0A td data-grid-cell-id="diff-5c3fa597431eda03ac3339ae6bf7f05e1a50d6fc7333679ec38e21b337cb6721-90-16-2" data-line-anchor="diff-5c3fa597431eda03ac3339ae6bf7f05e1a50d6fc7333679ec38e21b337cb6721L90" data-selected="false" role="gridcell" style="background-color:var(--diffBlob-deletionLine-bgColor, var(--diffBlob-deletion-bgColor-line));padding-right:24px" tabindex="-1" valign="top" class="focusable-grid-cell diff-text-cell left-side-diff-cell border-right left-side">-
id: update-project-version
Original file line numberDiff line numberDiff line change
@@ -14,170 +14,170 @@ defaults:
1414

1515
jobs:
1616

17-
build:
18-
name: Build and test on ${{matrix.db_version_name}} DB
19-
runs-on: ubuntu-latest
20-
env:
21-
ORACLE_VERSION: ${{matrix.oracle-version}}
22-
CONNECTION_STR: ${{matrix.connection-str}}
23-
ORACLE_PASSWORD: oracle
24-
DOCKER_VOLUME: ${{matrix.docker-volume}}
25-
strategy:
26-
fail-fast: false
27-
matrix:
28-
include:
29-
- oracle-version: "gvenzl/oracle-xe:11-full"
30-
connection-str: '127.0.0.1:1521/XE'
31-
id: 1
32-
db_version_name: '11xe'
33-
# TODO - need to add healthcheck.sh into our containers
34-
# - oracle-version: "utplsqlv3/oracledb:12c-r1-se2-small"
35-
# connection-str: '127.0.0.1:1521/ORCLCDB'
36-
# id: 2
37-
# db_version_name: '12.1se'
38-
# - oracle-version: "utplsqlv3/oracledb:12c-r2-se2-small"
39-
# connection-str: '127.0.0.1:1521/ORCLCDB'
40-
# id: 3
41-
# db_version_name: '12.2se'
42-
- oracle-version: "gvenzl/oracle-xe:18-slim"
43-
connection-str: '127.0.0.1:1521/XE'
44-
id: 4
45-
db_version_name: '18xe'
46-
# - oracle-version: "utplsqlv3/oracledb:18c-se2-small"
47-
# connection-str: '127.0.0.1:1521/ORCLCDB'
48-
# id: 5
49-
# db_version_name: '18se'
50-
# - oracle-version: "utplsqlv3/oracledb:19c-se2-small"
51-
# connection-str: '127.0.0.1:1521/ORCLCDB'
52-
# id: 6
53-
# db_version_name: '19se'
54-
- oracle-version: "gvenzl/oracle-xe:21-slim"
55-
connection-str: '127.0.0.1:1521/XE'
56-
id: 7
57-
db_version_name: '21xe'
58-
59-
services:
60-
oracle:
61-
image: ${{matrix.oracle-version}}
62-
env:
63-
ORACLE_PASSWORD: oracle
64-
MATRIX_JOB_ID: ${{matrix.id}}
65-
credentials:
66-
username: ${{ secrets.DOCKER_USER }}
67-
password: ${{ secrets.DOCKER_PASSWORD }}
68-
ports:
69-
- 1521:1521
70-
options: >-
71-
--health-cmd healthcheck.sh
72-
--health-interval 10s
73-
--health-timeout 5s
74-
--health-retries 10
75-
76-
steps:
77-
- uses: actions/checkout@v2
78-
with:
79-
fetch-depth: 0
80-
- uses: c-py/action-dotenv-to-setenv@v2
81-
with:
82-
env-file: .github/variables/.env
83-
- uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action
84-
85-
- name: Set build version number env variables
86-
id: set-build-version-number-vars
87-
run: .github/scripts/set_version_numbers_env.sh
88-
89-
- name: Update project version & build number to verify that code is deployable after the update
90
91-
run: .github/scripts/update_project_version.sh
92-
93-
- name: Download utPLSQL release for testing
94-
# For PR build - test using target branch as framework, for branch build use self as testing framework
95-
run: git clone --depth=1 --branch=${CI_HEAD_REF:-$CI_REF_NAME} https://github.com/utPLSQL/utPLSQL.git $UTPLSQL_DIR
96-
97-
- name: Update privileges on sources
98-
run: chmod -R go+w ./{source,test,examples,${UTPLSQL_DIR}/source}
99-
100-
- name: Add OJDBC home
101-
id: get-ojdbc
102-
run: mkdir -p ${OJDBC_HOME} && curl -Lk -o ${OJDBC_HOME}/ojdbc8.jar ${OJDBC_URL}/ojdbc8.jar && curl -Lk -o ${OJDBC_HOME}/orai18n.jar ${OJDBC_URL}/orai18n.jar
103-
104-
- name: Install utPLSQL-cli
105-
id: install-utplsql-cli
106-
run: curl -Lk -o utPLSQL-cli.zip "https://github.com/utPLSQL/utPLSQL-cli/releases/download/v3.1.8/utPLSQL-cli.zip" && unzip utPLSQL-cli.zip && chmod -R u+x utPLSQL-cli
107-
108-
- name: Install utPLSQL
109-
id: install-utplsql
110-
run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install.sh
111-
112-
- name: Install utPLSQL release
113-
id: install-utplsql-release
114-
run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install_utplsql_release.sh
115-
116-
- name: Run Examples
117-
id: run-examples
118-
run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/run_examples.sh
119-
120-
- name: Install tests
121-
id: install-tests
122-
run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} test/install_tests.sh
123-
124-
- name: Run Tests
125-
id: run-tests
126-
run: bash test/run_tests.sh
127-
128-
- name: Validate utPLSQL reports format
129-
id: validate-reports-format
130-
run: bash .github/scripts/validate_report_files.sh
131-
132-
- name: SonarCloud Scan
133-
id: sonar
134-
uses: SonarSource/sonarcloud-github-action@master
135-
env:
136-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
137-
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
138-
139-
publish:
140-
name: Deploy documentation
141-
needs: [ build ]
142-
concurrency: publish
143-
runs-on: ubuntu-latest
144-
if: |
145-
github.repository == 'utPLSQL/utPLSQL' &&
146-
github.base_ref == null &&
147-
( startsWith( github.ref, 'refs/heads/release/v' )
148-
|| github.ref == 'refs/heads/develop'
149-
|| github.ref == 'refs/heads/feature/github_actions'
150-
)
151-
steps:
152-
- uses: actions/checkout@v2
153-
with:
154-
fetch-depth: 0
155-
- uses: c-py/action-dotenv-to-setenv@v2
156-
with:
157-
env-file: .github/variables/.env
158-
- uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action
159-
- name: Set buid version number env variables
160-
id: set-build-version-number-vars
161-
run: .github/scripts/set_version_numbers_env.sh
162-
- name: Update project version & build number in source code and documentation
163-
id: update-project-version
164-
run: .github/scripts/update_project_version.sh
165-
- name: Push version update to repository
166-
id: push-version-number-update
167-
run: |
168-
git add sonar-project.properties VERSION source/* docs/*
169-
git commit -m 'Updated project version after build [skip ci]'
170-
git push --quiet origin HEAD:${CI_ACTION_REF_NAME}
171-
- name: Copy and push documentation to utPLSQL-github-io repo
172-
id: push-documentation
173-
env:
174-
API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }}
175-
run: .github/scripts/push_docs_to_github_io.sh
17+
# build:
18+
# name: Build and test on ${{matrix.db_version_name}} DB
19+
# runs-on: ubuntu-latest
20+
# env:
21+
# ORACLE_VERSION: ${{matrix.oracle-version}}
22 6377 +
# CONNECTION_STR: ${{matrix.connection-str}}
23+
# ORACLE_PASSWORD: oracle
24+
# DOCKER_VOLUME: ${{matrix.docker-volume}}
25+
# strategy:
26+
# fail-fast: false
27+
# matrix:
28+
# include:
29+
# - oracle-version: "gvenzl/oracle-xe:11-full"
30+
# connection-str: '127.0.0.1:1521/XE'
31+
# id: 1
32+
# db_version_name: '11xe'
33+
## TODO - need to add healthcheck.sh into our containers
34+
## - oracle-version: "utplsqlv3/oracledb:12c-r1-se2-small"
35+
## connection-str: '127.0.0.1:1521/ORCLCDB'
36+
## id: 2
37+
## db_version_name: '12.1se'
38+
## - oracle-version: "utplsqlv3/oracledb:12c-r2-se2-small"
39 A851 +
## connection-str: '127.0.0.1:1521/ORCLCDB'
40+
## id: 3
41+
## db_version_name: '12.2se'
42+
# - oracle-version: "gvenzl/oracle-xe:18-slim"
43+
# connection-str: '127.0.0.1:1521/XE'
44+
# id: 4
45+
# db_version_name: '18xe'
46+
## - oracle-version: "utplsqlv3/oracledb:18c-se2-small"
47+
## connection-str: '127.0.0.1:1521/ORCLCDB'
48+
## id: 5
49+
## db_version_name: '18se'
50+
## - oracle-version: "utplsqlv3/oracledb:19c-se2-small"
51+
## connection-str: '127.0.0.1:1521/ORCLCDB'
52+
## id: 6
53+
## db_version_name: '19se'
54+
# - oracle-version: "gvenzl/oracle-xe:21-slim"
55+
# connection-str: '127.0.0.1:1521/XE'
56+
# id: 7
57+
# db_version_name: '21xe'
58+
#
59+
# services:
60+
# oracle:
61+
# image: ${{matrix.oracle-version}}
62+
# env:
63+
# ORACLE_PASSWORD: oracle
64+
# MATRIX_JOB_ID: ${{matrix.id}}
65+
# credentials:
66+
# username: ${{ secrets.DOCKER_USER }}
67+
# password: ${{ secrets.DOCKER_PASSWORD }}
68+
# ports:
69+
# - 1521:1521
70+
# options: >-
71+
# --health-cmd healthcheck.sh
72+
# --health-interval 10s
73+
# --health-timeout 5s
74+
# --health-retries 10
75+
#
76+
# steps:
77+
# - uses: actions/checkout@v2
78+
# with:
79+
# fetch-depth: 0
80+
# - uses: c-py/action-dotenv-to-setenv@v2
81+
# with:
82+
# env-file: .github/variables/.env
83+
# - uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action
84+
#
85+
# - name: Set build version number env variables
86+
# id: set-build-version-number-vars
87+
# run: .github/scripts/set_version_numbers_env.sh
88+
#
89+
# - name: Update project version & build number to verify that code is deployable after the update
90+
# id: update-project-version
91+
# run: .github/scripts/update_project_version.sh
92+
#
93+
# - name: Download utPLSQL release for testing
94+
## For PR build - test using target branch as framework, for branch build use self as testing framework
95+
# run: git clone --depth=1 --branch=${CI_HEAD_REF:-$CI_REF_NAME} https://github.com/utPLSQL/utPLSQL.git $UTPLSQL_DIR
96+
#
97+
# - name: Update privileges on sources
98+
# run: chmod -R go+w ./{source,test,examples,${UTPLSQL_DIR}/source}
99+
#
100+
# - name: Add OJDBC home
101+
# id: get-ojdbc
102+
# run: mkdir -p ${OJDBC_HOME} && curl -Lk -o ${OJDBC_HOME}/ojdbc8.jar ${OJDBC_URL}/ojdbc8.jar && curl -Lk -o ${OJDBC_HOME}/orai18n.jar ${OJDBC_URL}/orai18n.jar
103+
#
104+
# - name: Install utPLSQL-cli
105+
# id: install-utplsql-cli
106+
# run: curl -Lk -o utPLSQL-cli.zip "https://github.com/utPLSQL/utPLSQL-cli/releases/download/v3.1.8/utPLSQL-cli.zip" && unzip utPLSQL-cli.zip && chmod -R u+x utPLSQL-cli
107+
#
108+
# - name: Install utPLSQL
109+
# id: install-utplsql
110+
# run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install.sh
111+
#
112+
# - name: Install utPLSQL release
113+
# id: install-utplsql-release
114+
# run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install_utplsql_release.sh
115+
#
116+
# - name: Run Examples
117+
# id: run-examples
118+
# run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/run_examples.sh
119+
#
120+
# - name: Install tests
121+
# id: install-tests
122+
# run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} test/install_tests.sh
123+
#
124+
# - name: Run Tests
125+
# id: run-tests
126+
# run: bash test/run_tests.sh
127+
#
128+
# - name: Validate utPLSQL reports format
129+
# id: validate-reports-format
130+
# run: bash .github/scripts/validate_report_files.sh
131+
#
132+
# - name: SonarCloud Scan
133+
# id: sonar
134+
# uses: SonarSource/sonarcloud-github-action@master
135+
# env:
136+
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
137+
# SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
138+
#
139+
# publish:
140+
# name: Deploy documentation
141+
# needs: [ build ]
142+
# concurrency: publish
143+
# runs-on: ubuntu-latest
144+
# if: |
145+
# github.repository == 'utPLSQL/utPLSQL' &&
146+
# github.base_ref == null &&
147+
# ( startsWith( github.ref, 'refs/heads/release/v' )
148+
# || github.ref == 'refs/heads/develop'
149+
# || github.ref == 'refs/heads/feature/github_actions'
150+
# )
151+
# steps:
152+
# - uses: actions/checkout@v2
153+
# with:
154+
# fetch-depth: 0
155+
# - uses: c-py/action-dotenv-to-setenv@v2
156+
# with:
157+
# env-file: .github/variables/.env
158+
# - uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action
159+
# - name: Set buid version number env variables
160+
# id: set-build-version-number-vars
161+
# run: .github/scripts/set_version_numbers_env.sh
162+
# - name: Update project version & build number in source code and documentation
163+
# id: update-project-version
164+
# run: .github/scripts/update_project_version.sh
165+
# - name: Push version update to repository
166+
# id: push-version-number-update
167+
# run: |
168+
# git add sonar-project.properties VERSION source/* docs/*
169+
# git commit -m 'Updated project version after build [skip ci]'
170+
# git push --quiet origin HEAD:${CI_ACTION_REF_NAME}
171+
# - name: Copy and push documentation to utPLSQL-github-io repo
172+
# id: push-documentation
173+
# env:
174+
# API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }}
175+
# run: .github/scripts/push_docs_to_github_io.sh
176176

177177
dispatch:
178178
name: Dispatch downstream builds
179179
concurrency: trigger
180-
needs: [ build, publish ]
180+
# needs: [ build, publish ]
181181
runs-on: ubuntu-latest
182182
if: |
183183
github.repository == 'utPLSQL/utPLSQL' &&
@@ -188,28 +188,28 @@ jobs:
188188
)
189189
strategy:
190190
matrix:
191-
repo: ['utPLSQL/utPLSQL-maven-plugin', 'utPLSQL/utPLSQL-demo-project']
191+
repo: ['utPLSQL-maven-plugin', 'utPLSQL-demo-project']
192192
# repo: ['utPLSQL/utPLSQL-java-api', 'utPLSQL/utPLSQL-v2-v3-migration', 'utPLSQL/utPLSQL-cli', 'utPLSQL/utPLSQL-maven-plugin', 'utPLSQL/utPLSQL-demo-project']
193193
steps:
194194
- name: Repository Dispatch
195195
uses: peter-evans/repository-dispatch@v1
196196
with:
197197
token: ${{ secrets.API_TOKEN_GITHUB }}
198-
repository: ${{ matrix.repo }}
198+
repository: ${{ join( 'utPLSQL/', matrix.repo ) }}
199199
event-type: utPLSQL-build
200200

201-
slack-workflow-status:
202-
if: always()
203-
name: Post Workflow Status To Slack
204-
needs: [ build, publish, dispatch ]
205-
runs-on: ubuntu-latest
206-
steps:
207-
- name: Slack Workflow Notification
208-
uses: Gamesight/slack-workflow-status@master
209-
with:
210-
# Required Input
211-
repo_token: ${{secrets.GITHUB_TOKEN}}
212-
slack_webhook_url: ${{secrets.SLACK_WEBHOOK_URL}}
213-
# Optional Input
214-
name: 'Github Actions[bot]'
215-
icon_url: 'https://octodex.github.com/images/mona-the-rivetertocat.png'
201+
# slack-workflow-status:
202+
# if: always()
203+
# name: Post Workflow Status To Slack
204+
# needs: [ build, publish, dispatch ]
205+
# runs-on: ubuntu-latest
206+
# steps:
207+
# - name: Slack Workflow Notification
208+
# uses: Gamesight/slack-workflow-status@master
209+
# with:
210+
# # Required Input
211+
# repo_token: ${{secrets.GITHUB_TOKEN}}
212+
# slack_webhook_url: ${{secrets.SLACK_WEBHOOK_URL}}
213+
# # Optional Input
214+
# name: 'Github Actions[bot]'
215+
# icon_url: 'https://octodex.github.com/images/mona-the-rivetertocat.png'

0 commit comments

Comments
 (0)
0