Hello community, here is the log from the commit of package caasp-tools for openSUSE:Factory checked in at 2017-09-23 21:34:40 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/caasp-tools (Old) and /work/SRC/openSUSE:Factory/.caasp-tools.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "caasp-tools" Sat Sep 23 21:34:40 2017 rev:11 rq:528139 version:0.25 Changes: -------- --- /work/SRC/openSUSE:Factory/caasp-tools/caasp-tools.changes 2017-09-13 22:37:21.700253957 +0200 +++ /work/SRC/openSUSE:Factory/.caasp-tools.new/caasp-tools.changes 2017-09-23 21:34:47.761517108 +0200 @@ -1,0 +2,6 @@ +Thu Sep 21 19:50:18 UTC 2017 - [email protected] + +- Move cc_suse_caasp.py out of tar archive and install with in the + right python directory + +------------------------------------------------------------------- Old: ---- MicroOS-tools-0.24.tar.bz2 New: ---- MicroOS-tools-0.25.tar.bz2 cc_suse_caasp.py ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ caasp-tools.spec ++++++ --- /var/tmp/diff_new_pack.7SRh6p/_old 2017-09-23 21:34:48.513411366 +0200 +++ /var/tmp/diff_new_pack.7SRh6p/_new 2017-09-23 21:34:48.517410803 +0200 @@ -17,7 +17,7 @@ Name: caasp-tools -Version: 0.24 +Version: 0.25 Release: 0 Summary: Files and Scripts for SUSE CaaS Platform License: GPL-2.0+ @@ -25,8 +25,14 @@ Source0: MicroOS-tools-%{version}.tar.bz2 Source1: create_autoyast_profile.pl Source2: COPYING +Source3: cc_suse_caasp.py BuildRequires: distribution-release BuildRequires: dracut +%if 0%{?suse_version} < 1330 +BuildRequires: python2-base +%else +BuildRequires: python3-base +%endif BuildRequires: salt-minion BuildRequires: systemd Requires: perl-JSON @@ -62,6 +68,11 @@ pod2man %{SOURCE1} > %{buildroot}%{_mandir}/man8/create_autoyast_profile.8 mkdir -p %{buildroot}%{_docdir}/%{name} install -D -m644 %{SOURCE2} %{buildroot}%{_docdir}/%{name}/COPYING +%if 0%{?suse_version} < 1330 +install -D -m644 %{SOURCE3} %{buildroot}%{python_sitelib}/cloudinit/config/cc_suse_caasp.py +%else +install -D -m644 %{SOURCE3} %{buildroot}%{python3_sitelib}/cloudinit/config/cc_suse_caasp.py +%endif %if ! 0%{?is_susecaasp} mkdir -p %{buildroot}/usr/share/caasp-container-manifests echo -e "#!/bin/bash\ntrue" > %{buildroot}%{_datadir}/caasp-container-manifests/activate.sh ++++++ MicroOS-tools-0.24.tar.bz2 -> MicroOS-tools-0.25.tar.bz2 ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/MicroOS-tools-0.24/usr/lib/python2.7/site-packages/cloudinit/config/cc_suse_caasp.py new/MicroOS-tools-0.25/usr/lib/python2.7/site-packages/cloudinit/config/cc_suse_caasp.py --- old/MicroOS-tools-0.24/usr/lib/python2.7/site-packages/cloudinit/config/cc_suse_caasp.py 2017-06-27 15:30:45.373885191 +0200 +++ new/MicroOS-tools-0.25/usr/lib/python2.7/site-packages/cloudinit/config/cc_suse_caasp.py 1970-01-01 01:00:00.000000000 +0100 @@ -1,79 +0,0 @@ -# vi: ts=4 expandtab -# -# Copyright (C) 2017 SUSE LLC -# -# Author: Thorsten Kukuk <[email protected]> -# -# This program is free software; you can redistribute it and/or -# modify it under the terms of the GNU General Public License -# in Version 2 or later as published by the Free Software Foundation. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see <http://www.gnu.org/licenses/>. - -from cloudinit.settings import PER_INSTANCE -from cloudinit import util - -frequency = PER_INSTANCE - -DEFAULT_PERMS = 0o644 - -# suse_caasp: -# role: [admin|cluster] -# admin_node: admin-node.example.com - -def enable_service(service): - cmd = ['systemctl', 'enable', '--now', service] - util.subp(cmd, capture=True) - -def handle(name, cfg, cloud, log, args): - if len(args) != 0: - caasp_cfg = util.read_conf(args[0]) - else: - if 'suse_caasp' not in cfg: - log.debug(("Skipping module named %s, " - "no 'suse_caasp' configuration found"), name) - return - caasp_cfg = cfg['suse_caasp'] - - if 'role' not in caasp_cfg: - log.warn(("Skipping module named %s, " - "no 'role' found in 'suse_caasp' configuration"), name) - return - system_role = caasp_cfg['role'] - - if system_role == 'admin': - log.debug(("role administration node found")) - cmd = ['/usr/share/caasp-container-manifests/activate.sh'] - util.subp(cmd, capture=True) - enable_service('admin-node-setup') - enable_service('docker') - enable_service('container-feeder') - enable_service('etcd') - enable_service('kubelet') - enable_service('salt-minion') - elif system_role == 'cluster': - log.debug(("role cluster node found")) - if 'admin_node' not in caasp_cfg: - log.warn(("Skipping module named %s, " - "no 'admin_node' found for cluster system role"), name) - return - admin_node = caasp_cfg['admin_node'] - - contents = "master: %s" % (admin_node) - util.write_file('/etc/salt/minion.d/master.conf', contents, mode=DEFAULT_PERMS) - sed_arg = "s|#NTP=.*|NTP=%s|g" % (admin_node) - cmd = ['sed', '-i', '-e', sed_arg, '/etc/systemd/timesyncd.conf'] - util.subp(cmd, capture=True) - - enable_service('docker') - enable_service('container-feeder') - enable_service('salt-minion') - enable_service('systemd-timesyncd') - else: - log.warn(("Unknown role %s, skipping module named %s"), role, name) ++++++ cc_suse_caasp.py ++++++ # vi: ts=4 expandtab # # Copyright (C) 2017 SUSE LLC # # Author: Thorsten Kukuk <[email protected]> # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # in Version 2 or later as published by the Free Software Foundation. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. from cloudinit.settings import PER_INSTANCE from cloudinit import util frequency = PER_INSTANCE DEFAULT_PERMS = 0o644 # suse_caasp: # role: [admin|cluster] # admin_node: admin-node.example.com def enable_service(service): cmd = ['systemctl', 'enable', '--now', service] util.subp(cmd, capture=True) def handle(name, cfg, cloud, log, args): if len(args) != 0: caasp_cfg = util.read_conf(args[0]) else: if 'suse_caasp' not in cfg: log.debug(("Skipping module named %s, " "no 'suse_caasp' configuration found"), name) return caasp_cfg = cfg['suse_caasp'] if 'role' not in caasp_cfg: log.warn(("Skipping module named %s, " "no 'role' found in 'suse_caasp' configuration"), name) return system_role = caasp_cfg['role'] if system_role == 'admin': log.debug(("role administration node found")) cmd = ['/usr/share/caasp-container-manifests/activate.sh'] util.subp(cmd, capture=True) enable_service('admin-node-setup') enable_service('docker') enable_service('container-feeder') enable_service('etcd') enable_service('kubelet') enable_service('salt-minion') elif system_role == 'cluster': log.debug(("role cluster node found")) if 'admin_node' not in caasp_cfg: log.warn(("Skipping module named %s, " "no 'admin_node' found for cluster system role"), name) return admin_node = caasp_cfg['admin_node'] contents = "master: %s" % (admin_node) util.write_file('/etc/salt/minion.d/master.conf', contents, mode=DEFAULT_PERMS) sed_arg = "s|#NTP=.*|NTP=%s|g" % (admin_node) cmd = ['sed', '-i', '-e', sed_arg, '/etc/systemd/timesyncd.conf'] util.subp(cmd, capture=True) enable_service('docker') enable_service('container-feeder') enable_service('salt-minion') enable_service('systemd-timesyncd') else: log.warn(("Unknown role %s, skipping module named %s"), role, name)
