Also remove the hard requirement that the container get its
self cid during entrypoint as it is only used to produce a warning
and to get the nginx-proxy container id through --volumes-from,
which is only one of the three methods.
The fact that the LE container could get an nginx-proxy container id
is independently verified by the entrypoint script anyway and this
hard requirement on getting its self cid has been known to cause
troubles with containers running under orchestrators such as Amazon ECS
or Kubernetes.
Fix #375
This enable the /app/force_renew script to get the LE companion
container ID, which is required to check if the nginx container
is running (#321) when using the --volumes-from method.
https://github.com/koalaman/shellcheck/wiki
start.sh:
Fix SC2173 on line 14.
letsencrypt_service:
Ignore SC2120 and SC1090.
Fix SC1087 on line 54, SC2068 on lines 54 and 124.
Fix SC2034 on lines 12, 13, 19 and 20.
+ use pushd / popd to change the CWD back to /etc/nginx/certs after simp_le execution.
functions.sh:
Ignore SC2155.
Add the missing shebang.
entrypoint.sh:
Ignore SC2155.
Assuming they're following a conventional setup, this will warn users
that they likely didn't set their volumes up correctly. It's not an
error though because they may have done something like mount the entire
/etc/nginx directory.
docker inspect command return a leading :ro or :rw string when use with
docker-compose. This fix remove the leading string to get only the
container ID. Thanks anoopr.
Fix #1 and close #2.