mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-25 07:33:57 -06:00
parallelize msi and exe creation
Contributes to CURA-8415
This commit is contained in:
parent
67caa185db
commit
f2c68fe2ce
1 changed files with 68 additions and 29 deletions
97
.github/workflows/windows.yml
vendored
97
.github/workflows/windows.yml
vendored
|
@ -84,6 +84,9 @@ jobs:
|
||||||
cura-installer-create:
|
cura-installer-create:
|
||||||
runs-on: ${{ inputs.operating_system }}
|
runs-on: ${{ inputs.operating_system }}
|
||||||
|
|
||||||
|
outputs:
|
||||||
|
INSTALLER_FILENAME: ${{ steps.filename.outputs.INSTALLER_FILENAME }}
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
|
@ -110,16 +113,6 @@ jobs:
|
||||||
- name: Create the default Conan profile
|
- name: Create the default Conan profile
|
||||||
run: conan profile new default --detect --force
|
run: conan profile new default --detect --force
|
||||||
|
|
||||||
- name: Create PFX certificate from BASE64_PFX_CONTENT secret
|
|
||||||
id: create-pfx
|
|
||||||
env:
|
|
||||||
PFX_CONTENT: ${{ secrets.WIN_CERT_INSTALLER_CER }}
|
|
||||||
run: |
|
|
||||||
$pfxPath = Join-Path -Path $env:RUNNER_TEMP -ChildPath "cert.pfx";
|
|
||||||
$encodedBytes = [System.Convert]::FromBase64String($env:PFX_CONTENT);
|
|
||||||
Set-Content $pfxPath -Value $encodedBytes -AsByteStream;
|
|
||||||
echo "PFX_PATH=$pfxPath" >> $env:GITHUB_OUTPUT;
|
|
||||||
|
|
||||||
- name: Get Conan configuration
|
- name: Get Conan configuration
|
||||||
run: conan config install https://github.com/Ultimaker/conan-config.git
|
run: conan config install https://github.com/Ultimaker/conan-config.git
|
||||||
|
|
||||||
|
@ -206,49 +199,95 @@ jobs:
|
||||||
for package in pkg_resources.working_set:
|
for package in pkg_resources.working_set:
|
||||||
f.writelines(f"`{package.key}/{package.version}`\n")
|
f.writelines(f"`{package.key}/{package.version}`\n")
|
||||||
|
|
||||||
|
- name: upload the dist folder
|
||||||
|
uses: actions/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: dist
|
||||||
|
path: |
|
||||||
|
dist/
|
||||||
|
retention-days: 5
|
||||||
|
|
||||||
|
cura-installer-create-exe:
|
||||||
|
needs: [ cura-installer-create ]
|
||||||
|
runs-on: ${{ inputs.operating_system }}
|
||||||
|
steps:
|
||||||
|
- name: Download the dist
|
||||||
|
uses: actions/download-artifact@v3
|
||||||
|
with:
|
||||||
|
name: dist
|
||||||
|
|
||||||
|
- name: Create PFX certificate from BASE64_PFX_CONTENT secret
|
||||||
|
id: create-pfx
|
||||||
|
env:
|
||||||
|
PFX_CONTENT: ${{ secrets.WIN_CERT_INSTALLER_CER }}
|
||||||
|
run: |
|
||||||
|
$pfxPath = Join-Path -Path $env:RUNNER_TEMP -ChildPath "cert.pfx";
|
||||||
|
$encodedBytes = [System.Convert]::FromBase64String($env:PFX_CONTENT);
|
||||||
|
Set-Content $pfxPath -Value $encodedBytes -AsByteStream;
|
||||||
|
echo "PFX_PATH=$pfxPath" >> $env:GITHUB_OUTPUT;
|
||||||
|
|
||||||
- name: Create the Windows exe installer (Powershell)
|
- name: Create the Windows exe installer (Powershell)
|
||||||
run: |
|
run: |
|
||||||
python ..\cura_inst\packaging\NSIS\create_windows_installer.py ../cura_inst . "${{ steps.filename.outputs.INSTALLER_FILENAME }}.exe"
|
python ..\cura_inst\packaging\NSIS\create_windows_installer.py ../cura_inst . "${{ needs.cura-installer-create.outputs.INSTALLER_FILENAME }}.exe"
|
||||||
working-directory: dist
|
|
||||||
|
|
||||||
- name: Create the Windows msi installer (Powershell)
|
|
||||||
run: |
|
|
||||||
python ..\cura_inst\packaging\msi\create_windows_msi.py ..\cura_inst .\UltiMaker-Cura "${{ steps.filename.outputs.INSTALLER_FILENAME }}.msi" "$Env:CURA_APP_NAME"
|
|
||||||
working-directory: dist
|
working-directory: dist
|
||||||
|
|
||||||
- name: Sign the Windows exe installer (Powershell)
|
- name: Sign the Windows exe installer (Powershell)
|
||||||
env:
|
env:
|
||||||
PFX_PATH: ${{ steps.create-pfx.outputs.PFX_PATH }}
|
PFX_PATH: ${{ steps.create-pfx.outputs.PFX_PATH }}
|
||||||
run: |
|
run: |
|
||||||
& "C:/Program Files (x86)/Windows Kits/10/bin/10.0.17763.0/x86/signtool.exe" sign /f $Env:PFX_PATH /p "$Env:WIN_CERT_INSTALLER_CER_PASS" /fd SHA256 /t http://timestamp.digicert.com "${{ steps.filename.outputs.INSTALLER_FILENAME }}.exe"
|
& "C:/Program Files (x86)/Windows Kits/10/bin/10.0.17763.0/x86/signtool.exe" sign /f $Env:PFX_PATH /p "$Env:WIN_CERT_INSTALLER_CER_PASS" /fd SHA256 /t http://timestamp.digicert.com "${{ needs.cura-installer-create.outputs.INSTALLER_FILENAME }}.exe"
|
||||||
|
working-directory: dist
|
||||||
|
|
||||||
|
- name: Upload the exe
|
||||||
|
uses: actions/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: ${{ needs.cura-installer-create.outputs.INSTALLER_FILENAME }}-exe
|
||||||
|
path: |
|
||||||
|
dist/${{ needs.cura-installer-create.outputs.INSTALLER_FILENAME }}.exe
|
||||||
|
retention-days: 5
|
||||||
|
|
||||||
|
cura-installer-create-msi:
|
||||||
|
needs: [ cura-installer-create ]
|
||||||
|
runs-on: ${{ inputs.operating_system }}
|
||||||
|
steps:
|
||||||
|
- name: Download the dist
|
||||||
|
uses: actions/download-artifact@v3
|
||||||
|
with:
|
||||||
|
name: dist
|
||||||
|
|
||||||
|
- name: Create PFX certificate from BASE64_PFX_CONTENT secret
|
||||||
|
id: create-pfx
|
||||||
|
env:
|
||||||
|
PFX_CONTENT: ${{ secrets.WIN_CERT_INSTALLER_CER }}
|
||||||
|
run: |
|
||||||
|
$pfxPath = Join-Path -Path $env:RUNNER_TEMP -ChildPath "cert.pfx";
|
||||||
|
$encodedBytes = [System.Convert]::FromBase64String($env:PFX_CONTENT);
|
||||||
|
Set-Content $pfxPath -Value $encodedBytes -AsByteStream;
|
||||||
|
echo "PFX_PATH=$pfxPath" >> $env:GITHUB_OUTPUT;
|
||||||
|
|
||||||
|
- name: Create the Windows msi installer (Powershell)
|
||||||
|
run: |
|
||||||
|
python ..\cura_inst\packaging\msi\create_windows_msi.py ..\cura_inst .\UltiMaker-Cura "${{ needs.cura-installer-create.outputs.INSTALLER_FILENAME }}.msi" "$Env:CURA_APP_NAME"
|
||||||
working-directory: dist
|
working-directory: dist
|
||||||
|
|
||||||
- name: Sign the Windows msi installer (Powershell)
|
- name: Sign the Windows msi installer (Powershell)
|
||||||
env:
|
env:
|
||||||
PFX_PATH: ${{ steps.create-pfx.outputs.PFX_PATH }}
|
PFX_PATH: ${{ steps.create-pfx.outputs.PFX_PATH }}
|
||||||
run: |
|
run: |
|
||||||
& "C:/Program Files (x86)/Windows Kits/10/bin/10.0.17763.0/x86/signtool.exe" sign /f $Env:PFX_PATH /p "$Env:WIN_CERT_INSTALLER_CER_PASS" /fd SHA256 /t http://timestamp.digicert.com "${{ steps.filename.outputs.INSTALLER_FILENAME }}.msi"
|
& "C:/Program Files (x86)/Windows Kits/10/bin/10.0.17763.0/x86/signtool.exe" sign /f $Env:PFX_PATH /p "$Env:WIN_CERT_INSTALLER_CER_PASS" /fd SHA256 /t http://timestamp.digicert.com "${{ needs.cura-installer-create.outputs.INSTALLER_FILENAME }}.msi"
|
||||||
working-directory: dist
|
working-directory: dist
|
||||||
|
|
||||||
- name: Upload the exe
|
|
||||||
uses: actions/upload-artifact@v3
|
|
||||||
with:
|
|
||||||
name: ${{ steps.filename.outputs.INSTALLER_FILENAME }}-exe
|
|
||||||
path: |
|
|
||||||
dist/${{ steps.filename.outputs.INSTALLER_FILENAME }}.exe
|
|
||||||
retention-days: 5
|
|
||||||
|
|
||||||
- name: Upload the msi
|
- name: Upload the msi
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: ${{ steps.filename.outputs.INSTALLER_FILENAME }}-msi
|
name: ${{ needs.cura-installer-create.outputs.INSTALLER_FILENAME }}-msi
|
||||||
path: |
|
path: |
|
||||||
dist/${{ steps.filename.outputs.INSTALLER_FILENAME }}.msi
|
dist/${{ needs.cura-installer-create.outputs.INSTALLER_FILENAME }}.msi
|
||||||
retention-days: 5
|
retention-days: 5
|
||||||
|
|
||||||
notify-export:
|
notify-export:
|
||||||
if: ${{ always() }}
|
if: ${{ always() }}
|
||||||
needs: [ cura-installer-create ]
|
needs: [ cura-installer-create-exe, cura-installer-create-msi ]
|
||||||
|
|
||||||
uses: ultimaker/cura/.github/workflows/notify.yml@main
|
uses: ultimaker/cura/.github/workflows/notify.yml@main
|
||||||
with:
|
with:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue