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

Sign MacOS Binaries with JFrog Certificate #2563

Open
wants to merge 197 commits into
base: dev
Choose a base branch
from

Conversation

EyalDelarea
Copy link
Contributor

@EyalDelarea EyalDelarea commented Jun 3, 2024

  • All tests have passed. If this feature is not already covered by the tests, new tests have been added.
  • The pull request is targeting the dev branch.
  • The code has been validated to compile successfully by running go vet ./....
  • The code has been formatted properly using go fmt ./....

Sign Darwin Binaries during Release

This PR introduce a way to integrate darwin signed executables singing during the CLI release.

Darwin Release Flow:

flowchart TD

    A[Release Pipepline Triggers the MacOS specific workflow] --> B[GitHub Actions Build & Upload Signed darwin exeutables] --> C(Jenkins Job downloads the binary from Github packages)
    
    C --> E
    
   E[Distribute to releases]
    

Loading

TODO Before merging:

  • Test Jenkins script
  • Add apple secrets to repository
  • Adjust download links in scripts repostiory

@EyalDelarea EyalDelarea added the improvement Automatically generated release notes label Jun 3, 2024
local cooldown=15 # Cooldown in seconds between retries
local retry_count=0

while [ $retry_count -lt $max_retries ]; do
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@yahavi,
In here we can't use curl --retry, because the curl execution will be okay as it queries all the artifacts from the repo.
The retry is when the query doesn't return the specific version and release version executable, which we try to filter from the response.

.github/workflows/prepareDarwinBinariesForRelease.yml Outdated Show resolved Hide resolved
Jenkinsfile Outdated Show resolved Hide resolved
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer $GITHUB_ACCESS_TOKEN" \
-H "X-GitHub-Api-Version: 2022-11-28" \
-s https://api.github.com/repos/eyaldelarea/jfrog-cli/actions/artifacts)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
-s https://api.github.com/repos/eyaldelarea/jfrog-cli/actions/artifacts)
-s https://api.github.com/repos/jfrog/jfrog-cli/actions/artifacts)

response=$(curl -L \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer $GITHUB_ACCESS_TOKEN" \
-H "X-GitHub-Api-Version: 2022-11-28" \
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

According to the documentation:

When a new REST API version is released, the previous API version will be supported for at least 24 more months following the release of the new API version.

Let's use the latest API

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
improvement Automatically generated release notes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Signed JFrog CLI binary for MacOS
2 participants