The optional positional argument to "systemctl reboot" is now
being deprecated in favor of this option.
+ * Support for the .include syntax in unit files has been removed. The
+ concept has been obsolete for 6 years and we started warning about
+ its pending removal 2 years ago (also see NEWS file below). It's
+ finally gone now.
+
CHANGES WITH 245:
* A new tool "systemd-repart" has been added, that operates as an
<filename>foo-.service.d/10-override.conf</filename> would override
<filename>service.d/10-override.conf</filename>.</para>
- <!-- Note that we do not document .include here, as we consider it mostly obsolete, and want
- people to use .d/ drop-ins instead. -->
-
<para>Note that while systemd offers a flexible dependency system
between units it is recommended to use this functionality only
sparingly and instead rely on techniques such as bus-based or
r = config_parse(u->id, fragment, f,
UNIT_VTABLE(u)->sections,
config_item_perf_lookup, load_fragment_gperf_lookup,
- CONFIG_PARSE_ALLOW_INCLUDE,
+ 0,
u,
NULL);
if (r == -ENOEXEC)
name, name, f,
UNIT_VTABLE(u)->sections,
config_item_perf_lookup, load_fragment_gperf_lookup,
- CONFIG_PARSE_ALLOW_INCLUDE,
+ 0,
u,
NULL);
char *l,
void *userdata) {
- char *e, *include;
+ char *e;
assert(filename);
assert(line > 0);
if (*l == '\n')
return 0;
- include = first_word(l, ".include");
- if (include) {
- _cleanup_free_ char *fn = NULL;
-
- /* .includes are a bad idea, we only support them here
- * for historical reasons. They create cyclic include
- * problems and make it difficult to detect
- * configuration file changes with an easy
- * stat(). Better approaches, such as .d/ drop-in
- * snippets exist.
- *
- * Support for them should be eventually removed. */
-
- if (!(flags & CONFIG_PARSE_ALLOW_INCLUDE)) {
- log_syntax(unit, LOG_ERR, filename, line, 0, ".include not allowed here. Ignoring.");
- return 0;
- }
-
- log_syntax(unit, LOG_WARNING, filename, line, 0,
- ".include directives are deprecated, and support for them will be removed in a future version of systemd. "
- "Please use drop-in files instead.");
-
- fn = file_in_same_dir(filename, strstrip(include));
- if (!fn)
- return -ENOMEM;
-
- return config_parse(unit, fn, NULL, sections, lookup, table, flags, userdata, NULL);
- }
-
if (!utf8_is_valid(l))
return log_syntax_invalid_utf8(unit, LOG_WARNING, filename, line, l);
typedef enum ConfigParseFlags {
CONFIG_PARSE_RELAXED = 1 << 0, /* Do not warn about unknown non-extension fields */
- CONFIG_PARSE_ALLOW_INCLUDE = 1 << 1, /* Allow the deprecated .include stanza */
- CONFIG_PARSE_WARN = 1 << 2, /* Emit non-debug messages */
+ CONFIG_PARSE_WARN = 1 << 1, /* Emit non-debug messages */
} ConfigParseFlags;
/* Argument list for parsers of specific configuration settings. */
"-Target\0"
"-Timer\0",
config_item_table_lookup, items,
- CONFIG_PARSE_ALLOW_INCLUDE, info,
+ 0, info,
NULL);
if (r < 0)
return log_debug_errno(r, "Failed to parse %s: %m", info->name);