valeriyvdovin / rpms / systemd

Forked from rpms/systemd 4 years ago
Clone

Blame SOURCES/0198-Add-VARIANT-as-a-standard-value-for-etc-os-release.patch

803fb7
From e31c6804ca177ab911f6212b34930969b83f2d30 Mon Sep 17 00:00:00 2001
803fb7
From: Stephen Gallagher <sgallagh@redhat.com>
803fb7
Date: Wed, 29 Apr 2015 08:19:05 -0400
803fb7
Subject: [PATCH] Add VARIANT as a standard value for /etc/os-release
803fb7
803fb7
Some distributions (such as Fedora) are using the VARIANT field to
803fb7
indicate to select packages which of several default configurations
803fb7
they should be using. For example, VARIANT=Server provides a
803fb7
different default firewall configuration (blocking basically
803fb7
everything but SSH and the management console) whereas
803fb7
VARIANT=Workstation opens many other ports for application
803fb7
compatibility.
803fb7
803fb7
By adding this patch to the manual pages, we can standardize on a
803fb7
cross-distribution mechanism for accomplishing this.
803fb7
803fb7
Fedora implementation details are available at
803fb7
https://fedoraproject.org/wiki/Packaging:Per-Product_Configuration
803fb7
803fb7
(David: drop double paranthesis)
803fb7
803fb7
(cherry picked from commit be7d0048ddda1e994f651e2825f96266d537d10d)
803fb7
803fb7
Cherry-picked from: be7d004
803fb7
Resolves: #1222517
803fb7
---
803fb7
 man/os-release.xml | 35 +++++++++++++++++++++++++++++++++++
803fb7
 1 file changed, 35 insertions(+)
803fb7
803fb7
diff --git a/man/os-release.xml b/man/os-release.xml
803fb7
index 4f57323d4..4ca2e5970 100644
803fb7
--- a/man/os-release.xml
803fb7
+++ b/man/os-release.xml
803fb7
@@ -273,6 +273,41 @@
803fb7
         </para></listitem>
803fb7
       </varlistentry>
803fb7
 
803fb7
+      <varlistentry>
803fb7
+        <term><varname>VARIANT=</varname></term>
803fb7
+
803fb7
+        <listitem><para>
803fb7
+        A string identifying a specific variant or edition of the
803fb7
+        operating system suitable for presentation to the user. This
803fb7
+        field may be used to inform the user that the configuration of
803fb7
+        this system is subject to a specific divergent set of rules or
803fb7
+        default configuration settings. This field is optional and may
803fb7
+        not be implemented on all systems.
803fb7
+        Examples:
803fb7
+        <literal>VARIANT="Server Edition"</literal>,
803fb7
+        <literal>VARIANT="Smart Refrigerator Edition"</literal>
803fb7
+        Note: this field is for display purposes only. The
803fb7
+        <varname>VARIANT_ID</varname> field should be used for making
803fb7
+        programmatic decisions.
803fb7
+        </para></listitem>
803fb7
+      </varlistentry>
803fb7
+
803fb7
+      <varlistentry>
803fb7
+        <term><varname>VARIANT_ID=</varname></term>
803fb7
+
803fb7
+        <listitem><para>
803fb7
+        A lower-case string (no spaces or other characters outside of
803fb7
+        0-9, a-z, ".", "_" and "-"), identifying a specific variant or
803fb7
+        edition of the operating system. This may be interpreted by
803fb7
+        other packages in order to determine a divergent default
803fb7
+        configuration. This field is optional and may not be
803fb7
+        implemented on all systems.
803fb7
+        Examples:
803fb7
+        <literal>VARIANT_ID=server</literal>,
803fb7
+        <literal>VARIANT_ID=embedded</literal>
803fb7
+        </para></listitem>
803fb7
+      </varlistentry>
803fb7
+
803fb7
     </variablelist>
803fb7
 
803fb7
     <para>If you are reading this file from C code or a shell script