Release version: 2.0.7 #20
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Publish tag release | |
on: | |
push: | |
tags: | |
- 'v[0-9]+.[0-9]+.[0-9]+' # Push events to matching semver 20.15.10 | |
jobs: | |
publish: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
submodules: true | |
- name: Set up JDK 1.8 | |
uses: actions/setup-java@v3 | |
with: | |
java-version: '8' | |
distribution: 'zulu' | |
- name: Build with Gradle | |
run: ./gradlew build | |
- name: Install expect | |
run: | | |
sudo apt-get update -y | |
sudo apt-get -y install expect dpkg-sig | |
- name: Sign RPM and Deb | |
run: | | |
test -d $HOME/.gnupg || ( mkdir $HOME/.gnupg && chmod go-rwx $HOME/.gnupg ) | |
GPG_PATH=$HOME/.gnupg scripts/sign-packages.sh $PWD/rd-cli-tool/build/distributions | |
env: | |
SIGNING_KEY_B64: ${{ secrets.SIGNING_KEY_B64 }} | |
RUNDECK_SIGNING_PASSWORD: ${{ secrets.SIGNING_PASSWORD }} | |
RUNDECK_SIGNING_KEYID: [email protected] | |
- name: Release | |
uses: softprops/action-gh-release@v1 | |
with: | |
fail_on_unmatched_files: true | |
files: | | |
rd-cli-tool/build/distributions/rd-*.zip | |
rd-cli-tool/build/distributions/rundeck-cli-*-1.noarch.rpm | |
rd-cli-tool/build/distributions/rundeck-cli_*-1_all.deb | |
rd-cli-tool/build/libs/rundeck-cli-*-all.jar | |
rd-api-client/build/libs/rd-api-client-*.jar | |
rd-cli-lib/build/libs/rd-cli-lib-*.jar | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- name: Publish to Maven Central | |
run: ./gradlew -PsigningKey=${SIGNING_KEY_B64} -PsigningPassword=${SIGNING_PASSWORD} -PsonatypeUsername=${SONATYPE_USERNAME} -PsonatypePassword=${SONATYPE_PASSWORD} publishToSonatype closeAndReleaseSonatypeStagingRepository | |
env: | |
SONATYPE_USERNAME: ${{ secrets.SONATYPE_USERNAME }} | |
SONATYPE_PASSWORD: ${{ secrets.SONATYPE_PASSWORD }} | |
SIGNING_KEY_B64: ${{ secrets.SIGNING_KEY_B64 }} | |
SIGNING_PASSWORD: ${{ secrets.SIGNING_PASSWORD }} | |
- name: Install Ruby | |
uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: 2.7.2 | |
- name: Install packagecloud.io CLI | |
run: | | |
gem install package_cloud | |
- name: Publish to Packagecloud | |
run: | | |
package_cloud push pagerduty/rundeck/any/any rd-cli-tool/build/distributions/rundeck-cli_*-1_all.deb | |
package_cloud push pagerduty/rundeckpro/any/any rd-cli-tool/build/distributions/rundeck-cli_*-1_all.deb | |
package_cloud push pagerduty/rundeck/rpm_any/rpm_any rd-cli-tool/build/distributions/rundeck-cli-*-1.noarch.rpm | |
package_cloud push pagerduty/rundeckpro/rpm_any/rpm_any rd-cli-tool/build/distributions/rundeck-cli-*-1.noarch.rpm | |
env: | |
PACKAGECLOUD_TOKEN: ${{ secrets.PKGCLD_WRITE_TOKEN }} |