File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -19,8 +19,10 @@ srcdir2="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
1919
2020cd " $srcdir2 /.."
2121
22+ # shellcheck disable=SC1091
2223. " tests/utils.sh"
2324
25+ # shellcheck disable=SC1091
2426. " bash-tools/lib/utils.sh"
2527
2628srcdir=" $srcdir2 "
@@ -75,12 +77,13 @@ private_key="registry.key"
7577certificate=" registry.crt"
7678htpasswd=" registry.htpasswd"
7779csr=" registry.csr"
78- if ! [ -f " $private_key " -a -f " $certificate " ]; then
80+ if ! [ -f " $private_key " ] &&
81+ [ -f " $certificate " ]; then
7982 echo " Generating sample SSL certificates:"
8083 echo
8184 openssl genrsa -out " $private_key " 2048
8285 echo
83- yes " " | openssl req -new -key " $private_key " -out " $csr " || :
86+ yes " . " | openssl req -new -key " $private_key " -out " $csr " || :
8487 echo
8588 openssl x509 -req -days 3650 -in " $csr " -signkey " $private_key " -out " $certificate "
8689 echo
@@ -108,6 +111,7 @@ echo "getting dynamic Docker Registry port mapping:"
108111docker_compose_port " Docker Registry"
109112hr
110113
114+ # shellcheck disable=SC2153
111115if [ -z " $DOCKER_REGISTRY_PORT " ]; then
112116 echo " DOCKER_REGISTRY_PORT not found from running container, did container fail to start up properly?"
113117 exit 1
You can’t perform that action at this time.
0 commit comments