feat(Docker): add timezone settings to dockerfile (#3292)
This commit is contained in:
@@ -1,7 +1,18 @@
|
|||||||
FROM ubuntu:20.04
|
FROM ubuntu:20.04
|
||||||
|
|
||||||
|
# List of timezones: http://en.wikipedia.org/wiki/List_of_tz_database_time_zones
|
||||||
|
|
||||||
|
# set timezone environment variable
|
||||||
|
ENV TZ=Etc/UTC
|
||||||
|
|
||||||
|
# set noninteractive mode so tzdata doesn't ask to set timezone on install
|
||||||
|
ENV DEBIAN_FRONTEND=noninteractive
|
||||||
|
|
||||||
# install the required dependencies to run the authserver
|
# install the required dependencies to run the authserver
|
||||||
RUN apt update && apt install -y libmysqlclient-dev libssl-dev libace-6.4.5 libace-dev net-tools;
|
RUN apt update && apt install -y libmysqlclient-dev libssl-dev libace-6.4.5 libace-dev net-tools tzdata;
|
||||||
|
|
||||||
|
# change timezone in container
|
||||||
|
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone && dpkg-reconfigure --frontend noninteractive tzdata
|
||||||
|
|
||||||
HEALTHCHECK --interval=5s --timeout=15s --start-period=30s --retries=3 CMD netstat -lnpt | grep :3724 || exit 1
|
HEALTHCHECK --interval=5s --timeout=15s --start-period=30s --retries=3 CMD netstat -lnpt | grep :3724 || exit 1
|
||||||
|
|
||||||
|
|||||||
@@ -16,6 +16,11 @@ RUN ./azerothcore/bin/acore-db-asm 1
|
|||||||
|
|
||||||
FROM mysql:5.7
|
FROM mysql:5.7
|
||||||
|
|
||||||
|
# List of timezones: http://en.wikipedia.org/wiki/List_of_tz_database_time_zones
|
||||||
|
|
||||||
|
# set timezone environment variable
|
||||||
|
ENV TZ=Etc/UTC
|
||||||
|
|
||||||
ENV LANG C.UTF-8
|
ENV LANG C.UTF-8
|
||||||
|
|
||||||
# copy files from the previous build stage - see: https://docs.docker.com/develop/develop-images/multistage-build/
|
# copy files from the previous build stage - see: https://docs.docker.com/develop/develop-images/multistage-build/
|
||||||
|
|||||||
@@ -1,7 +1,18 @@
|
|||||||
FROM ubuntu:20.04
|
FROM ubuntu:20.04
|
||||||
|
|
||||||
|
# List of timezones: http://en.wikipedia.org/wiki/List_of_tz_database_time_zones
|
||||||
|
|
||||||
|
# set timezone environment variable
|
||||||
|
ENV TZ=Etc/UTC
|
||||||
|
|
||||||
|
# set noninteractive mode so tzdata doesn't ask to set timezone on install
|
||||||
|
ENV DEBIAN_FRONTEND=noninteractive
|
||||||
|
|
||||||
# install the required dependencies to run the authserver
|
# install the required dependencies to run the authserver
|
||||||
RUN apt update && apt install -y libmysqlclient-dev libssl-dev libace-6.4.5 libace-dev libreadline-dev net-tools;
|
RUN apt update && apt install -y libmysqlclient-dev libssl-dev libace-6.4.5 libace-dev libreadline-dev net-tools tzdata;
|
||||||
|
|
||||||
|
# change timezone in container
|
||||||
|
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone && dpkg-reconfigure --frontend noninteractive tzdata
|
||||||
|
|
||||||
HEALTHCHECK --interval=5s --timeout=15s --start-period=30s --retries=3 CMD netstat -lnpt | grep :8085 || exit 1
|
HEALTHCHECK --interval=5s --timeout=15s --start-period=30s --retries=3 CMD netstat -lnpt | grep :8085 || exit 1
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user