Skip to content

Commit f25aab6

Browse files
Wait for build to finish (AST-000)
1 parent 3a699e5 commit f25aab6

File tree

1 file changed

+1
-107
lines changed

1 file changed

+1
-107
lines changed

.github/workflows/release.yml

Lines changed: 1 addition & 107 deletions
Original file line numberDiff line numberDiff line change
@@ -29,113 +29,6 @@ permissions:
2929
contents: write
3030

3131
jobs:
32-
build:
33-
runs-on: macos-13
34-
env:
35-
AC_PASSWORD: ${{ secrets.AC_PASSWORD }}
36-
APPLE_DEVELOPER_CERTIFICATE_P12_BASE64: ${{ secrets.APPLE_DEVELOPER_CERTIFICATE_P12_BASE64 }}
37-
APPLE_DEVELOPER_CERTIFICATE_PASSWORD: ${{ secrets.APPLE_DEVELOPER_CERTIFICATE_PASSWORD }}
38-
COSIGN_PRIVATE_KEY: ${{ secrets.COSIGN_PRIVATE_KEY }}
39-
COSIGN_PASSWORD: ${{ secrets.COSIGN_PASSWORD }}
40-
COSIGN_PUBLIC_KEY: ${{ secrets.COSIGN_PUBLIC_KEY }}
41-
steps:
42-
- name: Checkout
43-
uses: actions/checkout@1e31de5234b9f8995739874a8ce0492dc87873e2 #v4.0.0
44-
with:
45-
fetch-depth: 0
46-
- name: Install Go
47-
uses: actions/setup-go@4d34df0c2316fe8122ab82dc22947d607c0c91f9 #v4
48-
with:
49-
go-version-file: go.mod
50-
- name: Import Code-Signing Certificates
51-
uses: Apple-Actions/import-codesign-certs@253ddeeac23f2bdad1646faac5c8c2832e800071 #v1
52-
with:
53-
# The certificates in a PKCS12 file encoded as a base64 string
54-
p12-file-base64: ${{ secrets.APPLE_DEVELOPER_CERTIFICATE_P12_BASE64 }}
55-
# The password used to import the PKCS12 file.
56-
p12-password: ${{ secrets.APPLE_DEVELOPER_CERTIFICATE_PASSWORD }}
57-
- name: Updating and upgrading brew to a specific version
58-
run: |
59-
brew --version
60-
cd $(brew --repo)
61-
git fetch --tags
62-
git checkout 4.4.15
63-
export HOMEBREW_NO_AUTO_UPDATE=1
64-
brew --version
65-
66-
- name: Install gon
67-
run: |
68-
brew install Bearer/tap/gon
69-
- name: Setup Docker on macOS
70-
if: inputs.dev == false
71-
uses: douglascamata/setup-docker-macos-action@4fe96839fcba8a2d746e020d00a89a37afbc7dc9 #v1-alpha.15
72-
- name: Test docker
73-
if: inputs.dev == false
74-
run: |
75-
docker version
76-
docker info
77-
- name: Login to Docker Hub
78-
if: inputs.dev == false
79-
uses: docker/login-action@dd4fa0671be5250ee6f50aedf4cb05514abda2c7 #v1
80-
with:
81-
username: ${{ secrets.DOCKER_USERNAME }}
82-
password: ${{ secrets.DOCKER_PASSWORD }}
83-
84-
- name: Install Cosign
85-
if: inputs.dev == false
86-
run: |
87-
brew install sigstore/tap/cosign
88-
89-
- name: Configure AWS Credentials
90-
uses: aws-actions/configure-aws-credentials@5fd3084fc36e372ff1fff382a39b10d03659f355 #v2
91-
with:
92-
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_ARN }}
93-
aws-region: ${{ secrets.AWS_ASSUME_ROLE_REGION }}
94-
- name: Tag
95-
run: |
96-
echo ${{ inputs.tag }}
97-
echo "NEXT_VERSION=${{ inputs.tag }}" >> $GITHUB_ENV
98-
tag=${{ inputs.tag }}
99-
message='${{ inputs.tag }}: PR #${{ github.event.pull_request.number }} ${{ github.event.pull_request.title }}'
100-
git config user.name "${GITHUB_ACTOR}"
101-
git config user.email "${GITHUB_ACTOR}@users.noreply.github.com"
102-
git tag -a "${tag}" -m "${message}"
103-
git push origin "${tag}"
104-
- name: Build GoReleaser Args
105-
run: |
106-
args='release --clean --debug'
107-
if [ ${{ inputs.dev }} = true ]; then
108-
args=${args}' --config=".goreleaser-dev.yml"'
109-
fi
110-
echo "GR_ARGS=${args}" >> $GITHUB_ENV
111-
- name: Echo GoReleaser Args
112-
run: echo ${{ env.GR_ARGS }}
113-
- name: Run GoReleaser
114-
uses: goreleaser/goreleaser-action@b508e2e3ef3b19d4e4146d4f8fb3ba9db644a757 #v3
115-
with:
116-
version: v1.18.2
117-
args: ${{ env.GR_ARGS }}
118-
env:
119-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
120-
GO_BOT_TOKEN: ${{ secrets.PERSONAL_ACCESS_TOKEN }}
121-
S3_BUCKET_NAME: ${{ secrets.S3_BUCKET_NAME }}
122-
S3_BUCKET_REGION: ${{ secrets.S3_BUCKET_REGION }}
123-
SIGNING_REMOTE_SSH_USER: ${{ secrets.SIGNING_REMOTE_SSH_USER }}
124-
SIGNING_REMOTE_SSH_HOST: ${{ secrets.SIGNING_REMOTE_SSH_HOST }}
125-
SIGNING_REMOTE_SSH_PRIVATE_KEY: ${{ secrets.SIGNING_REMOTE_SSH_PRIVATE_KEY }}
126-
SIGNING_HSM_CREDS: ${{ secrets.SIGNING_HSM_CREDS }}
127-
- name: Sign Docker Image with Cosign
128-
if: inputs.dev == false
129-
run: |
130-
cosign sign --yes --key env://COSIGN_PRIVATE_KEY checkmarx/ast-cli:${{ inputs.tag }}
131-
132-
- name: Verify Docker image signature
133-
if: inputs.dev == false
134-
run: |
135-
echo "${{ secrets.COSIGN_PUBLIC_KEY }}" > cosign.pub
136-
cosign verify --key cosign.pub checkmarx/ast-cli:${{ inputs.tag }}
137-
env:
138-
COSIGN_PASSWORD: ${{ secrets.COSIGN_PASSWORD }}
13932

14033
notify:
14134
needs: build
@@ -146,3 +39,4 @@ jobs:
14639
cli_release_version: ""
14740
release_author: "Phoenix Team"
14841
release_url: https://github.com/Checkmarx/ast-cli/releases/tag/${{ inputs.tag }}
42+
secrets: inherit

0 commit comments

Comments
 (0)