]> git.ipfire.org Git - thirdparty/systemd.git/blame - src/core/load-fragment-gperf.gperf.in
Merge pull request #29458 from poettering/serialize-pidref
[thirdparty/systemd.git] / src / core / load-fragment-gperf.gperf.in
CommitLineData
997f52a5
ZJS
1{# SPDX-License-Identifier: LGPL-2.1-or-later #}
2
3{%- macro EXEC_CONTEXT_CONFIG_ITEMS(type) -%}
4{# Define the context options only once #}
5{{type}}.WorkingDirectory, config_parse_working_directory, 0, offsetof({{type}}, exec_context)
6{{type}}.RootDirectory, config_parse_unit_path_printf, true, offsetof({{type}}, exec_context.root_directory)
7{{type}}.RootImage, config_parse_unit_path_printf, true, offsetof({{type}}, exec_context.root_image)
8{{type}}.RootImageOptions, config_parse_root_image_options, 0, offsetof({{type}}, exec_context)
84be0c71 9{{type}}.RootImagePolicy, config_parse_image_policy, 0, offsetof({{type}}, exec_context.root_image_policy)
997f52a5
ZJS
10{{type}}.RootHash, config_parse_exec_root_hash, 0, offsetof({{type}}, exec_context)
11{{type}}.RootHashSignature, config_parse_exec_root_hash_sig, 0, offsetof({{type}}, exec_context)
12{{type}}.RootVerity, config_parse_unit_path_printf, true, offsetof({{type}}, exec_context.root_verity)
9c0c6701 13{{type}}.RootEphemeral, config_parse_bool, 0, offsetof({{type}}, exec_context.root_ephemeral)
a07b9926 14{{type}}.ExtensionDirectories, config_parse_namespace_path_strv, 0, offsetof({{type}}, exec_context.extension_directories)
997f52a5 15{{type}}.ExtensionImages, config_parse_extension_images, 0, offsetof({{type}}, exec_context)
84be0c71 16{{type}}.ExtensionImagePolicy, config_parse_image_policy, 0, offsetof({{type}}, exec_context.extension_image_policy)
997f52a5 17{{type}}.MountImages, config_parse_mount_images, 0, offsetof({{type}}, exec_context)
84be0c71 18{{type}}.MountImagePolicy, config_parse_image_policy, 0, offsetof({{type}}, exec_context.mount_image_policy)
997f52a5
ZJS
19{{type}}.User, config_parse_user_group_compat, 0, offsetof({{type}}, exec_context.user)
20{{type}}.Group, config_parse_user_group_compat, 0, offsetof({{type}}, exec_context.group)
21{{type}}.SupplementaryGroups, config_parse_user_group_strv_compat, 0, offsetof({{type}}, exec_context.supplementary_groups)
22{{type}}.Nice, config_parse_exec_nice, 0, offsetof({{type}}, exec_context)
23{{type}}.OOMScoreAdjust, config_parse_exec_oom_score_adjust, 0, offsetof({{type}}, exec_context)
24{{type}}.CoredumpFilter, config_parse_exec_coredump_filter, 0, offsetof({{type}}, exec_context)
25{{type}}.IOSchedulingClass, config_parse_exec_io_class, 0, offsetof({{type}}, exec_context)
26{{type}}.IOSchedulingPriority, config_parse_exec_io_priority, 0, offsetof({{type}}, exec_context)
27{{type}}.CPUSchedulingPolicy, config_parse_exec_cpu_sched_policy, 0, offsetof({{type}}, exec_context)
28{{type}}.CPUSchedulingPriority, config_parse_exec_cpu_sched_prio, 0, offsetof({{type}}, exec_context)
29{{type}}.CPUSchedulingResetOnFork, config_parse_bool, 0, offsetof({{type}}, exec_context.cpu_sched_reset_on_fork)
30{{type}}.CPUAffinity, config_parse_exec_cpu_affinity, 0, offsetof({{type}}, exec_context)
31{{type}}.NUMAPolicy, config_parse_numa_policy, 0, offsetof({{type}}, exec_context.numa_policy.type)
32{{type}}.NUMAMask, config_parse_numa_mask, 0, offsetof({{type}}, exec_context.numa_policy)
33{{type}}.UMask, config_parse_mode, 0, offsetof({{type}}, exec_context.umask)
34{{type}}.Environment, config_parse_environ, 0, offsetof({{type}}, exec_context.environment)
35{{type}}.EnvironmentFile, config_parse_unit_env_file, 0, offsetof({{type}}, exec_context.environment_files)
36{{type}}.PassEnvironment, config_parse_pass_environ, 0, offsetof({{type}}, exec_context.pass_environment)
37{{type}}.UnsetEnvironment, config_parse_unset_environ, 0, offsetof({{type}}, exec_context.unset_environment)
38{{type}}.DynamicUser, config_parse_bool, true, offsetof({{type}}, exec_context.dynamic_user)
39{{type}}.RemoveIPC, config_parse_bool, 0, offsetof({{type}}, exec_context.remove_ipc)
40{{type}}.StandardInput, config_parse_exec_input, 0, offsetof({{type}}, exec_context)
41{{type}}.StandardOutput, config_parse_exec_output, 0, offsetof({{type}}, exec_context)
42{{type}}.StandardError, config_parse_exec_output, 0, offsetof({{type}}, exec_context)
43{{type}}.StandardInputText, config_parse_exec_input_text, 0, offsetof({{type}}, exec_context)
44{{type}}.StandardInputData, config_parse_exec_input_data, 0, offsetof({{type}}, exec_context)
45{{type}}.TTYPath, config_parse_unit_path_printf, 0, offsetof({{type}}, exec_context.tty_path)
46{{type}}.TTYReset, config_parse_bool, 0, offsetof({{type}}, exec_context.tty_reset)
47{{type}}.TTYVHangup, config_parse_bool, 0, offsetof({{type}}, exec_context.tty_vhangup)
48{{type}}.TTYVTDisallocate, config_parse_bool, 0, offsetof({{type}}, exec_context.tty_vt_disallocate)
51462135
DDM
49{{type}}.TTYRows, config_parse_tty_size, 0, offsetof({{type}}, exec_context.tty_rows)
50{{type}}.TTYColumns, config_parse_tty_size, 0, offsetof({{type}}, exec_context.tty_cols)
997f52a5
ZJS
51{{type}}.SyslogIdentifier, config_parse_unit_string_printf, 0, offsetof({{type}}, exec_context.syslog_identifier)
52{{type}}.SyslogFacility, config_parse_log_facility, 0, offsetof({{type}}, exec_context.syslog_priority)
53{{type}}.SyslogLevel, config_parse_log_level, 0, offsetof({{type}}, exec_context.syslog_priority)
54{{type}}.SyslogLevelPrefix, config_parse_bool, 0, offsetof({{type}}, exec_context.syslog_level_prefix)
55{{type}}.LogLevelMax, config_parse_log_level, 0, offsetof({{type}}, exec_context.log_level_max)
56{{type}}.LogRateLimitIntervalSec, config_parse_sec, 0, offsetof({{type}}, exec_context.log_ratelimit_interval_usec)
57{{type}}.LogRateLimitBurst, config_parse_unsigned, 0, offsetof({{type}}, exec_context.log_ratelimit_burst)
58{{type}}.LogExtraFields, config_parse_log_extra_fields, 0, offsetof({{type}}, exec_context)
523ea123 59{{type}}.LogFilterPatterns, config_parse_log_filter_patterns, 0, offsetof({{type}}, exec_context)
997f52a5
ZJS
60{{type}}.Capabilities, config_parse_warn_compat, DISABLED_LEGACY, offsetof({{type}}, exec_context)
61{{type}}.SecureBits, config_parse_exec_secure_bits, 0, offsetof({{type}}, exec_context.secure_bits)
62{{type}}.CapabilityBoundingSet, config_parse_capability_set, 0, offsetof({{type}}, exec_context.capability_bounding_set)
63{{type}}.AmbientCapabilities, config_parse_capability_set, 0, offsetof({{type}}, exec_context.capability_ambient_set)
64{{type}}.TimerSlackNSec, config_parse_nsec, 0, offsetof({{type}}, exec_context.timer_slack_nsec)
65{{type}}.NoNewPrivileges, config_parse_bool, 0, offsetof({{type}}, exec_context.no_new_privileges)
66{{type}}.KeyringMode, config_parse_exec_keyring_mode, 0, offsetof({{type}}, exec_context.keyring_mode)
67{{type}}.ProtectProc, config_parse_protect_proc, 0, offsetof({{type}}, exec_context.protect_proc)
68{{type}}.ProcSubset, config_parse_proc_subset, 0, offsetof({{type}}, exec_context.proc_subset)
69{% if HAVE_SECCOMP %}
70{{type}}.SystemCallFilter, config_parse_syscall_filter, 0, offsetof({{type}}, exec_context)
71{{type}}.SystemCallArchitectures, config_parse_syscall_archs, 0, offsetof({{type}}, exec_context.syscall_archs)
72{{type}}.SystemCallErrorNumber, config_parse_syscall_errno, 0, offsetof({{type}}, exec_context)
73{{type}}.SystemCallLog, config_parse_syscall_log, 0, offsetof({{type}}, exec_context)
74{{type}}.MemoryDenyWriteExecute, config_parse_bool, 0, offsetof({{type}}, exec_context.memory_deny_write_execute)
75{{type}}.RestrictNamespaces, config_parse_restrict_namespaces, 0, offsetof({{type}}, exec_context)
76{{type}}.RestrictRealtime, config_parse_bool, 0, offsetof({{type}}, exec_context.restrict_realtime)
77{{type}}.RestrictSUIDSGID, config_parse_bool, 0, offsetof({{type}}, exec_context.restrict_suid_sgid)
78{{type}}.RestrictAddressFamilies, config_parse_address_families, 0, offsetof({{type}}, exec_context)
79{{type}}.LockPersonality, config_parse_bool, 0, offsetof({{type}}, exec_context.lock_personality)
80{% else %}
81{{type}}.SystemCallFilter, config_parse_warn_compat, DISABLED_CONFIGURATION, 0
82{{type}}.SystemCallArchitectures, config_parse_warn_compat, DISABLED_CONFIGURATION, 0
83{{type}}.SystemCallErrorNumber, config_parse_warn_compat, DISABLED_CONFIGURATION, 0
84{{type}}.SystemCallLog, config_parse_warn_compat, DISABLED_CONFIGURATION, 0
85{{type}}.MemoryDenyWriteExecute, config_parse_warn_compat, DISABLED_CONFIGURATION, 0
86{{type}}.RestrictNamespaces, config_parse_warn_compat, DISABLED_CONFIGURATION, 0
87{{type}}.RestrictRealtime, config_parse_warn_compat, DISABLED_CONFIGURATION, 0
88{{type}}.RestrictSUIDSGID, config_parse_warn_compat, DISABLED_CONFIGURATION, 0
89{{type}}.RestrictAddressFamilies, config_parse_warn_compat, DISABLED_CONFIGURATION, 0
90{{type}}.LockPersonality, config_parse_warn_compat, DISABLED_CONFIGURATION, 0
91{% endif %}
e59ccd03 92{{type}}.RestrictFileSystems, config_parse_restrict_filesystems, 0, offsetof({{type}}, exec_context)
997f52a5
ZJS
93{{type}}.LimitCPU, config_parse_rlimit, RLIMIT_CPU, offsetof({{type}}, exec_context.rlimit)
94{{type}}.LimitFSIZE, config_parse_rlimit, RLIMIT_FSIZE, offsetof({{type}}, exec_context.rlimit)
95{{type}}.LimitDATA, config_parse_rlimit, RLIMIT_DATA, offsetof({{type}}, exec_context.rlimit)
96{{type}}.LimitSTACK, config_parse_rlimit, RLIMIT_STACK, offsetof({{type}}, exec_context.rlimit)
97{{type}}.LimitCORE, config_parse_rlimit, RLIMIT_CORE, offsetof({{type}}, exec_context.rlimit)
98{{type}}.LimitRSS, config_parse_rlimit, RLIMIT_RSS, offsetof({{type}}, exec_context.rlimit)
99{{type}}.LimitNOFILE, config_parse_rlimit, RLIMIT_NOFILE, offsetof({{type}}, exec_context.rlimit)
100{{type}}.LimitAS, config_parse_rlimit, RLIMIT_AS, offsetof({{type}}, exec_context.rlimit)
101{{type}}.LimitNPROC, config_parse_rlimit, RLIMIT_NPROC, offsetof({{type}}, exec_context.rlimit)
102{{type}}.LimitMEMLOCK, config_parse_rlimit, RLIMIT_MEMLOCK, offsetof({{type}}, exec_context.rlimit)
103{{type}}.LimitLOCKS, config_parse_rlimit, RLIMIT_LOCKS, offsetof({{type}}, exec_context.rlimit)
104{{type}}.LimitSIGPENDING, config_parse_rlimit, RLIMIT_SIGPENDING, offsetof({{type}}, exec_context.rlimit)
105{{type}}.LimitMSGQUEUE, config_parse_rlimit, RLIMIT_MSGQUEUE, offsetof({{type}}, exec_context.rlimit)
106{{type}}.LimitNICE, config_parse_rlimit, RLIMIT_NICE, offsetof({{type}}, exec_context.rlimit)
107{{type}}.LimitRTPRIO, config_parse_rlimit, RLIMIT_RTPRIO, offsetof({{type}}, exec_context.rlimit)
108{{type}}.LimitRTTIME, config_parse_rlimit, RLIMIT_RTTIME, offsetof({{type}}, exec_context.rlimit)
109{{type}}.ReadWriteDirectories, config_parse_namespace_path_strv, 0, offsetof({{type}}, exec_context.read_write_paths)
110{{type}}.ReadOnlyDirectories, config_parse_namespace_path_strv, 0, offsetof({{type}}, exec_context.read_only_paths)
111{{type}}.InaccessibleDirectories, config_parse_namespace_path_strv, 0, offsetof({{type}}, exec_context.inaccessible_paths)
112{{type}}.ReadWritePaths, config_parse_namespace_path_strv, 0, offsetof({{type}}, exec_context.read_write_paths)
113{{type}}.ReadOnlyPaths, config_parse_namespace_path_strv, 0, offsetof({{type}}, exec_context.read_only_paths)
114{{type}}.InaccessiblePaths, config_parse_namespace_path_strv, 0, offsetof({{type}}, exec_context.inaccessible_paths)
115{{type}}.ExecPaths, config_parse_namespace_path_strv, 0, offsetof({{type}}, exec_context.exec_paths)
116{{type}}.NoExecPaths, config_parse_namespace_path_strv, 0, offsetof({{type}}, exec_context.no_exec_paths)
8c35c10d 117{{type}}.ExecSearchPath, config_parse_colon_separated_paths, 0, offsetof({{type}}, exec_context.exec_search_path)
997f52a5
ZJS
118{{type}}.BindPaths, config_parse_bind_paths, 0, offsetof({{type}}, exec_context)
119{{type}}.BindReadOnlyPaths, config_parse_bind_paths, 0, offsetof({{type}}, exec_context)
120{{type}}.TemporaryFileSystem, config_parse_temporary_filesystems, 0, offsetof({{type}}, exec_context)
121{{type}}.PrivateTmp, config_parse_bool, 0, offsetof({{type}}, exec_context.private_tmp)
122{{type}}.PrivateDevices, config_parse_bool, 0, offsetof({{type}}, exec_context.private_devices)
123{{type}}.ProtectKernelTunables, config_parse_bool, 0, offsetof({{type}}, exec_context.protect_kernel_tunables)
124{{type}}.ProtectKernelModules, config_parse_bool, 0, offsetof({{type}}, exec_context.protect_kernel_modules)
125{{type}}.ProtectKernelLogs, config_parse_bool, 0, offsetof({{type}}, exec_context.protect_kernel_logs)
126{{type}}.ProtectClock, config_parse_bool, 0, offsetof({{type}}, exec_context.protect_clock)
127{{type}}.ProtectControlGroups, config_parse_bool, 0, offsetof({{type}}, exec_context.protect_control_groups)
128{{type}}.NetworkNamespacePath, config_parse_unit_path_printf, 0, offsetof({{type}}, exec_context.network_namespace_path)
129{{type}}.IPCNamespacePath, config_parse_unit_path_printf, 0, offsetof({{type}}, exec_context.ipc_namespace_path)
130{{type}}.LogNamespace, config_parse_log_namespace, 0, offsetof({{type}}, exec_context)
131{{type}}.PrivateNetwork, config_parse_bool, 0, offsetof({{type}}, exec_context.private_network)
132{{type}}.PrivateUsers, config_parse_bool, 0, offsetof({{type}}, exec_context.private_users)
24002121 133{{type}}.PrivateMounts, config_parse_tristate, 0, offsetof({{type}}, exec_context.private_mounts)
997f52a5
ZJS
134{{type}}.PrivateIPC, config_parse_bool, 0, offsetof({{type}}, exec_context.private_ipc)
135{{type}}.ProtectSystem, config_parse_protect_system, 0, offsetof({{type}}, exec_context.protect_system)
136{{type}}.ProtectHome, config_parse_protect_home, 0, offsetof({{type}}, exec_context.protect_home)
874cdcbc 137{{type}}.MountFlags, config_parse_exec_mount_propagation_flag, 0, offsetof({{type}}, exec_context.mount_propagation_flag)
997f52a5
ZJS
138{{type}}.MountAPIVFS, config_parse_exec_mount_apivfs, 0, offsetof({{type}}, exec_context)
139{{type}}.Personality, config_parse_personality, 0, offsetof({{type}}, exec_context.personality)
b9c1883a 140{{type}}.RuntimeDirectoryPreserve, config_parse_exec_preserve_mode, 0, offsetof({{type}}, exec_context.runtime_directory_preserve_mode)
997f52a5 141{{type}}.RuntimeDirectoryMode, config_parse_mode, 0, offsetof({{type}}, exec_context.directories[EXEC_DIRECTORY_RUNTIME].mode)
211a3d87 142{{type}}.RuntimeDirectory, config_parse_exec_directories, 0, offsetof({{type}}, exec_context.directories[EXEC_DIRECTORY_RUNTIME])
997f52a5 143{{type}}.StateDirectoryMode, config_parse_mode, 0, offsetof({{type}}, exec_context.directories[EXEC_DIRECTORY_STATE].mode)
211a3d87 144{{type}}.StateDirectory, config_parse_exec_directories, 0, offsetof({{type}}, exec_context.directories[EXEC_DIRECTORY_STATE])
997f52a5 145{{type}}.CacheDirectoryMode, config_parse_mode, 0, offsetof({{type}}, exec_context.directories[EXEC_DIRECTORY_CACHE].mode)
211a3d87 146{{type}}.CacheDirectory, config_parse_exec_directories, 0, offsetof({{type}}, exec_context.directories[EXEC_DIRECTORY_CACHE])
997f52a5 147{{type}}.LogsDirectoryMode, config_parse_mode, 0, offsetof({{type}}, exec_context.directories[EXEC_DIRECTORY_LOGS].mode)
211a3d87 148{{type}}.LogsDirectory, config_parse_exec_directories, 0, offsetof({{type}}, exec_context.directories[EXEC_DIRECTORY_LOGS])
997f52a5 149{{type}}.ConfigurationDirectoryMode, config_parse_mode, 0, offsetof({{type}}, exec_context.directories[EXEC_DIRECTORY_CONFIGURATION].mode)
211a3d87 150{{type}}.ConfigurationDirectory, config_parse_exec_directories, 0, offsetof({{type}}, exec_context.directories[EXEC_DIRECTORY_CONFIGURATION])
997f52a5 151{{type}}.SetCredential, config_parse_set_credential, 0, offsetof({{type}}, exec_context)
43144be4 152{{type}}.SetCredentialEncrypted, config_parse_set_credential, 1, offsetof({{type}}, exec_context)
997f52a5 153{{type}}.LoadCredential, config_parse_load_credential, 0, offsetof({{type}}, exec_context)
43144be4 154{{type}}.LoadCredentialEncrypted, config_parse_load_credential, 1, offsetof({{type}}, exec_context)
bbfb25f4 155{{type}}.ImportCredential, config_parse_import_credential, 0, offsetof({{type}}, exec_context.import_credentials)
997f52a5
ZJS
156{{type}}.TimeoutCleanSec, config_parse_sec, 0, offsetof({{type}}, exec_context.timeout_clean_usec)
157{% if HAVE_PAM %}
158{{type}}.PAMName, config_parse_unit_string_printf, 0, offsetof({{type}}, exec_context.pam_name)
159{% else %}
160{{type}}.PAMName, config_parse_warn_compat, DISABLED_CONFIGURATION, 0
161{% endif %}
162{{type}}.IgnoreSIGPIPE, config_parse_bool, 0, offsetof({{type}}, exec_context.ignore_sigpipe)
163{{type}}.UtmpIdentifier, config_parse_unit_string_printf, 0, offsetof({{type}}, exec_context.utmp_id)
164{{type}}.UtmpMode, config_parse_exec_utmp_mode, 0, offsetof({{type}}, exec_context.utmp_mode)
165{% if HAVE_SELINUX %}
166{{type}}.SELinuxContext, config_parse_exec_selinux_context, 0, offsetof({{type}}, exec_context)
167{% else %}
168{{type}}.SELinuxContext, config_parse_warn_compat, DISABLED_CONFIGURATION, 0
169{% endif %}
170{% if HAVE_APPARMOR %}
171{{type}}.AppArmorProfile, config_parse_exec_apparmor_profile, 0, offsetof({{type}}, exec_context)
172{% else %}
173{{type}}.AppArmorProfile, config_parse_warn_compat, DISABLED_CONFIGURATION, 0
174{% endif %}
175{% if ENABLE_SMACK %}
176{{type}}.SmackProcessLabel, config_parse_exec_smack_process_label, 0, offsetof({{type}}, exec_context)
177{% else %}
178{{type}}.SmackProcessLabel, config_parse_warn_compat, DISABLED_CONFIGURATION, 0
179{% endif %}
180{{type}}.ProtectHostname, config_parse_bool, 0, offsetof({{type}}, exec_context.protect_hostname)
85614c6e 181{{type}}.MemoryKSM, config_parse_tristate, 0, offsetof({{type}}, exec_context.memory_ksm)
997f52a5
ZJS
182{%- endmacro -%}
183
184{%- macro KILL_CONTEXT_CONFIG_ITEMS(type) -%}
185{{type}}.SendSIGKILL, config_parse_bool, 0, offsetof({{type}}, kill_context.send_sigkill)
186{{type}}.SendSIGHUP, config_parse_bool, 0, offsetof({{type}}, kill_context.send_sighup)
187{{type}}.KillMode, config_parse_kill_mode, 0, offsetof({{type}}, kill_context.kill_mode)
188{{type}}.KillSignal, config_parse_signal, 0, offsetof({{type}}, kill_context.kill_signal)
189{{type}}.RestartKillSignal, config_parse_signal, 0, offsetof({{type}}, kill_context.restart_kill_signal)
190{{type}}.FinalKillSignal, config_parse_signal, 0, offsetof({{type}}, kill_context.final_kill_signal)
191{{type}}.WatchdogSignal, config_parse_signal, 0, offsetof({{type}}, kill_context.watchdog_signal)
192{%- endmacro -%}
193
194{%- macro CGROUP_CONTEXT_CONFIG_ITEMS(type) -%}
195{{type}}.Slice, config_parse_unit_slice, 0, 0
31d3a520
PM
196{{type}}.AllowedCPUs, config_parse_allowed_cpuset, 0, offsetof({{type}}, cgroup_context.cpuset_cpus)
197{{type}}.StartupAllowedCPUs, config_parse_allowed_cpuset, 0, offsetof({{type}}, cgroup_context.startup_cpuset_cpus)
198{{type}}.AllowedMemoryNodes, config_parse_allowed_cpuset, 0, offsetof({{type}}, cgroup_context.cpuset_mems)
199{{type}}.StartupAllowedMemoryNodes, config_parse_allowed_cpuset, 0, offsetof({{type}}, cgroup_context.startup_cpuset_mems)
997f52a5 200{{type}}.CPUAccounting, config_parse_bool, 0, offsetof({{type}}, cgroup_context.cpu_accounting)
c8340822 201{{type}}.CPUWeight, config_parse_cg_cpu_weight, 0, offsetof({{type}}, cgroup_context.cpu_weight)
202{{type}}.StartupCPUWeight, config_parse_cg_cpu_weight, 0, offsetof({{type}}, cgroup_context.startup_cpu_weight)
997f52a5
ZJS
203{{type}}.CPUShares, config_parse_cpu_shares, 0, offsetof({{type}}, cgroup_context.cpu_shares)
204{{type}}.StartupCPUShares, config_parse_cpu_shares, 0, offsetof({{type}}, cgroup_context.startup_cpu_shares)
205{{type}}.CPUQuota, config_parse_cpu_quota, 0, offsetof({{type}}, cgroup_context)
206{{type}}.CPUQuotaPeriodSec, config_parse_sec_def_infinity, 0, offsetof({{type}}, cgroup_context.cpu_quota_period_usec)
207{{type}}.MemoryAccounting, config_parse_bool, 0, offsetof({{type}}, cgroup_context.memory_accounting)
208{{type}}.MemoryMin, config_parse_memory_limit, 0, offsetof({{type}}, cgroup_context)
209{{type}}.DefaultMemoryMin, config_parse_memory_limit, 0, offsetof({{type}}, cgroup_context)
210{{type}}.DefaultMemoryLow, config_parse_memory_limit, 0, offsetof({{type}}, cgroup_context)
53fda560 211{{type}}.DefaultStartupMemoryLow, config_parse_memory_limit, 0, offsetof({{type}}, cgroup_context)
997f52a5 212{{type}}.MemoryLow, config_parse_memory_limit, 0, offsetof({{type}}, cgroup_context)
53fda560 213{{type}}.StartupMemoryLow, config_parse_memory_limit, 0, offsetof({{type}}, cgroup_context)
997f52a5 214{{type}}.MemoryHigh, config_parse_memory_limit, 0, offsetof({{type}}, cgroup_context)
53fda560 215{{type}}.StartupMemoryHigh, config_parse_memory_limit, 0, offsetof({{type}}, cgroup_context)
997f52a5 216{{type}}.MemoryMax, config_parse_memory_limit, 0, offsetof({{type}}, cgroup_context)
53fda560 217{{type}}.StartupMemoryMax, config_parse_memory_limit, 0, offsetof({{type}}, cgroup_context)
997f52a5 218{{type}}.MemorySwapMax, config_parse_memory_limit, 0, offsetof({{type}}, cgroup_context)
53fda560 219{{type}}.StartupMemorySwapMax, config_parse_memory_limit, 0, offsetof({{type}}, cgroup_context)
d7fe0a67 220{{type}}.MemoryZSwapMax, config_parse_memory_limit, 0, offsetof({{type}}, cgroup_context)
53fda560 221{{type}}.StartupMemoryZSwapMax, config_parse_memory_limit, 0, offsetof({{type}}, cgroup_context)
997f52a5
ZJS
222{{type}}.MemoryLimit, config_parse_memory_limit, 0, offsetof({{type}}, cgroup_context)
223{{type}}.DeviceAllow, config_parse_device_allow, 0, offsetof({{type}}, cgroup_context)
224{{type}}.DevicePolicy, config_parse_device_policy, 0, offsetof({{type}}, cgroup_context.device_policy)
225{{type}}.IOAccounting, config_parse_bool, 0, offsetof({{type}}, cgroup_context.io_accounting)
226{{type}}.IOWeight, config_parse_cg_weight, 0, offsetof({{type}}, cgroup_context.io_weight)
227{{type}}.StartupIOWeight, config_parse_cg_weight, 0, offsetof({{type}}, cgroup_context.startup_io_weight)
228{{type}}.IODeviceWeight, config_parse_io_device_weight, 0, offsetof({{type}}, cgroup_context)
229{{type}}.IOReadBandwidthMax, config_parse_io_limit, 0, offsetof({{type}}, cgroup_context)
230{{type}}.IOWriteBandwidthMax, config_parse_io_limit, 0, offsetof({{type}}, cgroup_context)
231{{type}}.IOReadIOPSMax, config_parse_io_limit, 0, offsetof({{type}}, cgroup_context)
232{{type}}.IOWriteIOPSMax, config_parse_io_limit, 0, offsetof({{type}}, cgroup_context)
233{{type}}.IODeviceLatencyTargetSec, config_parse_io_device_latency, 0, offsetof({{type}}, cgroup_context)
234{{type}}.BlockIOAccounting, config_parse_bool, 0, offsetof({{type}}, cgroup_context.blockio_accounting)
235{{type}}.BlockIOWeight, config_parse_blockio_weight, 0, offsetof({{type}}, cgroup_context.blockio_weight)
236{{type}}.StartupBlockIOWeight, config_parse_blockio_weight, 0, offsetof({{type}}, cgroup_context.startup_blockio_weight)
237{{type}}.BlockIODeviceWeight, config_parse_blockio_device_weight, 0, offsetof({{type}}, cgroup_context)
238{{type}}.BlockIOReadBandwidth, config_parse_blockio_bandwidth, 0, offsetof({{type}}, cgroup_context)
239{{type}}.BlockIOWriteBandwidth, config_parse_blockio_bandwidth, 0, offsetof({{type}}, cgroup_context)
240{{type}}.TasksAccounting, config_parse_bool, 0, offsetof({{type}}, cgroup_context.tasks_accounting)
241{{type}}.TasksMax, config_parse_tasks_max, 0, offsetof({{type}}, cgroup_context.tasks_max)
242{{type}}.Delegate, config_parse_delegate, 0, offsetof({{type}}, cgroup_context)
a8b993dc 243{{type}}.DelegateSubgroup, config_parse_delegate_subgroup , 0, offsetof({{type}}, cgroup_context)
997f52a5
ZJS
244{{type}}.DisableControllers, config_parse_disable_controllers, 0, offsetof({{type}}, cgroup_context)
245{{type}}.IPAccounting, config_parse_bool, 0, offsetof({{type}}, cgroup_context.ip_accounting)
84ebe6f0
YW
246{{type}}.IPAddressAllow, config_parse_in_addr_prefixes, AF_UNSPEC, offsetof({{type}}, cgroup_context.ip_address_allow)
247{{type}}.IPAddressDeny, config_parse_in_addr_prefixes, AF_UNSPEC, offsetof({{type}}, cgroup_context.ip_address_deny)
997f52a5
ZJS
248{{type}}.IPIngressFilterPath, config_parse_ip_filter_bpf_progs, 0, offsetof({{type}}, cgroup_context.ip_filters_ingress)
249{{type}}.IPEgressFilterPath, config_parse_ip_filter_bpf_progs, 0, offsetof({{type}}, cgroup_context.ip_filters_egress)
250{{type}}.ManagedOOMSwap, config_parse_managed_oom_mode, 0, offsetof({{type}}, cgroup_context.moom_swap)
251{{type}}.ManagedOOMMemoryPressure, config_parse_managed_oom_mode, 0, offsetof({{type}}, cgroup_context.moom_mem_pressure)
252{{type}}.ManagedOOMMemoryPressureLimit, config_parse_managed_oom_mem_pressure_limit, 0, offsetof({{type}}, cgroup_context.moom_mem_pressure_limit)
253{{type}}.ManagedOOMPreference, config_parse_managed_oom_preference, 0, offsetof({{type}}, cgroup_context.moom_preference)
254{{type}}.NetClass, config_parse_warn_compat, DISABLED_LEGACY, 0
255{{type}}.BPFProgram, config_parse_bpf_foreign_program, 0, offsetof({{type}}, cgroup_context)
256{{type}}.SocketBindAllow, config_parse_cgroup_socket_bind, 0, offsetof({{type}}, cgroup_context.socket_bind_allow)
257{{type}}.SocketBindDeny, config_parse_cgroup_socket_bind, 0, offsetof({{type}}, cgroup_context.socket_bind_deny)
4f0c25c7 258{{type}}.RestrictNetworkInterfaces, config_parse_restrict_network_interfaces, 0, offsetof({{type}}, cgroup_context)
054749e4
YW
259{{type}}.MemoryPressureThresholdSec, config_parse_sec, 0, offsetof({{type}}, cgroup_context.memory_pressure_threshold_usec)
260{{type}}.MemoryPressureWatch, config_parse_memory_pressure_watch, 0, offsetof({{type}}, cgroup_context.memory_pressure_watch)
dc7d69b3 261{{type}}.NFTSet, config_parse_cgroup_nft_set, NFT_SET_PARSE_CGROUP, offsetof({{type}}, cgroup_context)
997f52a5
ZJS
262{%- endmacro -%}
263
f975e971 264%{
4831981d
SL
265#if __GNUC__ >= 7
266_Pragma("GCC diagnostic ignored \"-Wimplicit-fallthrough\"")
267#endif
f975e971 268#include <stddef.h>
f5947a5e 269#include "all-units.h"
f975e971 270#include "conf-parser.h"
06e78680 271#include "image-policy.h"
84ebe6f0 272#include "in-addr-prefix-util.h"
f975e971
LP
273#include "load-fragment.h"
274%}
275struct ConfigPerfItem;
276%null_strings
277%language=ANSI-C
278%define slot-name section_and_lvalue
279%define hash-function-name load_fragment_gperf_hash
280%define lookup-function-name load_fragment_gperf_lookup
281%readonly-tables
282%omit-struct-type
283%struct-type
284%includes
285%%
620ed14e
AZ
286Unit.Description, config_parse_unit_string_printf, 0, offsetof(Unit, description)
287Unit.Documentation, config_parse_documentation, 0, offsetof(Unit, documentation)
288Unit.SourcePath, config_parse_unit_path_printf, 0, offsetof(Unit, source_path)
289Unit.Requires, config_parse_unit_deps, UNIT_REQUIRES, 0
290Unit.Requisite, config_parse_unit_deps, UNIT_REQUISITE, 0
291Unit.Wants, config_parse_unit_deps, UNIT_WANTS, 0
292Unit.BindsTo, config_parse_unit_deps, UNIT_BINDS_TO, 0
293Unit.BindTo, config_parse_unit_deps, UNIT_BINDS_TO, 0
0bc488c9 294Unit.Upholds, config_parse_unit_deps, UNIT_UPHOLDS, 0
620ed14e
AZ
295Unit.Conflicts, config_parse_unit_deps, UNIT_CONFLICTS, 0
296Unit.Before, config_parse_unit_deps, UNIT_BEFORE, 0
297Unit.After, config_parse_unit_deps, UNIT_AFTER, 0
294446dc 298Unit.OnSuccess, config_parse_unit_deps, UNIT_ON_SUCCESS, 0
620ed14e
AZ
299Unit.OnFailure, config_parse_unit_deps, UNIT_ON_FAILURE, 0
300Unit.PropagatesReloadTo, config_parse_unit_deps, UNIT_PROPAGATES_RELOAD_TO, 0
301Unit.PropagateReloadTo, config_parse_unit_deps, UNIT_PROPAGATES_RELOAD_TO, 0
302Unit.ReloadPropagatedFrom, config_parse_unit_deps, UNIT_RELOAD_PROPAGATED_FROM, 0
303Unit.PropagateReloadFrom, config_parse_unit_deps, UNIT_RELOAD_PROPAGATED_FROM, 0
ffec78c0
LP
304Unit.PropagatesStopTo, config_parse_unit_deps, UNIT_PROPAGATES_STOP_TO, 0
305Unit.StopPropagatedFrom, config_parse_unit_deps, UNIT_STOP_PROPAGATED_FROM, 0
620ed14e
AZ
306Unit.PartOf, config_parse_unit_deps, UNIT_PART_OF, 0
307Unit.JoinsNamespaceOf, config_parse_unit_deps, UNIT_JOINS_NAMESPACE_OF, 0
308Unit.RequiresOverridable, config_parse_obsolete_unit_deps, UNIT_REQUIRES, 0
309Unit.RequisiteOverridable, config_parse_obsolete_unit_deps, UNIT_REQUISITE, 0
310Unit.RequiresMountsFor, config_parse_unit_requires_mounts_for, 0, 0
311Unit.StopWhenUnneeded, config_parse_bool, 0, offsetof(Unit, stop_when_unneeded)
312Unit.RefuseManualStart, config_parse_bool, 0, offsetof(Unit, refuse_manual_start)
313Unit.RefuseManualStop, config_parse_bool, 0, offsetof(Unit, refuse_manual_stop)
314Unit.AllowIsolate, config_parse_bool, 0, offsetof(Unit, allow_isolate)
315Unit.DefaultDependencies, config_parse_bool, 0, offsetof(Unit, default_dependencies)
559214cb 316Unit.SurviveFinalKillSignal, config_parse_bool, 0, offsetof(Unit, survive_final_kill_signal)
294446dc 317Unit.OnSuccessJobMode, config_parse_job_mode, 0, offsetof(Unit, on_success_job_mode)
620ed14e 318Unit.OnFailureJobMode, config_parse_job_mode, 0, offsetof(Unit, on_failure_job_mode)
997f52a5 319{# The following is a legacy alias name for compatibility #}
620ed14e
AZ
320Unit.OnFailureIsolate, config_parse_job_mode_isolate, 0, offsetof(Unit, on_failure_job_mode)
321Unit.IgnoreOnIsolate, config_parse_bool, 0, offsetof(Unit, ignore_on_isolate)
322Unit.IgnoreOnSnapshot, config_parse_warn_compat, DISABLED_LEGACY, 0
323Unit.JobTimeoutSec, config_parse_job_timeout_sec, 0, 0
324Unit.JobRunningTimeoutSec, config_parse_job_running_timeout_sec, 0, 0
325Unit.JobTimeoutAction, config_parse_emergency_action, 0, offsetof(Unit, job_timeout_action)
326Unit.JobTimeoutRebootArgument, config_parse_unit_string_printf, 0, offsetof(Unit, job_timeout_reboot_arg)
327Unit.StartLimitIntervalSec, config_parse_sec, 0, offsetof(Unit, start_ratelimit.interval)
997f52a5 328{# The following is a legacy alias name for compatibility #}
620ed14e
AZ
329Unit.StartLimitInterval, config_parse_sec, 0, offsetof(Unit, start_ratelimit.interval)
330Unit.StartLimitBurst, config_parse_unsigned, 0, offsetof(Unit, start_ratelimit.burst)
331Unit.StartLimitAction, config_parse_emergency_action, 0, offsetof(Unit, start_limit_action)
332Unit.FailureAction, config_parse_emergency_action, 0, offsetof(Unit, failure_action)
333Unit.SuccessAction, config_parse_emergency_action, 0, offsetof(Unit, success_action)
334Unit.FailureActionExitStatus, config_parse_exit_status, 0, offsetof(Unit, failure_action_exit_status)
335Unit.SuccessActionExitStatus, config_parse_exit_status, 0, offsetof(Unit, success_action_exit_status)
336Unit.RebootArgument, config_parse_unit_string_printf, 0, offsetof(Unit, reboot_arg)
337Unit.ConditionPathExists, config_parse_unit_condition_path, CONDITION_PATH_EXISTS, offsetof(Unit, conditions)
338Unit.ConditionPathExistsGlob, config_parse_unit_condition_path, CONDITION_PATH_EXISTS_GLOB, offsetof(Unit, conditions)
339Unit.ConditionPathIsDirectory, config_parse_unit_condition_path, CONDITION_PATH_IS_DIRECTORY, offsetof(Unit, conditions)
340Unit.ConditionPathIsSymbolicLink, config_parse_unit_condition_path, CONDITION_PATH_IS_SYMBOLIC_LINK, offsetof(Unit, conditions)
341Unit.ConditionPathIsMountPoint, config_parse_unit_condition_path, CONDITION_PATH_IS_MOUNT_POINT, offsetof(Unit, conditions)
342Unit.ConditionPathIsReadWrite, config_parse_unit_condition_path, CONDITION_PATH_IS_READ_WRITE, offsetof(Unit, conditions)
343Unit.ConditionPathIsEncrypted, config_parse_unit_condition_path, CONDITION_PATH_IS_ENCRYPTED, offsetof(Unit, conditions)
344Unit.ConditionDirectoryNotEmpty, config_parse_unit_condition_path, CONDITION_DIRECTORY_NOT_EMPTY, offsetof(Unit, conditions)
345Unit.ConditionFileNotEmpty, config_parse_unit_condition_path, CONDITION_FILE_NOT_EMPTY, offsetof(Unit, conditions)
346Unit.ConditionFileIsExecutable, config_parse_unit_condition_path, CONDITION_FILE_IS_EXECUTABLE, offsetof(Unit, conditions)
347Unit.ConditionNeedsUpdate, config_parse_unit_condition_path, CONDITION_NEEDS_UPDATE, offsetof(Unit, conditions)
348Unit.ConditionFirstBoot, config_parse_unit_condition_string, CONDITION_FIRST_BOOT, offsetof(Unit, conditions)
349Unit.ConditionArchitecture, config_parse_unit_condition_string, CONDITION_ARCHITECTURE, offsetof(Unit, conditions)
cbcdcaaa 350Unit.ConditionFirmware, config_parse_unit_condition_string, CONDITION_FIRMWARE, offsetof(Unit, conditions)
620ed14e
AZ
351Unit.ConditionVirtualization, config_parse_unit_condition_string, CONDITION_VIRTUALIZATION, offsetof(Unit, conditions)
352Unit.ConditionHost, config_parse_unit_condition_string, CONDITION_HOST, offsetof(Unit, conditions)
353Unit.ConditionKernelCommandLine, config_parse_unit_condition_string, CONDITION_KERNEL_COMMAND_LINE, offsetof(Unit, conditions)
354Unit.ConditionKernelVersion, config_parse_unit_condition_string, CONDITION_KERNEL_VERSION, offsetof(Unit, conditions)
4f80cfca 355Unit.ConditionCredential, config_parse_unit_condition_string, CONDITION_CREDENTIAL, offsetof(Unit, conditions)
620ed14e
AZ
356Unit.ConditionSecurity, config_parse_unit_condition_string, CONDITION_SECURITY, offsetof(Unit, conditions)
357Unit.ConditionCapability, config_parse_unit_condition_string, CONDITION_CAPABILITY, offsetof(Unit, conditions)
358Unit.ConditionACPower, config_parse_unit_condition_string, CONDITION_AC_POWER, offsetof(Unit, conditions)
359Unit.ConditionMemory, config_parse_unit_condition_string, CONDITION_MEMORY, offsetof(Unit, conditions)
bb5824c9 360Unit.ConditionCPUFeature, config_parse_unit_condition_string, CONDITION_CPU_FEATURE, offsetof(Unit, conditions)
620ed14e
AZ
361Unit.ConditionCPUs, config_parse_unit_condition_string, CONDITION_CPUS, offsetof(Unit, conditions)
362Unit.ConditionEnvironment, config_parse_unit_condition_string, CONDITION_ENVIRONMENT, offsetof(Unit, conditions)
363Unit.ConditionUser, config_parse_unit_condition_string, CONDITION_USER, offsetof(Unit, conditions)
364Unit.ConditionGroup, config_parse_unit_condition_string, CONDITION_GROUP, offsetof(Unit, conditions)
365Unit.ConditionControlGroupController, config_parse_unit_condition_string, CONDITION_CONTROL_GROUP_CONTROLLER, offsetof(Unit, conditions)
1e26f8a6 366Unit.ConditionOSRelease, config_parse_unit_condition_string, CONDITION_OS_RELEASE, offsetof(Unit, conditions)
81513b38
LB
367Unit.ConditionMemoryPressure, config_parse_unit_condition_string, CONDITION_MEMORY_PRESSURE, offsetof(Unit, conditions)
368Unit.ConditionCPUPressure, config_parse_unit_condition_string, CONDITION_CPU_PRESSURE, offsetof(Unit, conditions)
369Unit.ConditionIOPressure, config_parse_unit_condition_string, CONDITION_IO_PRESSURE, offsetof(Unit, conditions)
620ed14e
AZ
370Unit.AssertPathExists, config_parse_unit_condition_path, CONDITION_PATH_EXISTS, offsetof(Unit, asserts)
371Unit.AssertPathExistsGlob, config_parse_unit_condition_path, CONDITION_PATH_EXISTS_GLOB, offsetof(Unit, asserts)
372Unit.AssertPathIsDirectory, config_parse_unit_condition_path, CONDITION_PATH_IS_DIRECTORY, offsetof(Unit, asserts)
373Unit.AssertPathIsSymbolicLink, config_parse_unit_condition_path, CONDITION_PATH_IS_SYMBOLIC_LINK, offsetof(Unit, asserts)
374Unit.AssertPathIsMountPoint, config_parse_unit_condition_path, CONDITION_PATH_IS_MOUNT_POINT, offsetof(Unit, asserts)
375Unit.AssertPathIsReadWrite, config_parse_unit_condition_path, CONDITION_PATH_IS_READ_WRITE, offsetof(Unit, asserts)
376Unit.AssertPathIsEncrypted, config_parse_unit_condition_path, CONDITION_PATH_IS_ENCRYPTED, offsetof(Unit, asserts)
377Unit.AssertDirectoryNotEmpty, config_parse_unit_condition_path, CONDITION_DIRECTORY_NOT_EMPTY, offsetof(Unit, asserts)
378Unit.AssertFileNotEmpty, config_parse_unit_condition_path, CONDITION_FILE_NOT_EMPTY, offsetof(Unit, asserts)
379Unit.AssertFileIsExecutable, config_parse_unit_condition_path, CONDITION_FILE_IS_EXECUTABLE, offsetof(Unit, asserts)
380Unit.AssertNeedsUpdate, config_parse_unit_condition_path, CONDITION_NEEDS_UPDATE, offsetof(Unit, asserts)
381Unit.AssertFirstBoot, config_parse_unit_condition_string, CONDITION_FIRST_BOOT, offsetof(Unit, asserts)
382Unit.AssertArchitecture, config_parse_unit_condition_string, CONDITION_ARCHITECTURE, offsetof(Unit, asserts)
383Unit.AssertVirtualization, config_parse_unit_condition_string, CONDITION_VIRTUALIZATION, offsetof(Unit, asserts)
384Unit.AssertHost, config_parse_unit_condition_string, CONDITION_HOST, offsetof(Unit, asserts)
385Unit.AssertKernelCommandLine, config_parse_unit_condition_string, CONDITION_KERNEL_COMMAND_LINE, offsetof(Unit, asserts)
386Unit.AssertKernelVersion, config_parse_unit_condition_string, CONDITION_KERNEL_VERSION, offsetof(Unit, asserts)
4f80cfca 387Unit.AssertCredential, config_parse_unit_condition_string, CONDITION_CREDENTIAL, offsetof(Unit, asserts)
620ed14e
AZ
388Unit.AssertSecurity, config_parse_unit_condition_string, CONDITION_SECURITY, offsetof(Unit, asserts)
389Unit.AssertCapability, config_parse_unit_condition_string, CONDITION_CAPABILITY, offsetof(Unit, asserts)
390Unit.AssertACPower, config_parse_unit_condition_string, CONDITION_AC_POWER, offsetof(Unit, asserts)
391Unit.AssertMemory, config_parse_unit_condition_string, CONDITION_MEMORY, offsetof(Unit, asserts)
bb5824c9 392Unit.AssertCPUFeature, config_parse_unit_condition_string, CONDITION_CPU_FEATURE, offsetof(Unit, asserts)
620ed14e
AZ
393Unit.AssertCPUs, config_parse_unit_condition_string, CONDITION_CPUS, offsetof(Unit, asserts)
394Unit.AssertEnvironment, config_parse_unit_condition_string, CONDITION_ENVIRONMENT, offsetof(Unit, asserts)
395Unit.AssertUser, config_parse_unit_condition_string, CONDITION_USER, offsetof(Unit, asserts)
396Unit.AssertGroup, config_parse_unit_condition_string, CONDITION_GROUP, offsetof(Unit, asserts)
397Unit.AssertControlGroupController, config_parse_unit_condition_string, CONDITION_CONTROL_GROUP_CONTROLLER, offsetof(Unit, asserts)
1e26f8a6 398Unit.AssertOSRelease, config_parse_unit_condition_string, CONDITION_OS_RELEASE, offsetof(Unit, asserts)
81513b38
LB
399Unit.AssertMemoryPressure, config_parse_unit_condition_string, CONDITION_MEMORY_PRESSURE, offsetof(Unit, asserts)
400Unit.AssertCPUPressure, config_parse_unit_condition_string, CONDITION_CPU_PRESSURE, offsetof(Unit, asserts)
401Unit.AssertIOPressure, config_parse_unit_condition_string, CONDITION_IO_PRESSURE, offsetof(Unit, asserts)
620ed14e 402Unit.CollectMode, config_parse_collect_mode, 0, offsetof(Unit, collect_mode)
620ed14e
AZ
403Service.PIDFile, config_parse_pid_file, 0, offsetof(Service, pid_file)
404Service.ExecCondition, config_parse_exec, SERVICE_EXEC_CONDITION, offsetof(Service, exec_command)
405Service.ExecStartPre, config_parse_exec, SERVICE_EXEC_START_PRE, offsetof(Service, exec_command)
406Service.ExecStart, config_parse_exec, SERVICE_EXEC_START, offsetof(Service, exec_command)
407Service.ExecStartPost, config_parse_exec, SERVICE_EXEC_START_POST, offsetof(Service, exec_command)
408Service.ExecReload, config_parse_exec, SERVICE_EXEC_RELOAD, offsetof(Service, exec_command)
409Service.ExecStop, config_parse_exec, SERVICE_EXEC_STOP, offsetof(Service, exec_command)
410Service.ExecStopPost, config_parse_exec, SERVICE_EXEC_STOP_POST, offsetof(Service, exec_command)
411Service.RestartSec, config_parse_sec, 0, offsetof(Service, restart_usec)
be1adc27 412Service.RestartSteps, config_parse_unsigned, 0, offsetof(Service, restart_steps)
e9f17fa8 413Service.RestartMaxDelaySec, config_parse_sec, 0, offsetof(Service, restart_max_delay_usec)
620ed14e
AZ
414Service.TimeoutSec, config_parse_service_timeout, 0, 0
415Service.TimeoutStartSec, config_parse_service_timeout, 0, 0
416Service.TimeoutStopSec, config_parse_sec_fix_0, 0, offsetof(Service, timeout_stop_usec)
417Service.TimeoutAbortSec, config_parse_service_timeout_abort, 0, 0
418Service.TimeoutStartFailureMode, config_parse_service_timeout_failure_mode, 0, offsetof(Service, timeout_start_failure_mode)
419Service.TimeoutStopFailureMode, config_parse_service_timeout_failure_mode, 0, offsetof(Service, timeout_stop_failure_mode)
420Service.RuntimeMaxSec, config_parse_sec, 0, offsetof(Service, runtime_max_usec)
5918a933 421Service.RuntimeRandomizedExtraSec, config_parse_sec, 0, offsetof(Service, runtime_rand_extra_usec)
620ed14e 422Service.WatchdogSec, config_parse_sec, 0, offsetof(Service, watchdog_usec)
997f52a5 423{# The following five only exist for compatibility, they moved into Unit, see above #}
620ed14e
AZ
424Service.StartLimitInterval, config_parse_sec, 0, offsetof(Unit, start_ratelimit.interval)
425Service.StartLimitBurst, config_parse_unsigned, 0, offsetof(Unit, start_ratelimit.burst)
426Service.StartLimitAction, config_parse_emergency_action, 0, offsetof(Unit, start_limit_action)
427Service.FailureAction, config_parse_emergency_action, 0, offsetof(Unit, failure_action)
428Service.RebootArgument, config_parse_unit_string_printf, 0, offsetof(Unit, reboot_arg)
429Service.Type, config_parse_service_type, 0, offsetof(Service, type)
596e4470 430Service.ExitType, config_parse_service_exit_type, 0, offsetof(Service, exit_type)
620ed14e 431Service.Restart, config_parse_service_restart, 0, offsetof(Service, restart)
e568fea9 432Service.RestartMode, config_parse_service_restart_mode, 0, offsetof(Service, restart_mode)
620ed14e
AZ
433Service.PermissionsStartOnly, config_parse_bool, 0, offsetof(Service, permissions_start_only)
434Service.RootDirectoryStartOnly, config_parse_bool, 0, offsetof(Service, root_directory_start_only)
435Service.RemainAfterExit, config_parse_bool, 0, offsetof(Service, remain_after_exit)
436Service.GuessMainPID, config_parse_bool, 0, offsetof(Service, guess_main_pid)
437Service.RestartPreventExitStatus, config_parse_set_status, 0, offsetof(Service, restart_prevent_status)
438Service.RestartForceExitStatus, config_parse_set_status, 0, offsetof(Service, restart_force_status)
439Service.SuccessExitStatus, config_parse_set_status, 0, offsetof(Service, success_status)
440Service.SysVStartPriority, config_parse_warn_compat, DISABLED_LEGACY, 0
441Service.NonBlocking, config_parse_bool, 0, offsetof(Service, exec_context.non_blocking)
442Service.BusName, config_parse_bus_name, 0, offsetof(Service, bus_name)
443Service.FileDescriptorStoreMax, config_parse_unsigned, 0, offsetof(Service, n_fd_store_max)
b9c1883a 444Service.FileDescriptorStorePreserve, config_parse_exec_preserve_mode, 0, offsetof(Service, fd_store_preserve_mode)
620ed14e
AZ
445Service.NotifyAccess, config_parse_notify_access, 0, offsetof(Service, notify_access)
446Service.Sockets, config_parse_service_sockets, 0, 0
447Service.BusPolicy, config_parse_warn_compat, DISABLED_LEGACY, 0
448Service.USBFunctionDescriptors, config_parse_unit_path_printf, 0, offsetof(Service, usb_function_descriptors)
449Service.USBFunctionStrings, config_parse_unit_path_printf, 0, offsetof(Service, usb_function_strings)
450Service.OOMPolicy, config_parse_oom_policy, 0, offsetof(Service, oom_policy)
cd48e23f 451Service.OpenFile, config_parse_open_file, 0, offsetof(Service, open_files)
3bd28bf7 452Service.ReloadSignal, config_parse_signal, 0, offsetof(Service, reload_signal)
997f52a5
ZJS
453{{ EXEC_CONTEXT_CONFIG_ITEMS('Service') }}
454{{ CGROUP_CONTEXT_CONFIG_ITEMS('Service') }}
455{{ KILL_CONTEXT_CONFIG_ITEMS('Service') }}
620ed14e
AZ
456Socket.ListenStream, config_parse_socket_listen, SOCKET_SOCKET, 0
457Socket.ListenDatagram, config_parse_socket_listen, SOCKET_SOCKET, 0
458Socket.ListenSequentialPacket, config_parse_socket_listen, SOCKET_SOCKET, 0
459Socket.ListenFIFO, config_parse_socket_listen, SOCKET_FIFO, 0
460Socket.ListenNetlink, config_parse_socket_listen, SOCKET_SOCKET, 0
461Socket.ListenSpecial, config_parse_socket_listen, SOCKET_SPECIAL, 0
462Socket.ListenMessageQueue, config_parse_socket_listen, SOCKET_MQUEUE, 0
463Socket.ListenUSBFunction, config_parse_socket_listen, SOCKET_USB_FUNCTION, 0
464Socket.SocketProtocol, config_parse_socket_protocol, 0, offsetof(Socket, socket_protocol)
465Socket.BindIPv6Only, config_parse_socket_bind, 0, offsetof(Socket, bind_ipv6_only)
466Socket.Backlog, config_parse_unsigned, 0, offsetof(Socket, backlog)
467Socket.BindToDevice, config_parse_socket_bindtodevice, 0, 0
468Socket.ExecStartPre, config_parse_exec, SOCKET_EXEC_START_PRE, offsetof(Socket, exec_command)
469Socket.ExecStartPost, config_parse_exec, SOCKET_EXEC_START_POST, offsetof(Socket, exec_command)
470Socket.ExecStopPre, config_parse_exec, SOCKET_EXEC_STOP_PRE, offsetof(Socket, exec_command)
471Socket.ExecStopPost, config_parse_exec, SOCKET_EXEC_STOP_POST, offsetof(Socket, exec_command)
472Socket.TimeoutSec, config_parse_sec_fix_0, 0, offsetof(Socket, timeout_usec)
473Socket.SocketUser, config_parse_user_group_compat, 0, offsetof(Socket, user)
474Socket.SocketGroup, config_parse_user_group_compat, 0, offsetof(Socket, group)
475Socket.SocketMode, config_parse_mode, 0, offsetof(Socket, socket_mode)
476Socket.DirectoryMode, config_parse_mode, 0, offsetof(Socket, directory_mode)
477Socket.Accept, config_parse_bool, 0, offsetof(Socket, accept)
478Socket.FlushPending, config_parse_bool, 0, offsetof(Socket, flush_pending)
479Socket.Writable, config_parse_bool, 0, offsetof(Socket, writable)
480Socket.MaxConnections, config_parse_unsigned, 0, offsetof(Socket, max_connections)
481Socket.MaxConnectionsPerSource, config_parse_unsigned, 0, offsetof(Socket, max_connections_per_source)
482Socket.KeepAlive, config_parse_bool, 0, offsetof(Socket, keep_alive)
483Socket.KeepAliveTimeSec, config_parse_sec, 0, offsetof(Socket, keep_alive_time)
484Socket.KeepAliveIntervalSec, config_parse_sec, 0, offsetof(Socket, keep_alive_interval)
485Socket.KeepAliveProbes, config_parse_unsigned, 0, offsetof(Socket, keep_alive_cnt)
486Socket.DeferAcceptSec, config_parse_sec, 0, offsetof(Socket, defer_accept)
487Socket.NoDelay, config_parse_bool, 0, offsetof(Socket, no_delay)
488Socket.Priority, config_parse_int, 0, offsetof(Socket, priority)
489Socket.ReceiveBuffer, config_parse_iec_size, 0, offsetof(Socket, receive_buffer)
490Socket.SendBuffer, config_parse_iec_size, 0, offsetof(Socket, send_buffer)
491Socket.IPTOS, config_parse_ip_tos, 0, offsetof(Socket, ip_tos)
492Socket.IPTTL, config_parse_int, 0, offsetof(Socket, ip_ttl)
493Socket.Mark, config_parse_int, 0, offsetof(Socket, mark)
494Socket.PipeSize, config_parse_iec_size, 0, offsetof(Socket, pipe_size)
495Socket.FreeBind, config_parse_bool, 0, offsetof(Socket, free_bind)
496Socket.Transparent, config_parse_bool, 0, offsetof(Socket, transparent)
497Socket.Broadcast, config_parse_bool, 0, offsetof(Socket, broadcast)
498Socket.PassCredentials, config_parse_bool, 0, offsetof(Socket, pass_cred)
499Socket.PassSecurity, config_parse_bool, 0, offsetof(Socket, pass_sec)
500Socket.PassPacketInfo, config_parse_bool, 0, offsetof(Socket, pass_pktinfo)
9b191525 501Socket.Timestamping, config_parse_socket_timestamping, 0, offsetof(Socket, timestamping)
620ed14e
AZ
502Socket.TCPCongestion, config_parse_string, 0, offsetof(Socket, tcp_congestion)
503Socket.ReusePort, config_parse_bool, 0, offsetof(Socket, reuse_port)
504Socket.MessageQueueMaxMessages, config_parse_long, 0, offsetof(Socket, mq_maxmsg)
505Socket.MessageQueueMessageSize, config_parse_long, 0, offsetof(Socket, mq_msgsize)
506Socket.RemoveOnStop, config_parse_bool, 0, offsetof(Socket, remove_on_stop)
507Socket.Symlinks, config_parse_unit_path_strv_printf, 0, offsetof(Socket, symlinks)
508Socket.FileDescriptorName, config_parse_fdname, 0, 0
509Socket.Service, config_parse_socket_service, 0, 0
510Socket.TriggerLimitIntervalSec, config_parse_sec, 0, offsetof(Socket, trigger_limit.interval)
511Socket.TriggerLimitBurst, config_parse_unsigned, 0, offsetof(Socket, trigger_limit.burst)
2bec84e7
LP
512Socket.PollLimitIntervalSec, config_parse_sec, 0, offsetof(Socket, poll_limit_interval)
513Socket.PollLimitBurst, config_parse_unsigned, 0, offsetof(Socket, poll_limit_burst)
997f52a5
ZJS
514{% if ENABLE_SMACK %}
515Socket.SmackLabel, config_parse_unit_string_printf, 0, offsetof(Socket, smack)
620ed14e 516Socket.SmackLabelIPIn, config_parse_unit_string_printf, 0, offsetof(Socket, smack_ip_in)
997f52a5
ZJS
517Socket.SmackLabelIPOut, config_parse_unit_string_printf, 0, offsetof(Socket, smack_ip_out)
518{% else %}
519Socket.SmackLabel, config_parse_warn_compat, DISABLED_CONFIGURATION, 0
620ed14e 520Socket.SmackLabelIPIn, config_parse_warn_compat, DISABLED_CONFIGURATION, 0
997f52a5
ZJS
521Socket.SmackLabelIPOut, config_parse_warn_compat, DISABLED_CONFIGURATION, 0
522{% endif %}
523{% if HAVE_SELINUX %}
524Socket.SELinuxContextFromNet, config_parse_bool, 0, offsetof(Socket, selinux_context_from_net)
525{% else %}
526Socket.SELinuxContextFromNet, config_parse_warn_compat, DISABLED_CONFIGURATION, 0
527{% endif %}
528{{ EXEC_CONTEXT_CONFIG_ITEMS('Socket') }}
529{{ CGROUP_CONTEXT_CONFIG_ITEMS('Socket') }}
530{{ KILL_CONTEXT_CONFIG_ITEMS('Socket') }}
620ed14e
AZ
531Mount.What, config_parse_unit_string_printf, 0, offsetof(Mount, parameters_fragment.what)
532Mount.Where, config_parse_unit_path_printf, 0, offsetof(Mount, where)
533Mount.Options, config_parse_unit_string_printf, 0, offsetof(Mount, parameters_fragment.options)
534Mount.Type, config_parse_unit_string_printf, 0, offsetof(Mount, parameters_fragment.fstype)
535Mount.TimeoutSec, config_parse_sec_fix_0, 0, offsetof(Mount, timeout_usec)
536Mount.DirectoryMode, config_parse_mode, 0, offsetof(Mount, directory_mode)
537Mount.SloppyOptions, config_parse_bool, 0, offsetof(Mount, sloppy_options)
538Mount.LazyUnmount, config_parse_bool, 0, offsetof(Mount, lazy_unmount)
539Mount.ForceUnmount, config_parse_bool, 0, offsetof(Mount, force_unmount)
540Mount.ReadWriteOnly, config_parse_bool, 0, offsetof(Mount, read_write_only)
997f52a5
ZJS
541{{ EXEC_CONTEXT_CONFIG_ITEMS('Mount') }}
542{{ CGROUP_CONTEXT_CONFIG_ITEMS('Mount') }}
543{{ KILL_CONTEXT_CONFIG_ITEMS('Mount') }}
620ed14e 544Automount.Where, config_parse_unit_path_printf, 0, offsetof(Automount, where)
7c5cef22 545Automount.ExtraOptions, config_parse_unit_string_printf, 0, offsetof(Automount, extra_options)
620ed14e
AZ
546Automount.DirectoryMode, config_parse_mode, 0, offsetof(Automount, directory_mode)
547Automount.TimeoutIdleSec, config_parse_sec_fix_0, 0, offsetof(Automount, timeout_idle_usec)
620ed14e
AZ
548Swap.What, config_parse_unit_path_printf, 0, offsetof(Swap, parameters_fragment.what)
549Swap.Priority, config_parse_swap_priority, 0, 0
550Swap.Options, config_parse_unit_string_printf, 0, offsetof(Swap, parameters_fragment.options)
551Swap.TimeoutSec, config_parse_sec_fix_0, 0, offsetof(Swap, timeout_usec)
997f52a5
ZJS
552{{ EXEC_CONTEXT_CONFIG_ITEMS('Swap') }}
553{{ CGROUP_CONTEXT_CONFIG_ITEMS('Swap') }}
554{{ KILL_CONTEXT_CONFIG_ITEMS('Swap') }}
620ed14e
AZ
555Timer.OnCalendar, config_parse_timer, TIMER_CALENDAR, 0
556Timer.OnActiveSec, config_parse_timer, TIMER_ACTIVE, 0
557Timer.OnBootSec, config_parse_timer, TIMER_BOOT, 0
558Timer.OnStartupSec, config_parse_timer, TIMER_STARTUP, 0
559Timer.OnUnitActiveSec, config_parse_timer, TIMER_UNIT_ACTIVE, 0
560Timer.OnUnitInactiveSec, config_parse_timer, TIMER_UNIT_INACTIVE, 0
561Timer.OnClockChange, config_parse_bool, 0, offsetof(Timer, on_clock_change)
562Timer.OnTimezoneChange, config_parse_bool, 0, offsetof(Timer, on_timezone_change)
563Timer.Persistent, config_parse_bool, 0, offsetof(Timer, persistent)
564Timer.WakeSystem, config_parse_bool, 0, offsetof(Timer, wake_system)
565Timer.RemainAfterElapse, config_parse_bool, 0, offsetof(Timer, remain_after_elapse)
acf24a1a 566Timer.FixedRandomDelay, config_parse_bool, 0, offsetof(Timer, fixed_random_delay)
620ed14e
AZ
567Timer.AccuracySec, config_parse_sec, 0, offsetof(Timer, accuracy_usec)
568Timer.RandomizedDelaySec, config_parse_sec, 0, offsetof(Timer, random_usec)
569Timer.Unit, config_parse_trigger_unit, 0, 0
620ed14e
AZ
570Path.PathExists, config_parse_path_spec, 0, 0
571Path.PathExistsGlob, config_parse_path_spec, 0, 0
572Path.PathChanged, config_parse_path_spec, 0, 0
573Path.PathModified, config_parse_path_spec, 0, 0
574Path.DirectoryNotEmpty, config_parse_path_spec, 0, 0
575Path.Unit, config_parse_trigger_unit, 0, 0
576Path.MakeDirectory, config_parse_bool, 0, offsetof(Path, make_directory)
577Path.DirectoryMode, config_parse_mode, 0, offsetof(Path, directory_mode)
47dba9fb
LB
578Path.TriggerLimitIntervalSec, config_parse_sec, 0, offsetof(Path, trigger_limit.interval)
579Path.TriggerLimitBurst, config_parse_unsigned, 0, offsetof(Path, trigger_limit.burst)
997f52a5
ZJS
580{{ CGROUP_CONTEXT_CONFIG_ITEMS('Slice') }}
581{{ CGROUP_CONTEXT_CONFIG_ITEMS('Scope') }}
582{{ KILL_CONTEXT_CONFIG_ITEMS('Scope') }}
620ed14e 583Scope.RuntimeMaxSec, config_parse_sec, 0, offsetof(Scope, runtime_max_usec)
5918a933 584Scope.RuntimeRandomizedExtraSec, config_parse_sec, 0, offsetof(Scope, runtime_rand_extra_usec)
620ed14e 585Scope.TimeoutStopSec, config_parse_sec, 0, offsetof(Scope, timeout_stop_usec)
d5a1657d 586Scope.OOMPolicy, config_parse_oom_policy, 0, offsetof(Scope, oom_policy)
997f52a5 587{# The [Install] section is ignored here #}
620ed14e
AZ
588Install.Alias, NULL, 0, 0
589Install.WantedBy, NULL, 0, 0
590Install.RequiredBy, NULL, 0, 0
38f90179 591Install.UpheldBy, NULL, 0, 0
620ed14e
AZ
592Install.Also, NULL, 0, 0
593Install.DefaultInstance, NULL, 0, 0