After SSHing to my shared hosting (Namecheap) non-root user-account, I ran basically this:
cd "$web_application_root_dir"/downloadtest`
curl https://get.acme.sh
I got this:
#!/usr/bin/env sh
#GitHub - acmesh-official/get.acme.sh: get.acme.sh
_exists() {
cmd="$1"
if [ -z "$cmd" ] ; then
echo "Usage: _exists cmd"
return 1
fi
if type command >/dev/null 2>&1 ; then
command -v $cmd >/dev/null 2>&1
else
type $cmd >/dev/null 2>&1
fi
ret="$?"
return $ret
}if [ -z "$BRANCH" ]; then
BRANCH="master"
fi#format "email=my@example.com"
_email="$1"if [ "$_email" ]; then
shift
_email="--$(echo "$_email" | tr '=' ' ')"
fi_url="https://raw.githubusercontent.com/acmesh-official/acme.sh/$BRANCH/acme.sh"
_get=""
if _exists curl && [ "${ACME_USE_WGET:-0}" = "0" ]; then
_get="curl -L"
elif _exists wget ; then
_get="wget -O -"
else
echo "Sorry, you must have curl or wget installed first."
echo "Please install either of them and try again."
exit 1
fiif ! $_get "$_url" | sh -s -- --install-online $_email "$@"; then
echo "Install error"
echo "中国大陆用户请参考:"
echo "Install in China · acmesh-official/acme.sh Wiki · GitHub"
fi
This doesn't make sense to me primarily because curl
and wget
are already available for my non root user account.
Anyways, I then tried this instead:
curl https://get.acme.sh | sh
I got this:
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
103 1032 0 1032 0 0 3005 0 --:--:-- --:--:-- --:--:-- 7267
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 216k 100 216k 0 0 234k 0 --:--:-- --:--:-- --:--:-- 295k
[Thu Nov 23 21:10:40 EST 2023] Installing from online archive.
[Thu Nov 23 21:10:40 EST 2023] Downloading https://github.com/acmesh-official/acme.sh/archive/master.tar.gz
[Thu Nov 23 21:10:40 EST 2023] Extracting master.tar.gz
[Thu Nov 23 21:10:40 EST 2023] It is recommended to install socat first.
[Thu Nov 23 21:10:40 EST 2023] We use socat for standalone server if you use standalone mode.
[Thu Nov 23 21:10:40 EST 2023] If you don't use standalone mode, just ignore this warning.
[Thu Nov 23 21:10:40 EST 2023] Installing to /home/MY_WONDERFUL_USER_NAME/.acme.sh
[Thu Nov 23 21:10:40 EST 2023] Installed to /home/MY_WONDERFUL_USER_NAME/.acme.sh/acme.sh
[Thu Nov 23 21:10:41 EST 2023] Installing alias to '/home/MY_WONDERFUL_USER_NAME/.bashrc'
[Thu Nov 23 21:10:41 EST 2023] OK, Close and reopen your terminal to start using acme.sh
[Thu Nov 23 21:10:41 EST 2023] Installing cron job
[Thu Nov 23 21:10:42 EST 2023] Good, bash is found, so change the shebang to use bash as preferred.
[Thu Nov 23 21:10:45 EST 2023] OK
I just want one SSL certificate for a mediawiki website, is "socat" relevant for me?
What is this "standalone mode"? I mean, standalone of what? As my server environment is shared hosting, I dobut it relates to me but please do opine on this.
Would it be decent to say that I have installed acme.sh successfully?