1 /* SPDX-License-Identifier: LGPL-2.1-or-later */ 2 #pragma once 3 4 #define SPECIAL_DEFAULT_TARGET "default.target" 5 #define SPECIAL_INITRD_TARGET "initrd.target" 6 7 /* Shutdown targets */ 8 #define SPECIAL_UMOUNT_TARGET "umount.target" 9 /* This is not really intended to be started by directly. This is 10 * mostly so that other targets (reboot/halt/poweroff) can depend on 11 * it to bring all services down that want to be brought down on 12 * system shutdown. */ 13 #define SPECIAL_SHUTDOWN_TARGET "shutdown.target" 14 #define SPECIAL_HALT_TARGET "halt.target" 15 #define SPECIAL_POWEROFF_TARGET "poweroff.target" 16 #define SPECIAL_REBOOT_TARGET "reboot.target" 17 #define SPECIAL_KEXEC_TARGET "kexec.target" 18 #define SPECIAL_EXIT_TARGET "exit.target" 19 #define SPECIAL_SUSPEND_TARGET "suspend.target" 20 #define SPECIAL_HIBERNATE_TARGET "hibernate.target" 21 #define SPECIAL_HYBRID_SLEEP_TARGET "hybrid-sleep.target" 22 #define SPECIAL_SUSPEND_THEN_HIBERNATE_TARGET "suspend-then-hibernate.target" 23 #define SPECIAL_FACTORY_RESET_TARGET "factory-reset.target" 24 25 /* Special boot targets */ 26 #define SPECIAL_RESCUE_TARGET "rescue.target" 27 #define SPECIAL_EMERGENCY_TARGET "emergency.target" 28 #define SPECIAL_MULTI_USER_TARGET "multi-user.target" 29 #define SPECIAL_GRAPHICAL_TARGET "graphical.target" 30 31 /* Early boot targets */ 32 #define SPECIAL_SYSINIT_TARGET "sysinit.target" 33 #define SPECIAL_SOCKETS_TARGET "sockets.target" 34 #define SPECIAL_TIMERS_TARGET "timers.target" 35 #define SPECIAL_PATHS_TARGET "paths.target" 36 #define SPECIAL_LOCAL_FS_TARGET "local-fs.target" 37 #define SPECIAL_LOCAL_FS_PRE_TARGET "local-fs-pre.target" 38 #define SPECIAL_INITRD_FS_TARGET "initrd-fs.target" 39 #define SPECIAL_INITRD_ROOT_DEVICE_TARGET "initrd-root-device.target" 40 #define SPECIAL_INITRD_ROOT_FS_TARGET "initrd-root-fs.target" 41 #define SPECIAL_INITRD_USR_FS_TARGET "initrd-usr-fs.target" 42 #define SPECIAL_REMOTE_FS_TARGET "remote-fs.target" /* LSB's $remote_fs */ 43 #define SPECIAL_REMOTE_FS_PRE_TARGET "remote-fs-pre.target" 44 #define SPECIAL_SWAP_TARGET "swap.target" 45 #define SPECIAL_NETWORK_ONLINE_TARGET "network-online.target" 46 #define SPECIAL_TIME_SYNC_TARGET "time-sync.target" /* LSB's $time */ 47 #define SPECIAL_TIME_SET_TARGET "time-set.target" 48 #define SPECIAL_BASIC_TARGET "basic.target" 49 50 /* LSB compatibility */ 51 #define SPECIAL_NETWORK_TARGET "network.target" /* LSB's $network */ 52 #define SPECIAL_NSS_LOOKUP_TARGET "nss-lookup.target" /* LSB's $named */ 53 #define SPECIAL_RPCBIND_TARGET "rpcbind.target" /* LSB's $portmap */ 54 55 /* 56 * Rules regarding adding further high level targets like the above: 57 * 58 * - Be conservative, only add more of these when we really need 59 * them. We need strong usecases for further additions. 60 * 61 * - When there can be multiple implementations running side-by-side, 62 * it needs to be a .target unit which can pull in all 63 * implementations. 64 * 65 * - If something can be implemented with socket activation, and 66 * without, it needs to be a .target unit, so that it can pull in 67 * the appropriate unit. 68 * 69 * - Otherwise, it should be a .service unit. 70 * 71 * - In some cases it is OK to have both a .service and a .target 72 * unit, i.e. if there can be multiple parallel implementations, but 73 * only one is the "system" one. Example: syslog. 74 * 75 * Or to put this in other words: .service symlinks can be used to 76 * arbitrate between multiple implementations if there can be only one 77 * of a kind. .target units can be used to support multiple 78 * implementations that can run side-by-side. 79 */ 80 81 /* Magic early boot services */ 82 #define SPECIAL_FSCK_SERVICE "systemd-fsck@.service" 83 #define SPECIAL_FSCK_ROOT_SERVICE "systemd-fsck-root.service" 84 #define SPECIAL_FSCK_USR_SERVICE "systemd-fsck-usr.service" 85 #define SPECIAL_QUOTACHECK_SERVICE "systemd-quotacheck.service" 86 #define SPECIAL_QUOTAON_SERVICE "quotaon.service" 87 #define SPECIAL_REMOUNT_FS_SERVICE "systemd-remount-fs.service" 88 #define SPECIAL_VOLATILE_ROOT_SERVICE "systemd-volatile-root.service" 89 #define SPECIAL_UDEVD_SERVICE "systemd-udevd.service" 90 91 /* Services systemd relies on */ 92 #define SPECIAL_DBUS_SERVICE "dbus.service" 93 #define SPECIAL_DBUS_SOCKET "dbus.socket" 94 #define SPECIAL_JOURNALD_SOCKET "systemd-journald.socket" 95 #define SPECIAL_JOURNALD_SERVICE "systemd-journald.service" 96 #define SPECIAL_TMPFILES_SETUP_SERVICE "systemd-tmpfiles-setup.service" 97 98 /* Magic init signals */ 99 #define SPECIAL_KBREQUEST_TARGET "kbrequest.target" 100 #define SPECIAL_SIGPWR_TARGET "sigpwr.target" 101 #define SPECIAL_CTRL_ALT_DEL_TARGET "ctrl-alt-del.target" 102 103 /* Where we add all our system units, users and machines by default */ 104 #define SPECIAL_SYSTEM_SLICE "system.slice" 105 #define SPECIAL_USER_SLICE "user.slice" 106 #define SPECIAL_MACHINE_SLICE "machine.slice" 107 #define SPECIAL_ROOT_SLICE "-.slice" 108 109 /* The scope unit systemd itself lives in. */ 110 #define SPECIAL_INIT_SCOPE "init.scope" 111 112 /* The root directory. */ 113 #define SPECIAL_ROOT_MOUNT "-.mount" 114 115 /* Special slices valid for the user instance */ 116 #define SPECIAL_SESSION_SLICE "session.slice" 117 #define SPECIAL_APP_SLICE "app.slice" 118 #define SPECIAL_BACKGROUND_SLICE "background.slice" 119