diff --git a/images/nginx/rootfs/Dockerfile b/images/nginx/rootfs/Dockerfile index 75c63cff12..2371acd820 100644 --- a/images/nginx/rootfs/Dockerfile +++ b/images/nginx/rootfs/Dockerfile @@ -31,10 +31,8 @@ ENV LUA_CPATH="/usr/local/lib/lua/?/?.so;/usr/local/lib/lua/?.so;;" COPY --from=builder /usr/local /usr/local COPY --from=builder /opt /opt COPY --from=builder /etc/nginx /etc/nginx -COPY --from=builder entrypoint.sh /usr/local/entrypoint.sh -RUN chmod +x /usr/local/entrypoint.sh \ - && apk update \ +RUN apk update \ && apk upgrade \ && apk add -U --no-cache \ bash \ @@ -73,6 +71,4 @@ RUN chmod +x /usr/local/entrypoint.sh \ EXPOSE 80 443 -ENTRYPOINT ["/usr/local/entrypoint.sh"] - CMD ["nginx", "-g", "daemon off;"] diff --git a/images/nginx/rootfs/entrypoint.sh b/images/nginx/rootfs/entrypoint.sh deleted file mode 100755 index 9479831f1f..0000000000 --- a/images/nginx/rootfs/entrypoint.sh +++ /dev/null @@ -1,27 +0,0 @@ -#!/bin/bash - -# Copyright 2022 The Kubernetes Authors. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -set -o errexit -set -o nounset -set -o pipefail - -if [ -d "/modules_mount/etc/nginx/modules" ]; then - for dir in /modules_mount/etc/nginx/modules/*; do - cp "$dir"/* "/etc/nginx/modules/$(basename "$dir")" - done -fi - -exec "$@"