summaryrefslogtreecommitdiff
path: root/config
diff options
context:
space:
mode:
authorScott Moser <smoser@brickies.net>2017-06-15 10:03:45 -0400
committerScott Moser <smoser@brickies.net>2017-06-15 17:10:54 -0400
commitecb408afa1104fe49ce6eb1dc5708be56abd5cb2 (patch)
tree8d1161c2f44f07aec73348fa6d2c8a14701d7dd6 /config
parent9ccb8f5e2ab262ee04bb9c103c1302479f7c81d3 (diff)
downloadvyos-cloud-init-ecb408afa1104fe49ce6eb1dc5708be56abd5cb2.tar.gz
vyos-cloud-init-ecb408afa1104fe49ce6eb1dc5708be56abd5cb2.zip
FreeBSD: Make freebsd a variant, fix unittests and tools/build-on-freebsd.
- Simplify the logic of 'variant' in util.system_info much of the data from https://github.com/hpcugent/easybuild/wiki/OS_flavor_name_version - fix get_resource_disk_on_freebsd when running on a system without an Azure resource disk. - fix tools/build-on-freebsd to replace oauth with oauthlib and add bash which is a dependency for tests. - update a fiew places that were checking for freebsd but not using the util.is_FreeBSD()
Diffstat (limited to 'config')
-rw-r--r--config/cloud.cfg.tmpl20
1 files changed, 9 insertions, 11 deletions
diff --git a/config/cloud.cfg.tmpl b/config/cloud.cfg.tmpl
index 5af2a88f..f4b9069b 100644
--- a/config/cloud.cfg.tmpl
+++ b/config/cloud.cfg.tmpl
@@ -2,7 +2,7 @@
# The top level settings are used as module
# and system configuration.
-{% if variant in ["bsd"] %}
+{% if variant in ["freebsd"] %}
syslog_fix_perms: root:wheel
{% endif %}
# A set of users which may be applied and/or used by various modules
@@ -13,7 +13,7 @@ users:
# If this is set, 'root' will not be able to ssh in and they
# will get a message to login instead as the default $user
-{% if variant in ["bsd"] %}
+{% if variant in ["freebsd"] %}
disable_root: false
{% else %}
disable_root: true
@@ -30,7 +30,7 @@ ssh_pwauth: 0
# This will cause the set+update hostname module to not operate (if true)
preserve_hostname: false
-{% if variant in ["bsd"] %}
+{% if variant in ["freebsd"] %}
# This should not be required, but leave it in place until the real cause of
# not beeing able to find -any- datasources is resolved.
datasource_list: ['ConfigDrive', 'Azure', 'OpenStack', 'Ec2']
@@ -53,13 +53,13 @@ cloud_init_modules:
- write-files
- growpart
- resizefs
-{% if variant not in ["bsd"] %}
+{% if variant not in ["freebsd"] %}
- disk_setup
- mounts
{% endif %}
- set_hostname
- update_hostname
-{% if variant not in ["bsd"] %}
+{% if variant not in ["freebsd"] %}
- update_etc_hosts
- ca-certs
- rsyslog
@@ -87,7 +87,7 @@ cloud_config_modules:
- apt-pipelining
- apt-configure
{% endif %}
-{% if variant not in ["bsd"] %}
+{% if variant not in ["freebsd"] %}
- ntp
{% endif %}
- timezone
@@ -108,7 +108,7 @@ cloud_final_modules:
- landscape
- lxd
{% endif %}
-{% if variant not in ["bsd"] %}
+{% if variant not in ["freebsd"] %}
- puppet
- chef
- salt-minion
@@ -130,10 +130,8 @@ cloud_final_modules:
# (not accessible to handlers/transforms)
system_info:
# This will affect which distro class gets used
-{% if variant in ["centos", "debian", "fedora", "rhel", "ubuntu"] %}
+{% if variant in ["centos", "debian", "fedora", "rhel", "ubuntu", "freebsd"] %}
distro: {{ variant }}
-{% elif variant in ["bsd"] %}
- distro: freebsd
{% else %}
# Unknown/fallback distro.
distro: ubuntu
@@ -182,7 +180,7 @@ system_info:
cloud_dir: /var/lib/cloud/
templates_dir: /etc/cloud/templates/
ssh_svcname: sshd
-{% elif variant in ["bsd"] %}
+{% elif variant in ["freebsd"] %}
# Default user name + that default users groups (if added/used)
default_user:
name: freebsd