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

Add lib to sign and publish artifacts to artifacts.opensearch.org #127

Merged
merged 2 commits into from
Feb 6, 2023

Conversation

gaiksaya
Copy link
Member

@gaiksaya gaiksaya commented Feb 3, 2023

Description

This change adds the library to sign and publish the artifacts to artifacts.opensearch.org. The role management is manual as of today but we are looking into automating the same.

Issues Resolved

required for opensearch-project/opensearch-build#3112

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

@codecov-commenter
Copy link

codecov-commenter commented Feb 3, 2023

Codecov Report

Merging #127 (d3a1e8a) into main (ad5133e) will increase coverage by 0.08%.
The diff coverage is 100.00%.

📣 This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more

@@             Coverage Diff              @@
##               main     #127      +/-   ##
============================================
+ Coverage     82.98%   83.07%   +0.08%     
  Complexity       24       24              
============================================
  Files            69       70       +1     
  Lines           194      195       +1     
  Branches         11       11              
============================================
+ Hits            161      162       +1     
  Misses           25       25              
  Partials          8        8              
Impacted Files Coverage Δ
...kins/jobs/PublishToArtifactsProdBucket_Jenkinsfile 100.00% <100.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@gaiksaya gaiksaya marked this pull request as ready for review February 4, 2023 02:05
@gaiksaya gaiksaya requested a review from a team as a code owner February 4, 2023 02:05
@param Map[source] <required> - Path to yml or artifact file.
@param Map[destination] <required> - Artifact type in the manifest, [type] is required for signing yml.
@param Map[signingPlatform] <optional> - The distribution platform for signing. Defaults to linux
@param Map[sigtype] <optional> - signature type. Defaults to '.sig'
Copy link
Collaborator

Choose a reason for hiding this comment

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

Nit: sigType

@param Map[destination] <required> - Artifact type in the manifest, [type] is required for signing yml.
@param Map[signingPlatform] <optional> - The distribution platform for signing. Defaults to linux
@param Map[sigtype] <optional> - signature type. Defaults to '.sig'
@param Map[overwrite]<optional> - Allow output artifacts to overwrite the existing artifacts. Defaults to false
Copy link
Collaborator

Choose a reason for hiding this comment

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

Nit: overWrite

Copy link
Member Author

@gaiksaya gaiksaya Feb 6, 2023

Choose a reason for hiding this comment

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

Hey! So these args are supplied as it is to sign.sh so has to be sigtype and overwrite: https://github.com/opensearch-project/opensearch-build/blob/main/src/sign_workflow/sign_args.py#L45-L57

Copy link
Member Author

Choose a reason for hiding this comment

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

Fixed!

Signed-off-by: Sayali Gaikawad <[email protected]>
Signed-off-by: Sayali Gaikawad <[email protected]>
@gaiksaya gaiksaya merged commit 09ba828 into opensearch-project:main Feb 6, 2023
@gaiksaya gaiksaya deleted the artifacts-upload branch February 6, 2023 20:14
@opensearch-trigger-bot
Copy link

The backport to 1.x failed:

The process '/usr/bin/git' failed with exit code 128

To backport manually, run these commands in your terminal:

# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add ../.worktrees/backport-1.x 1.x
# Navigate to the new working tree
pushd ../.worktrees/backport-1.x
# Create a new branch
git switch --create backport/backport-127-to-1.x
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 09ba8285089488f9d0efbd789a4bb8bd01c6aab1
# Push it to GitHub
git push --set-upstream origin backport/backport-127-to-1.x
# Go back to the original working tree
popd
# Delete the working tree
git worktree remove ../.worktrees/backport-1.x

Then, create a pull request where the base branch is 1.x and the compare/head branch is backport/backport-127-to-1.x.

gaiksaya added a commit that referenced this pull request Feb 6, 2023
@opensearch-trigger-bot
Copy link

The backport to 1.x failed:

The process '/usr/bin/git' failed with exit code 128

To backport manually, run these commands in your terminal:

# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add ../.worktrees/backport-1.x 1.x
# Navigate to the new working tree
pushd ../.worktrees/backport-1.x
# Create a new branch
git switch --create backport/backport-127-to-1.x
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 09ba8285089488f9d0efbd789a4bb8bd01c6aab1
# Push it to GitHub
git push --set-upstream origin backport/backport-127-to-1.x
# Go back to the original working tree
popd
# Delete the working tree
git worktree remove ../.worktrees/backport-1.x

Then, create a pull request where the base branch is 1.x and the compare/head branch is backport/backport-127-to-1.x.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants