您可以将TZ环境应用于您的docker-compose,如下所示:
image: jenkins/jenkins:alpine container_name: jenkins hostname: jenkins restart: always environment: - TZ=Asia/Shanghai volumes: - ./jenkins/data:/var/jenkins_home - ./jenkins/bin/jenkins.war:/usr/share/jenkins/jenkins.war