java-workflow/.github/workflows/maven-thrift-deploy.yml
2022-01-19 18:04:12 +03:00

37 lines
1.2 KiB
YAML

name: Maven Deploy Artifact
on:
workflow_call:
secrets:
server-username:
required: true
server-password:
required: true
deploy-secret-key:
required: true
deploy-secret-key-password:
required: true
jobs:
deploy:
runs-on: ubuntu-20.04
steps:
- name: Install thrift
uses: valitydev/action-setup-thrift@v0.0.5
- name: Checkout Repo
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Retrieve commit info
run: |
echo "::set-output name=COMMIT_NUMBER::$(git rev-list HEAD --count)"
echo "::set-output name=SHA_7::${GITHUB_SHA::7}"
id: commit_info
- name: Deploy package
uses: valitydev/action-deploy-jdk-package@v1.0.12
with:
server-username: ${{ secrets.server-username }}
server-password: ${{ secrets.server-password }}
deploy-secret-key: ${{ secrets.deploy-secret-key }}
deploy-secret-key-password: ${{ secrets.deploy-secret-key-password }}
maven-args: '-Dcommit.number=${{ steps.commit_info.outputs.COMMIT_NUMBER }} -Drevision="1.${{ steps.commit_info.outputs.COMMIT_NUMBER }}-${{ steps.commit_info.outputs.SHA_7 }}"'