5.11. 设置时区和 NTP
您可以自定义蓝图来配置时区和 网络时间协议 (NTP)。timezone 和 ntpservers 属性是可选字符串。如果您没有自定义时区,系统将使用 Universal Time, Coordinated (UTC)。如果您没有设置 NTP 服务器,系统将使用默认发行版。
自定义带有您想要的
timezone和ntpservers的蓝图:[customizations.timezone] timezone = "TIMEZONE" ntpservers = "NTP_SERVER"例如:
[customizations.timezone] timezone = "US/Eastern" ntpservers = ["0.north-america.pool.ntp.org", "1.north-america.pool.ntp.org"]注意有些镜像类型,如 Google Cloud,已经建立了 NTP 服务器。您无法覆盖它,因为镜像需要 NTP 服务器来在所选环境中引导。但是,您可以在蓝图中自定义时区。