Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Disable UPX Compression #2212

Closed
wants to merge 5 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions .github/.goreleaser-unstable.yml
Original file line number Diff line number Diff line change
Expand Up @@ -62,10 +62,6 @@ builds:
- -s -w -X go.mondoo.com/cnquery/v9.Version={{.Version}} -X go.mondoo.com/cnquery/v9.Build={{.ShortCommit}} -X go.mondoo.com/cnquery/v9.Date={{.Date}}
hooks:
post:
- cmd: ./scripts/windows-upx.sh "{{ .Path }}"
output: true
env:
- TARGET={{ .Target }}
- cmd: jsign --storetype DIGICERTONE --alias "{{ .Env.SM_CERT_ALIAS }}" --storepass "{{ .Env.SM_API_KEY }}|{{ .Env.SM_CLIENT_CERT_FILE}}|{{ .Env.SM_CLIENT_CERT_PASSWORD }}" --tsaurl "http://timestamp.digicert.com" '{{ .Path }}'
nfpms:
-
Expand Down
15 changes: 11 additions & 4 deletions .github/workflows/goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,15 +34,15 @@ jobs:

- name: Skip Publish for Alpha and Beta Tags
id: skip-publish
if: contains(github.ref, 'alpha') || contains(github.ref, 'beta') || contains(github.ref, 'rc') || inputs.skip-publish == 'true'
if: contains(github.ref, 'alpha') || contains(github.ref, 'beta') || contains(github.ref, 'rc') || inputs.skip-publish == true
run: |
echo "Skipping publish for alpha and beta tags"
echo "skip-publish=true" >> $GITHUB_OUTPUT
echo "skip-publish=true" >> $GITHUB_ENV

- name: Import environment variables from file
run: cat ".github/env" >> $GITHUB_ENV

- name: Set up Go
uses: actions/setup-go@v4
with:
Expand Down Expand Up @@ -127,13 +127,13 @@ jobs:
QUILL_NOTARY_KEY_ID: ${{ secrets.APPLE_NOTARY_KEY_ID }}
QUILL_NOTARY_ISSUER: ${{ secrets.APPLE_NOTARY_ISSUER }}

- name: Run GoReleaser (w/o Docker Release)
- name: Run GoReleaser (Build Binaries Only)
if: ${{ steps.skip-publish.outputs.skip-publish == 'true' }}
uses: goreleaser/goreleaser-action@v5
with:
distribution: goreleaser
version: latest
args: release -f .github/.goreleaser-unstable.yml --clean --timeout 120m
args: build -f .github/.goreleaser-unstable.yml --timeout 120m --snapshot
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CERT_PASSWORD: ${{ steps.gcp_secrets.outputs.code_sign_cert_challenge }}
Expand Down Expand Up @@ -168,6 +168,13 @@ jobs:
"version": "${{ github.ref_name }}"
}'

- name: Save Artifacts
if: ${{ steps.skip-publish.outputs.skip-publish }}
uses: actions/upload-artifact@v3
with:
name: build_artifacts
path: dist/

- name: Cleanup
if: always()
run:
Expand Down
8 changes: 4 additions & 4 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -62,10 +62,10 @@ builds:
- -s -w -X go.mondoo.com/cnquery/v9.Version={{.Version}} -X go.mondoo.com/cnquery/v9.Build={{.ShortCommit}} -X go.mondoo.com/cnquery/v9.Date={{.Date}}
hooks:
post:
- cmd: ./scripts/windows-upx.sh "{{ .Path }}"
output: true
env:
- TARGET={{ .Target }}
# - cmd: ./scripts/windows-upx.sh "{{ .Path }}"
# output: true
# env:
# - TARGET={{ .Target }}
- cmd: jsign --storetype DIGICERTONE --alias "{{ .Env.SM_CERT_ALIAS }}" --storepass "{{ .Env.SM_API_KEY }}|{{ .Env.SM_CLIENT_CERT_FILE}}|{{ .Env.SM_CLIENT_CERT_PASSWORD }}" --tsaurl "http://timestamp.digicert.com" '{{ .Path }}'
nfpms:
-
Expand Down