Modify the way to get timezone

This commit is contained in:
iwumingz 2022-04-08 15:02:39 +08:00
parent d3bb82aedb
commit 86fa998700

View File

@ -129,7 +129,7 @@ install_sycgram(){
echo -e "${yellow}正在启动容器...${plain}" echo -e "${yellow}正在启动容器...${plain}"
docker run $1 \ docker run $1 \
--name ${CONTAINER_NAME} \ --name ${CONTAINER_NAME} \
--env TZ=$(timedatectl | grep "Time zone" | awk '{print $3}') \ --env TZ=$(cat /etc/timezone) \
--restart always \ --restart always \
--hostname ${CONTAINER_NAME} \ --hostname ${CONTAINER_NAME} \
-v ${PROJECT_PATH}/data:/sycgram/data \ -v ${PROJECT_PATH}/data:/sycgram/data \