diff --git a/.github/workflows/deploy.yaml b/.github/workflows/deploy.yaml index 93e85cc..b9eb84d 100644 --- a/.github/workflows/deploy.yaml +++ b/.github/workflows/deploy.yaml @@ -12,16 +12,12 @@ jobs: runs-on: ubuntu-latest environment: ${{ inputs.environment }} steps: - - name: Checkout repository - uses: actions/checkout@v2 - name: Declare image's tag shell: bash run: | - echo "sha_short=$(git rev-parse --short "$GITHUB_SHA")" >> "$GITHUB_ENV" + echo "sha_short=$(echo $GITHUB_SHA | cut -c 1-8)" >> $GITHUB_ENV - name: Deploy uses: appleboy/ssh-action@v1.1.0 - env: - sha_short: ${{ env.sha_short }} with: host: ${{ secrets.DEPLOY_HOST }} username: ${{ secrets.DEPLOY_USER }} @@ -31,4 +27,4 @@ jobs: cd ${{ secrets.DEPLOY_PATH }} && git pull microk8s ctr image import img.tar && rm img.tar cd infra/helm - microk8s helm upgrade -f ./qmra/${{ inputs.environment }}.values.yaml qmra ./qmra -n qmra --set app_secret_key.value=${{ secrets.APP_SECRET_KEY }},image.tag="$sha_short" \ No newline at end of file + microk8s helm upgrade -f ./qmra/${{ inputs.environment }}.values.yaml qmra ./qmra -n qmra --set app_secret_key.value=${{ secrets.APP_SECRET_KEY }},image.tag="$sha_short"