Publish Spark metadata client #45
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 Spark metadata client | |
on: | |
workflow_dispatch: | |
jobs: | |
publish-spark-metadata-client: | |
name: Publish Spark metadata client | |
runs-on: ubuntu-20.04 | |
environment: Treeverse signing | |
steps: | |
- name: Check-out code | |
uses: actions/checkout@v3 | |
- uses: actions/setup-java@v3 | |
with: | |
distribution: 'adopt-hotspot' | |
java-version: '8' | |
cache: 'sbt' | |
- name: validate format | |
working-directory: clients/spark | |
run: sbt scalafmtCheck | |
- name: validate unused | |
working-directory: clients/spark | |
run: sbt "scalafix --check" | |
- name: Install secret key for signing | |
run: | | |
echo -e '${{ secrets.OSSRH_GPG_SECRET_KEY }}' | gpg --batch --import | |
gpg --list-secret-keys --keyid-format LONG | |
- name: Prepare publish credentials | |
run: | | |
mkdir -p ~/.sbt | |
cat << EOS > ~/.sbt/credentials | |
realm=Amazon S3" > ~/.sbt/credentials | |
host=treeverse-clients-us-east.s3.amazonaws.com | |
user=${AWS_ACCESS_KEY_ID} | |
password=${AWS_SECRET_ACCESS_KEY} | |
EOS | |
cat << EOS > ~/.sbt/sonatype_credentials | |
realm=Sonatype Nexus Repository Manager | |
host=s01.oss.sonatype.org | |
user=${OSSRH_USERNAME} | |
password=${OSSRH_TOKEN} | |
EOS | |
env: | |
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
OSSRH_USERNAME: ${{ secrets.OSSRH_USERNAME }} | |
OSSRH_TOKEN: ${{ secrets.OSSRH_TOKEN }} | |
- name: Publish artifacts | |
run: make publish-scala | |
env: | |
AWS_REGION: us-east-1 | |
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |