summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorDmitriyEshenko <dmitriy.eshenko@vyos.io>2021-02-23 18:56:47 +0000
committerDmitriyEshenko <dmitriy.eshenko@vyos.io>2021-02-23 18:56:47 +0000
commite218a757616d27a5c31a3c39a175c5e73a376f23 (patch)
tree365a5724c4f7da7cae0f0346dd2a6b8cbe72cd50 /scripts
parent1de3f19a2856d13b182962fe9eef5f655f6e75a5 (diff)
downloadvyos-build-e218a757616d27a5c31a3c39a175c5e73a376f23.tar.gz
vyos-build-e218a757616d27a5c31a3c39a175c5e73a376f23.zip
T3303: Modify os_release file for changing Welcome message on boot
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/make-version-file17
1 files changed, 17 insertions, 0 deletions
diff --git a/scripts/make-version-file b/scripts/make-version-file
index 5f394f3b..e35dfd8b 100755
--- a/scripts/make-version-file
+++ b/scripts/make-version-file
@@ -100,6 +100,18 @@ version_data = {
'build_comment': build_config['build_comment']
}
+os_release = f"""
+PRETTY_NAME="VyOS {version} ({build_config['release_train']})"
+NAME="VyOS"
+VERSION_ID="{version}"
+VERSION="{version} ({build_config['release_train']})"
+VERSION_CODENAME=buster
+ID=vyos
+HOME_URL="https://vyos.io"
+SUPPORT_URL="https://support.vyos.io"
+BUG_REPORT_URL="https://phabricator.vyos.net"
+"""
+
os.makedirs(os.path.join(defaults.CHROOT_INCLUDES_DIR, 'usr/share/vyos'), exist_ok=True)
with open(os.path.join(defaults.CHROOT_INCLUDES_DIR, 'usr/share/vyos/version.json'), 'w') as f:
json.dump(version_data, f)
@@ -116,3 +128,8 @@ with open(os.path.join(defaults.CHROOT_INCLUDES_DIR, 'opt/vyatta/etc/version'),
# neither we want to use lengthy paths in makefiles
with open(os.path.join(defaults.BUILD_DIR, 'version'), 'w') as f:
print(version, file=f)
+
+# Define variables that influence to welcome message on boot
+os.makedirs(os.path.join(defaults.CHROOT_INCLUDES_DIR, 'usr/lib/'), exist_ok=True)
+with open(os.path.join(defaults.CHROOT_INCLUDES_DIR, 'usr/lib//os-release'), 'w') as f:
+ print(os_release, file=f)