mirror of
https://github.com/bitnami/containers.git
synced 2026-03-02 08:04:33 +08:00
config: move default config var to Dockerfile
This commit is contained in:
@@ -10,11 +10,15 @@ RUN install_packages libc6 libpcre3 libssl1.0.0 zlib1g
|
||||
|
||||
# Install nginx
|
||||
RUN bitnami-pkg unpack nginx-1.10.3-0 --checksum f55a7ac4e3ce28c59596e2bdc21531b8cc7c5991cc84768be804534017db7c9f
|
||||
RUN ln -sf /opt/bitnami/$BITNAMI_APP_NAME/html /app
|
||||
RUN ln -sf /opt/bitnami/nginx/html /app
|
||||
|
||||
ENV PATH=/opt/bitnami/$BITNAMI_APP_NAME/sbin:/opt/bitnami/$BITNAMI_APP_NAME/bin:/opt/bitnami/common/bin:$PATH
|
||||
ENV PATH=/opt/bitnami/nginx/sbin:/opt/bitnami/nginx/bin:/opt/bitnami/common/bin:$PATH
|
||||
|
||||
COPY rootfs/ /
|
||||
|
||||
ENV NGINX_HTTP_PORT=80 \
|
||||
NGINX_HTTPS_PORT=443
|
||||
|
||||
ENTRYPOINT ["/app-entrypoint.sh"]
|
||||
CMD ["nami", "start", "--foreground", "nginx"]
|
||||
|
||||
|
||||
@@ -13,10 +13,6 @@ function initialize {
|
||||
fi
|
||||
}
|
||||
|
||||
# Set default values
|
||||
export NGINX_HTTP_PORT=${NGINX_HTTP_PORT:-80}
|
||||
export NGINX_HTTPS_PORT=${NGINX_HTTPS_PORT:-443}
|
||||
|
||||
if [[ "$1" == "nami" && "$2" == "start" ]] || [[ "$1" == "/init.sh" ]]; then
|
||||
initialize nginx
|
||||
chown -R :$BITNAMI_APP_USER /bitnami/nginx || true
|
||||
|
||||
Reference in New Issue
Block a user