Skip to content

Commit

Permalink
add release-binary reusable flow part 4
Browse files Browse the repository at this point in the history
  • Loading branch information
pirog committed Nov 19, 2024
1 parent a9e1adb commit 0d1e3e4
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 11 deletions.
14 changes: 7 additions & 7 deletions .github/workflows/dev-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,15 +45,15 @@ jobs:

# - lando-linux-x64-${{ github.sha }}
# - lando-macos-x64-${{ github.sha }}
# - lando-win-x64-${{ github.sha }}.exe
# - lando-win-x64-${{ github.sha }}

# - lando-linux-arm64-${{ github.sha }}-slim
# - lando-macos-arm64-${{ github.sha }}-slim
# - lando-win-arm64-${{ github.sha }}-slim.exe
# - lando-win-arm64-${{ github.sha }}-slim

- lando-linux-x64-${{ github.sha }}-slim
- lando-macos-x64-${{ github.sha }}-slim
- lando-win-x64-${{ github.sha }}-slim.exe
- lando-win-x64-${{ github.sha }}-slim

with:
download-pattern: packaged-lando-*
Expand Down Expand Up @@ -88,9 +88,9 @@ jobs:
- dev
- latest
with:
destination: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ matrix.alias }}${{ matrix.type }}.exe
destination: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ matrix.alias }}${{ matrix.type }}${{ matrix.os == 'win' && '.exe' || '' }}
download-pattern: signed-lando-*
source: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ github.sha }}${{ matrix.type }}.exe
source: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ github.sha }}${{ matrix.type }}${{ matrix.os == 'win' && '.exe' || '' }}

release-binary-branch:
uses: ./.github/workflows/release-binary.yml
Expand All @@ -110,9 +110,9 @@ jobs:
- -slim
-
with:
destination: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ github.ref_name }}${{ matrix.type }}.exe
destination: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ github.ref_name }}${{ matrix.type }}
download-pattern: signed-lando-*
source: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ github.sha }}${{ matrix.type }}.exe
source: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ github.sha }}${{ matrix.type }}


# - name: Configure S3 Credentials
Expand Down
8 changes: 5 additions & 3 deletions .github/workflows/release-binary.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,14 +43,16 @@ jobs:
- name: Mod as needed
run: |
mkdir -p /tmp/release-binary
cp -rf "/tmp/${{ github.sha }}/${{ inputs.source }}" "/tmp/release-binary/${{ inputs.destination }}"
cp -rf \
"/tmp/${{ github.sha }}/${{ inputs.source }}${{ runner.os == 'Windows' && !endsWith(inputs.source, '.exe') && '.exe' || '' }}" \
"/tmp/release-binary/${{ inputs.destination }}${{ runner.os == 'Windows' && !endsWith(inputs.destination, '.exe') && '.exe' || '' }}"
chmod +x /tmp/release-binary/*
ls -lsa /tmp/release-binary
- name: Upload signed binaries
uses: actions/upload-artifact@v4
with:
name: release-binary-${{ inputs.destination }}
name: release-binary-${{ inputs.destination }}${{ runner.os == 'Windows' && !endsWith(inputs.destination, '.exe') && '.exe' || '' }}"
overwrite: true
path: /tmp/release-binary/${{ inputs.destination }}
path: /tmp/release-binary/${{ inputs.destination }}${{ runner.os == 'Windows' && !endsWith(inputs.destination, '.exe') && '.exe' || '' }}"
if-no-files-found: error
retention-days: 1
2 changes: 1 addition & 1 deletion .github/workflows/sign-binary.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ jobs:
certificate-data: ${{ secrets.certificate-data }}
certificate-id: FY8GAUX282
certificate-password: ${{ secrets.certificate-password }}
file: ${{ steps.download-artifacts.outputs.download-path }}/${{ inputs.file }}
file: ${{ steps.download-artifacts.outputs.download-path }}/${{ inputs.file }}${{ runner.os == 'Windows' && !endsWith(inputs.file, '.exe') && '.exe' || '' }}
keylocker-api-key: ${{ secrets.keylocker-api-key }}
keylocker-cert-sha1-hash: ${{ secrets.keylocker-cert-sha1-hash }}
keylocker-host: https://clientauth.one.digicert.com
Expand Down

0 comments on commit 0d1e3e4

Please sign in to comment.