mirror of
https://github.com/openharmony/miscservices_time.git
synced 2026-07-19 12:02:04 -04:00
@@ -1,9 +1,18 @@
|
||||
{
|
||||
"jobs" : [{
|
||||
"name" : "boot",
|
||||
"cmds" : [
|
||||
"mkdir /data/service/el1/public/time 0770 time time",
|
||||
"syncexec /system/bin/chown -R time:time /data/service/el1/public/time",
|
||||
"start time_service"
|
||||
]
|
||||
}
|
||||
],
|
||||
"services" : [{
|
||||
"name" : "time_service",
|
||||
"path" : ["/system/bin/sa_main", "/system/profile/time_service.xml"],
|
||||
"uid" : "system",
|
||||
"gid" : ["system", "time", "shell"],
|
||||
"uid" : "time",
|
||||
"gid" : ["time", "shell"],
|
||||
"caps" : ["SYS_TIME", "WAKE_ALARM"],
|
||||
"secon" : "u:r:time_service:s0"
|
||||
}
|
||||
|
||||
@@ -40,7 +40,7 @@ namespace MiscServices {
|
||||
namespace {
|
||||
constexpr uint64_t NANO_TO_MILLISECOND = 1000000;
|
||||
constexpr uint64_t DAY_TO_MILLISECOND = 86400000;
|
||||
const std::string AUTOTIME_FILE_PATH = "/data/misc/zoneinfo/autotime.json";
|
||||
const std::string AUTOTIME_FILE_PATH = "/data/service/el1/public/time/autotime.json";
|
||||
const std::string NETWORK_TIME_STATUS_ON = "ON";
|
||||
const std::string NETWORK_TIME_STATUS_OFF = "OFF";
|
||||
const std::string NTP_CN_SERVER = "ntp.aliyun.com";
|
||||
|
||||
Reference in New Issue
Block a user