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
Automatically enable EPEL after prompting users #3259
Conversation
@NoodlesNZ or @hogarthj would either of you (or someone else from your team) be interested in reviewing this? This is realistically going to be the way that CentOS 6 users get to install Certbot for the rest of time... |
Just noticed that I had some changes locally that weren't included here. I've updated this PR. |
echo "To use Certbot, packages from the EPEL repository need to be installed." | ||
if [ "$ASSUME_YES" = 1 ]; then | ||
/bin/echo -n "Enabling the EPEL repository in 3 seconds..." | ||
sleep 1s |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is the s
an actual thing? I can't find it documented in the Fedora man page, and OS X, at least, just ignores the s. You can sleep 1q
with equal results.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sleep
on Fedora etc is GNU sleep, which supports the s
(as well as m
and h
).
That's all I see. Otherwise, it looks fine. |
@bmw I think this is back in your court to consider enabling the "optional" channel for RHN users. |
@bmw it may be that we can kick the RHN piece into a future ticket. If you agree, go ahead and merge this! |
I'm really struggling testing this on a Red Hat machine with RHN. Does anyone else want to take a crack at it? |
So it appears that you can only Due to this oversight on my part, we will error out on RHEL systems (or CentOS systems that don't include the |
@@ -287,6 +287,10 @@ BootstrapRpmCommon() { | |||
|
|||
if ! $SUDO $tool list *virtualenv >/dev/null 2>&1; then | |||
echo "To use Certbot, packages from the EPEL repository need to be installed." | |||
if ! $SUDO $tool list epel-release >/dev/null 2>&1; then |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As long as we're sure that this package will always be visible on RPM-based systems where certbot-auto
works.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we're not, I guess we can do something like make this a warning?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually I guess this is fine, because we're inside the if
about virtualenv. So overall, LGTM.
Fixes #2158.
I tested all branches of this on CentOS 6 and tested the script on CentOS 7 (EPEL doesn't need to be enabled on CentOS 7 so there's not much to test). I also tested this on the test farm, however, it appears EPEL is already enabled so I think the value of testing there is fairly minimal.