"Officializing" getcaddy.com

FWIW, Caddy does this the most correctly out of all the curl | sh implementations I’ve ever seen, but I agree. wget it, cat, it, and then execute it.

1 Like

Going back to the file path question asked earlier, I personally prefer an install path of /usr/local/bin. The other option I recommend considering is /opt. For me, I see both of these locations as where where non-distro software/scripts should go. The conventional directory layout is a good overview of what should go where in a Unix/Linux file systems.

I understand the need for something like /usr/bin/ for Termux. I guess the other option would be to fall back to it if /usr/local/bin or /opt aren’t available.

Thanks for your input – in fact, that’s what I’ve done with it; try /usr/local/bin first, then /usr/bin as a fallback. :+1:

1 Like

Curious about one thing with this, when using to install caddy, will the script be able to handle upgrades as well? Or will you need to do something like:

To update you would need to run the curl command again. The script automatically backups your current Caddy version and places the new one, so you don’t have to rm before :slight_smile:

3 Likes

It backs it up to say /usr/local/bin/caddy_0.8.3 (If you were running 0.8.3 when upgrading) then upgrades /usr/local/bin/caddy to the latest version. Check the script, it’s all there.