Skip to content

Commit

Permalink
cicd: Added new jobs and needs to release step #TASK-6204 #TASK-6185
Browse files Browse the repository at this point in the history
  • Loading branch information
juanfeSanahuja committed May 14, 2024
1 parent 4138612 commit 334fe85
Showing 1 changed file with 54 additions and 12 deletions.
66 changes: 54 additions & 12 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,39 +7,81 @@ on:
workflow_dispatch:

jobs:
build:
# Add the build-hdp and deploy-docker-hdp jobs
build-hdp:
uses: opencb/java-common-libs/.github/workflows/build-java-app-workflow.yml@develop
with:
maven_opts: -P hdp3.1,RClient -Dopencga.war.name=opencga -Dcheckstyle.skip

deploy-maven:
uses: opencb/java-common-libs/.github/workflows/deploy-maven-repository-workflow.yml@develop
needs: build
deploy-docker-hdp:
uses: opencb/java-common-libs/.github/workflows/deploy-docker-hub-workflow.yml@develop
needs: build-hdp
with:
maven_opts: -P hdp3.1 -Dopencga.war.name=opencga
cli: python3 ./build/cloud/docker/docker-build.py push --images base,init --tag ${{ needs.build-hdp.outputs.version }}
secrets: inherit

# Add the build-hdi and deploy-docker-hdi jobs
build-hdi:
uses: opencb/java-common-libs/.github/workflows/build-java-app-workflow.yml@develop
with:
maven_opts: -P hdi5.1,RClient -Dopencga.war.name=opencga -Dcheckstyle.skip

deploy-docker-hdi:
uses: opencb/java-common-libs/.github/workflows/deploy-docker-hub-workflow.yml@develop
needs: build-hdi
with:
cli: python3 ./build/cloud/docker/docker-build.py push --images base,init --tag ${{ needs.build-hdi.outputs.version }}
secrets: inherit

deploy-docker:
# Add the build-emr and deploy-docker-emr jobs
build-emr:
uses: opencb/java-common-libs/.github/workflows/build-java-app-workflow.yml@develop
with:
maven_opts: -P emr6.1,RClient -Dopencga.war.name=opencga -Dcheckstyle.skip

deploy-docker-emr:
uses: opencb/java-common-libs/.github/workflows/deploy-docker-hub-workflow.yml@develop
needs: build
needs: build-emr
with:
cli: python3 ./build/cloud/docker/docker-build.py push --images base,init --tag ${{ needs.build.outputs.version }}
cli: python3 ./build/cloud/docker/docker-build.py push --images base,init --tag ${{ needs.build-emr.outputs.version }}
secrets: inherit

# Add the build-emr613 and deploy-docker-emr613 jobs
build-emr613:
uses: opencb/java-common-libs/.github/workflows/build-java-app-workflow.yml@develop
with:
maven_opts: -P emr6.13,RClient -Dopencga.war.name=opencga -Dcheckstyle.skip

deploy-docker-emr613:
uses: opencb/java-common-libs/.github/workflows/deploy-docker-hub-workflow.yml@develop
needs: build-emr613
with:
cli: python3 ./build/cloud/docker/docker-build.py push --images base,init --tag ${{ needs.build-emr613.outputs.version }}
secrets: inherit

# Add the deploy-maven and deploy-python jobs they depend on the build-hdp job
deploy-maven:
uses: opencb/java-common-libs/.github/workflows/deploy-maven-repository-workflow.yml@develop
needs: build-hdp
with:
maven_opts: -P hdp3.1 -Dopencga.war.name=opencga
secrets: inherit

deploy-python:
uses: opencb/java-common-libs/.github/workflows/deploy-python-workflow.yml@develop
needs: build
needs: build-hdp
with:
cli: ./clients/python/python-build.sh push
artifact: build-folder
secrets: inherit

# Add the release job that depends on all the previous jobs
release:
uses: opencb/java-common-libs/.github/workflows/release-github-workflow.yml@develop
needs: [ build, deploy-maven, deploy-docker, deploy-python ]
needs: [ build-hdp, deploy-docker-hdp, build-hdi, deploy-docker-hdi, build-emr, deploy-docker-emr, build-emr613, deploy-docker-emr613, deploy-maven, deploy-docker, deploy-python ]
with:
artifact: build-folder
file: |
opencga-client-${{ needs.build.outputs.version }}.tar.gz
clients/R/opencgaR_${{ needs.build.outputs.version }}.tar.gz
opencga-client-${{ needs.build-hdp.outputs.version }}.tar.gz
clients/R/opencgaR_${{ needs.build-hdp.outputs.version }}.tar.gz

0 comments on commit 334fe85

Please sign in to comment.