File tree Expand file tree Collapse file tree 1 file changed +22
-0
lines changed
Expand file tree Collapse file tree 1 file changed +22
-0
lines changed Original file line number Diff line number Diff line change 2424 with :
2525 ref : ${{ env.RELEASE_TAG }}
2626
27+ - name : Prepare signing certificate
28+ shell : pwsh
29+ env :
30+ CLOUDSQLCTL_SIGN_CERT_B64 : ${{ secrets.CLOUDSQLCTL_SIGN_CERT_B64 }}
31+ CLOUDSQLCTL_SIGN_PWD : ${{ secrets.CLOUDSQLCTL_SIGN_PWD }}
32+ run : |
33+ if (-not $env:CLOUDSQLCTL_SIGN_CERT_B64) {
34+ Write-Host "Signing cert not provided; skipping signing setup."
35+ exit 0
36+ }
37+ $certPath = Join-Path $env:RUNNER_TEMP "cloudsqlctl-signing.pfx"
38+ [IO.File]::WriteAllBytes($certPath, [Convert]::FromBase64String($env:CLOUDSQLCTL_SIGN_CERT_B64))
39+ "CLOUDSQLCTL_SIGN_CERT=$certPath" | Out-File -FilePath $env:GITHUB_ENV -Append
40+ "CLOUDSQLCTL_SIGN_PWD=$env:CLOUDSQLCTL_SIGN_PWD" | Out-File -FilePath $env:GITHUB_ENV -Append
41+
2742 - name : Use Node.js 22.x
2843 uses : actions/setup-node@v4
2944 with :
5469 - name : Build Installer
5570 run : npm run installer
5671
72+ - name : Sign artifacts
73+ if : ${{ env.CLOUDSQLCTL_SIGN_CERT != '' }}
74+ shell : pwsh
75+ run : |
76+ powershell -ExecutionPolicy Bypass -File tools/sign-exe.ps1 -ExePath "bin/cloudsqlctl.exe"
77+ powershell -ExecutionPolicy Bypass -File tools/sign-exe.ps1 -ExePath "dist/cloudsqlctl-setup.exe"
78+
5779 - name : Generate Docs
5880 run : npm run docs:generate
5981
You can’t perform that action at this time.
0 commit comments