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

pkg: remove use of sudo from the signing script #4206

Merged
merged 1 commit into from
Jun 5, 2024

Conversation

anjannath
Copy link
Member

this is required as use of 'sudo' is not available in downstream build machines. while testing the built pkg with this changes crc is working as expected

this is required as use of 'sudo' is not available
in downstream build machines. while testing the built
pkg with this changes crc is working as expected
@openshift-ci openshift-ci bot requested review from cfergeau and evidolob June 5, 2024 10:42
@anjannath
Copy link
Member Author

/hold
till it is tested by the downstream pipeline, cc @adrianriobo

@@ -49,7 +49,7 @@ sign "${crcBinDir}/crc"
sign "${crcBinDir}/crc-admin-helper-darwin"
sign "${crcBinDir}/vfkit"

sudo chmod +sx "${crcBinDir}/crc-admin-helper-darwin"
chmod +sx "${crcBinDir}/crc-admin-helper-darwin"
Copy link
Contributor

Choose a reason for hiding this comment

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

If "${crcBinDir}/crc-admin-helper-darwin" is owned by the user running the script, both versions should be equivalent.
After installation though, crc-admin-helper-darwin must be owned by root and have the +s permission set, otherwise the binary won't be able to make changes to /etc/hosts Have you checked it's still fine?

Copy link
Contributor

Choose a reason for hiding this comment

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

After create installer from this PR and run it I have this

podmanqe@dev-platform-mac4 ~ % ls -al /usr/local/crc     
total 389096
drwxr-xr-x  5 root  wheel        160 Jun  5 13:11 .
drwxr-xr-x  5 root  wheel        160 Jun  5 13:12 ..
-rwxr-xr-x  1 root  wheel  159483008 Jun  5 13:11 crc
-rwsr-sr-x  1 root  wheel    5238656 Jun  5 13:11 crc-admin-helper-darwin
-rwxr-xr-x  1 root  wheel   34489808 Jun  5 13:11 vfkit

Copy link
Member Author

Choose a reason for hiding this comment

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

the installation needs to be run as root, since it installs in the / dir, and the files it creates are also owned by root

Copy link

openshift-ci bot commented Jun 5, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: adrianriobo

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci openshift-ci bot added the approved label Jun 5, 2024
@anjannath anjannath merged commit e589591 into crc-org:v2.37 Jun 5, 2024
17 of 24 checks passed
@anjannath
Copy link
Member Author

/cheery-pick main

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