You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by bh...@apache.org on 2017/12/05 12:38:20 UTC

[cloudstack] branch debian9-systemvmtemplate updated (279aded -> 40a4a22)

This is an automated email from the ASF dual-hosted git repository.

bhaisaab pushed a change to branch debian9-systemvmtemplate
in repository https://gitbox.apache.org/repos/asf/cloudstack.git.


 discard 279aded  template build improvements
     new 40a4a22  template build improvements

This update added new revisions after undoing existing revisions.
That is to say, some revisions that were in the old version of the
branch are not in the new version.  This situation occurs
when a user --force pushes a change and generates a repository
containing something like this:

 * -- * -- B -- O -- O -- O   (279aded)
            \
             N -- N -- N   refs/heads/debian9-systemvmtemplate (40a4a22)

You should already have received notification emails for all of the O
revisions, and so the following emails describe only the N revisions
from the common base, B.

Any revisions marked "omit" are not gone; other references still
refer to them.  Any revisions marked "discard" are gone forever.

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 tools/appliance/definitions/systemvmtemplate/preseed.cfg | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

-- 
To stop receiving notification emails like this one, please contact
['"commits@cloudstack.apache.org" <co...@cloudstack.apache.org>'].

[cloudstack] 01/01: template build improvements

Posted by bh...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

bhaisaab pushed a commit to branch debian9-systemvmtemplate
in repository https://gitbox.apache.org/repos/asf/cloudstack.git

commit 40a4a227f5e9d3da8f32168d7065b5788a10889a
Author: Rohit Yadav <ro...@shapeblue.com>
AuthorDate: Tue Dec 5 10:54:29 2017 +0530

    template build improvements
    
    Signed-off-by: Rohit Yadav <ro...@shapeblue.com>
---
 LICENSE                                            |  8 ++--
 pom.xml                                            |  3 +-
 .../{patches => }/debian/etc/apache2/httpd.conf    |  0
 .../debian/etc/apache2/vhost.template              |  0
 systemvm/{patches => }/debian/etc/cloud-nic.rules  |  0
 .../{patches => }/debian/etc/dnsmasq.conf.tmpl     |  0
 .../{patches => }/debian/etc/haproxy/haproxy.cfg   |  0
 systemvm/{patches => }/debian/etc/ipsec.conf       |  0
 .../{patches => }/debian/etc/ipsec.d/l2tp.conf     |  0
 systemvm/{patches => }/debian/etc/ipsec.secrets    |  0
 .../debian/etc/iptables/iptables-consoleproxy      |  0
 .../debian/etc/iptables/iptables-dhcpsrvr          |  0
 .../debian/etc/iptables/iptables-elbvm             |  0
 .../debian/etc/iptables/iptables-ilbvm             |  0
 .../debian/etc/iptables/iptables-router            |  0
 .../debian/etc/iptables/iptables-secstorage        |  0
 .../debian/etc/iptables/iptables-vpcrouter         |  0
 .../debian/etc/iptables/rt_tables_init             |  0
 systemvm/{patches => }/debian/etc/iptables/rules   |  0
 systemvm/{patches => }/debian/etc/issue            |  0
 systemvm/{patches => }/debian/etc/logrotate.conf   |  0
 .../{patches => }/debian/etc/logrotate.d/apache2   |  0
 .../{patches => }/debian/etc/logrotate.d/cloud     |  0
 .../debian/etc/logrotate.d/conntrackd              |  0
 .../{patches => }/debian/etc/logrotate.d/dnsmasq   |  0
 .../{patches => }/debian/etc/logrotate.d/haproxy   |  0
 systemvm/{patches => }/debian/etc/logrotate.d/ppp  |  0
 .../{patches => }/debian/etc/logrotate.d/rsyslog   |  0
 .../debian/etc/modprobe.d/aesni_intel.conf         |  0
 .../debian/etc/modprobe.d/pcspkr.conf              |  0
 .../{patches => }/debian/etc/ppp/options.xl2tpd    |  0
 .../{patches => }/debian/etc/profile.d/cloud.sh    |  0
 systemvm/{patches => }/debian/etc/rc.local         |  0
 systemvm/{patches => }/debian/etc/rsyslog.conf     |  0
 systemvm/{patches => }/debian/etc/ssh/sshd_config  |  1 -
 systemvm/{patches => }/debian/etc/sysctl.conf      |  0
 .../etc/systemd/system/cloud-early-config.service  | 18 ++++++++
 .../systemd/system/cloud-password-server@.service  |  0
 .../etc/systemd/system/cloud-postinit.service      |  0
 .../debian/etc/systemd/system/cloud.service        |  0
 systemvm/{patches => }/debian/etc/vpcdnsmasq.conf  |  0
 .../{patches => }/debian/etc/xl2tpd/xl2tpd.conf    |  0
 .../debian/opt/cloud/bin/baremetal-vr.py           |  0
 .../debian/opt/cloud/bin/baremetal_snat.sh         |  0
 .../debian/opt/cloud/bin/bumpup_priority.sh        |  0
 .../debian/opt/cloud/bin/checkbatchs2svpn.sh       |  0
 .../debian/opt/cloud/bin/checkrouter.sh            |  0
 .../debian/opt/cloud/bin/checks2svpn.sh            |  0
 .../debian/opt/cloud/bin/cloud-nic.sh              |  0
 .../debian/opt/cloud/bin/configure.py              |  0
 .../debian/opt/cloud/bin/cs/CsAddress.py           |  0
 .../{patches => }/debian/opt/cloud/bin/cs/CsApp.py |  0
 .../debian/opt/cloud/bin/cs/CsConfig.py            |  0
 .../debian/opt/cloud/bin/cs/CsDatabag.py           |  0
 .../debian/opt/cloud/bin/cs/CsDhcp.py              |  0
 .../debian/opt/cloud/bin/cs/CsFile.py              |  0
 .../debian/opt/cloud/bin/cs/CsGuestNetwork.py      |  0
 .../debian/opt/cloud/bin/cs/CsHelper.py            |  0
 .../debian/opt/cloud/bin/cs/CsLoadBalancer.py      |  0
 .../debian/opt/cloud/bin/cs/CsMonitor.py           |  0
 .../debian/opt/cloud/bin/cs/CsNetfilter.py         |  0
 .../debian/opt/cloud/bin/cs/CsProcess.py           |  0
 .../debian/opt/cloud/bin/cs/CsRedundant.py         |  0
 .../debian/opt/cloud/bin/cs/CsRoute.py             |  0
 .../debian/opt/cloud/bin/cs/CsRule.py              |  0
 .../debian/opt/cloud/bin/cs/CsStaticRoutes.py      |  0
 .../debian/opt/cloud/bin/cs/__init__.py            |  0
 .../debian/opt/cloud/bin/cs_cmdline.py             |  0
 .../{patches => }/debian/opt/cloud/bin/cs_dhcp.py  |  0
 .../debian/opt/cloud/bin/cs_firewallrules.py       |  0
 .../debian/opt/cloud/bin/cs_forwardingrules.py     |  0
 .../debian/opt/cloud/bin/cs_guestnetwork.py        |  0
 .../{patches => }/debian/opt/cloud/bin/cs_ip.py    |  0
 .../debian/opt/cloud/bin/cs_loadbalancer.py        |  0
 .../debian/opt/cloud/bin/cs_monitorservice.py      |  0
 .../debian/opt/cloud/bin/cs_network_acl.py         |  0
 .../debian/opt/cloud/bin/cs_remoteaccessvpn.py     |  0
 .../debian/opt/cloud/bin/cs_site2sitevpn.py        |  0
 .../debian/opt/cloud/bin/cs_staticroutes.py        |  0
 .../debian/opt/cloud/bin/cs_vmdata.py              |  0
 .../{patches => }/debian/opt/cloud/bin/cs_vmp.py   |  0
 .../debian/opt/cloud/bin/cs_vpnusers.py            |  0
 .../{patches => }/debian/opt/cloud/bin/dnsmasq.sh  |  0
 .../debian/opt/cloud/bin/edithosts.sh              |  0
 .../debian/opt/cloud/bin/getRouterAlerts.sh        |  0
 .../debian/opt/cloud/bin/get_template_version.sh   |  0
 systemvm/{patches => }/debian/opt/cloud/bin/ilb.sh |  0
 .../{patches => }/debian/opt/cloud/bin/ipassoc.sh  |  0
 .../debian/opt/cloud/bin/ipsectunnel.sh            |  0
 .../debian/opt/cloud/bin/line_edit.py              |  0
 .../debian/opt/cloud/bin/loadbalancer.sh           |  0
 .../{patches => }/debian/opt/cloud/bin/master.py   |  0
 .../{patches => }/debian/opt/cloud/bin/merge.py    |  0
 .../debian/opt/cloud/bin/monitor_service.sh        |  0
 .../{patches => }/debian/opt/cloud/bin/netusage.sh |  0
 .../debian/opt/cloud/bin/passwd_server             |  0
 .../debian/opt/cloud/bin/passwd_server_ip          |  0
 .../debian/opt/cloud/bin/passwd_server_ip.py       |  0
 .../debian/opt/cloud/bin/prepare_pxe.sh            |  0
 .../debian/opt/cloud/bin/savepassword.sh           |  0
 .../debian/opt/cloud/bin/set_redundant.py          |  0
 .../opt/cloud/bin/setup}/cloud-early-config        | 48 ++--------------------
 .../debian/opt/cloud/bin/setup/common.sh           |  0
 .../debian/opt/cloud/bin/setup/consoleproxy.sh     |  0
 .../debian/opt/cloud/bin/setup/default.sh          |  0
 .../debian/opt/cloud/bin/setup/dhcpsrvr.sh         |  0
 .../debian/opt/cloud/bin/setup/elbvm.sh            |  0
 .../debian/opt/cloud/bin/setup/ilbvm.sh            |  0
 .../debian/opt/cloud/bin/setup/patchsystemvm.sh    |  0
 .../debian/opt/cloud/bin/setup/postinit.sh         |  0
 .../debian/opt/cloud/bin/setup/router.sh           |  0
 .../debian/opt/cloud/bin/setup/secstorage.sh       |  0
 .../debian/opt/cloud/bin/setup/vpcrouter.sh        |  0
 .../debian/opt/cloud/bin/update_config.py          |  0
 .../{patches => }/debian/opt/cloud/bin/vmdata.py   |  0
 .../{patches => }/debian/opt/cloud/bin/vpc_func.sh |  0
 .../debian/opt/cloud/bin/vpc_netusage.sh           |  0
 .../debian/opt/cloud/bin/vpc_passwd_server         |  0
 .../{patches => }/debian/opt/cloud/bin/vpc_snat.sh |  0
 .../debian/opt/cloud/bin/vpc_staticroute.sh        |  0
 .../{patches => }/debian/opt/cloud/bin/vpn_l2tp.sh |  0
 .../{patches => }/debian/opt/cloud/bin/vr_cfg.sh   |  0
 .../debian/opt/cloud/templates/README              |  0
 .../opt/cloud/templates/arping_gateways.sh.templ   |  0
 .../debian/opt/cloud/templates/check_bumpup.sh     |  0
 .../opt/cloud/templates/check_heartbeat.sh.templ   |  0
 .../opt/cloud/templates/checkrouter.sh.templ       |  0
 .../opt/cloud/templates/conntrackd.conf.templ      |  0
 .../debian/opt/cloud/templates/heartbeat.sh.templ  |  0
 .../opt/cloud/templates/keepalived.conf.templ      |  0
 .../{patches => }/debian/opt/cloud/testdata/README |  0
 .../debian/opt/cloud/testdata/acl0001.json         |  0
 .../debian/opt/cloud/testdata/dhcp0001.json        |  0
 .../debian/opt/cloud/testdata/gn0001.json          |  0
 .../debian/opt/cloud/testdata/ips0001.json         |  0
 .../debian/opt/cloud/testdata/ips0002.json         |  0
 .../debian/opt/cloud/testdata/ips0003.json         |  0
 .../debian/opt/cloud/testdata/s2s0001.json         |  0
 .../debian/opt/cloud/testdata/test.sh              |  0
 .../debian/opt/cloud/testdata/vmp0001.json         |  0
 .../{patches => }/debian/root/.ssh/authorized_keys |  0
 .../{patches => }/debian/root/clearUsageRules.sh   |  0
 systemvm/{patches => }/debian/root/func.sh         |  0
 .../{patches => }/debian/root/monitorServices.py   |  0
 systemvm/{patches => }/debian/root/reconfigLB.sh   |  0
 .../debian/var/www/html/latest/.htaccess           |  0
 .../debian/var/www/html/userdata/.htaccess         |  0
 systemvm/pom.xml                                   |  4 +-
 systemvm/test/runtests.sh                          |  6 +--
 .../definitions/systemvmtemplate/apt_upgrade.sh    | 12 +++++-
 .../definitions/systemvmtemplate/cleanup.sh        | 22 +++++++++-
 .../systemvmtemplate/configure_login.sh            | 34 +--------------
 .../configure_systemvm_services.sh                 |  3 +-
 .../definitions/systemvmtemplate/definition.rb     |  6 +--
 .../systemvmtemplate/{zerodisk.sh => finalize.sh}  | 37 +++++++++++++----
 .../systemvmtemplate/install_systemvm_packages.sh  | 13 +++---
 .../definitions/systemvmtemplate/preseed.cfg       | 11 ++---
 tools/appliance/shar_cloud_scripts.sh              |  4 +-
 tools/whisker/LICENSE                              |  8 ++--
 tools/whisker/descriptor-for-packaging.xml         |  8 ++--
 tools/whisker/descriptor.xml                       |  8 ++--
 utils/src/main/java/com/cloud/utils/nio/Link.java  |  2 +-
 162 files changed, 120 insertions(+), 136 deletions(-)

diff --git a/LICENSE b/LICENSE
index 982b158..c30d859 100644
--- a/LICENSE
+++ b/LICENSE
@@ -208,7 +208,7 @@ Within the console-proxy/js directory
             jquery.js 
 
 
-Within the patches/systemvm/debian/config/etc directory
+Within the systemvm/debian/etc directory
     placed in the public domain
         by Adiscon GmbH  http://www.adiscon.com/ 
             rsyslog.conf 
@@ -216,14 +216,14 @@ Within the patches/systemvm/debian/config/etc directory
             dnsmasq.conf 
             vpcdnsmasq.conf 
 
-Within the patches/systemvm/debian/config/etc/apache2 directory
+Within the systemvm/debian/etc/apache2 directory
     licensed under the Apache License, Version 2 http://www.apache.org/licenses/LICENSE-2.0.txt  (as above)
     Copyright (c) 2012 The Apache Software Foundation
         from The Apache Software Foundation  http://www.apache.org/ 
             httpd.conf 
             vhost.template
 
-Within the patches/systemvm/debian/config/etc/ssh/ directory
+Within the systemvm/debian/etc/ssh/ directory
     licensed under the BSD (2-clause) http://www.opensource.org/licenses/BSD-2-Clause  (as follows)
  
             
@@ -254,7 +254,7 @@ Within the patches/systemvm/debian/config/etc/ssh/ directory
         from OpenSSH Project  http://www.openssh.org/ 
             sshd_config 
 
-Within the patches/systemvm/debian/config/root/redundant_router directory
+Within the systemvm/debian/root/redundant_router directory
     placed in the public domain
         by The netfilter.org project  http://www.netfilter.org/ 
             conntrackd.conf.templ 
diff --git a/pom.xml b/pom.xml
index d4d1a37..57e3adf 100644
--- a/pom.xml
+++ b/pom.xml
@@ -929,8 +929,7 @@
               <exclude>systemvm/agent/conf/environment.properties</exclude>
               <exclude>systemvm/agent/js/jquery.js</exclude>
               <exclude>systemvm/agent/js/jquery.flot.navigate.js</exclude>
-              <exclude>systemvm/patches/debian/**</exclude>
-              <exclude>systemvm/patches/vpn/**</exclude>
+              <exclude>systemvm/debian/**</exclude>
               <exclude>tools/transifex/.tx/config</exclude>
               <exclude>tools/logo/apache_cloudstack.png</exclude>
               <exclude>tools/marvin/marvin/sandbox/advanced/sandbox.cfg</exclude>
diff --git a/systemvm/patches/debian/etc/apache2/httpd.conf b/systemvm/debian/etc/apache2/httpd.conf
similarity index 100%
rename from systemvm/patches/debian/etc/apache2/httpd.conf
rename to systemvm/debian/etc/apache2/httpd.conf
diff --git a/systemvm/patches/debian/etc/apache2/vhost.template b/systemvm/debian/etc/apache2/vhost.template
similarity index 100%
rename from systemvm/patches/debian/etc/apache2/vhost.template
rename to systemvm/debian/etc/apache2/vhost.template
diff --git a/systemvm/patches/debian/etc/cloud-nic.rules b/systemvm/debian/etc/cloud-nic.rules
similarity index 100%
rename from systemvm/patches/debian/etc/cloud-nic.rules
rename to systemvm/debian/etc/cloud-nic.rules
diff --git a/systemvm/patches/debian/etc/dnsmasq.conf.tmpl b/systemvm/debian/etc/dnsmasq.conf.tmpl
similarity index 100%
rename from systemvm/patches/debian/etc/dnsmasq.conf.tmpl
rename to systemvm/debian/etc/dnsmasq.conf.tmpl
diff --git a/systemvm/patches/debian/etc/haproxy/haproxy.cfg b/systemvm/debian/etc/haproxy/haproxy.cfg
similarity index 100%
rename from systemvm/patches/debian/etc/haproxy/haproxy.cfg
rename to systemvm/debian/etc/haproxy/haproxy.cfg
diff --git a/systemvm/patches/debian/etc/ipsec.conf b/systemvm/debian/etc/ipsec.conf
similarity index 100%
rename from systemvm/patches/debian/etc/ipsec.conf
rename to systemvm/debian/etc/ipsec.conf
diff --git a/systemvm/patches/debian/etc/ipsec.d/l2tp.conf b/systemvm/debian/etc/ipsec.d/l2tp.conf
similarity index 100%
rename from systemvm/patches/debian/etc/ipsec.d/l2tp.conf
rename to systemvm/debian/etc/ipsec.d/l2tp.conf
diff --git a/systemvm/patches/debian/etc/ipsec.secrets b/systemvm/debian/etc/ipsec.secrets
similarity index 100%
rename from systemvm/patches/debian/etc/ipsec.secrets
rename to systemvm/debian/etc/ipsec.secrets
diff --git a/systemvm/patches/debian/etc/iptables/iptables-consoleproxy b/systemvm/debian/etc/iptables/iptables-consoleproxy
similarity index 100%
rename from systemvm/patches/debian/etc/iptables/iptables-consoleproxy
rename to systemvm/debian/etc/iptables/iptables-consoleproxy
diff --git a/systemvm/patches/debian/etc/iptables/iptables-dhcpsrvr b/systemvm/debian/etc/iptables/iptables-dhcpsrvr
similarity index 100%
rename from systemvm/patches/debian/etc/iptables/iptables-dhcpsrvr
rename to systemvm/debian/etc/iptables/iptables-dhcpsrvr
diff --git a/systemvm/patches/debian/etc/iptables/iptables-elbvm b/systemvm/debian/etc/iptables/iptables-elbvm
similarity index 100%
rename from systemvm/patches/debian/etc/iptables/iptables-elbvm
rename to systemvm/debian/etc/iptables/iptables-elbvm
diff --git a/systemvm/patches/debian/etc/iptables/iptables-ilbvm b/systemvm/debian/etc/iptables/iptables-ilbvm
similarity index 100%
rename from systemvm/patches/debian/etc/iptables/iptables-ilbvm
rename to systemvm/debian/etc/iptables/iptables-ilbvm
diff --git a/systemvm/patches/debian/etc/iptables/iptables-router b/systemvm/debian/etc/iptables/iptables-router
similarity index 100%
rename from systemvm/patches/debian/etc/iptables/iptables-router
rename to systemvm/debian/etc/iptables/iptables-router
diff --git a/systemvm/patches/debian/etc/iptables/iptables-secstorage b/systemvm/debian/etc/iptables/iptables-secstorage
similarity index 100%
rename from systemvm/patches/debian/etc/iptables/iptables-secstorage
rename to systemvm/debian/etc/iptables/iptables-secstorage
diff --git a/systemvm/patches/debian/etc/iptables/iptables-vpcrouter b/systemvm/debian/etc/iptables/iptables-vpcrouter
similarity index 100%
rename from systemvm/patches/debian/etc/iptables/iptables-vpcrouter
rename to systemvm/debian/etc/iptables/iptables-vpcrouter
diff --git a/systemvm/patches/debian/etc/iptables/rt_tables_init b/systemvm/debian/etc/iptables/rt_tables_init
similarity index 100%
rename from systemvm/patches/debian/etc/iptables/rt_tables_init
rename to systemvm/debian/etc/iptables/rt_tables_init
diff --git a/systemvm/patches/debian/etc/iptables/rules b/systemvm/debian/etc/iptables/rules
similarity index 100%
rename from systemvm/patches/debian/etc/iptables/rules
rename to systemvm/debian/etc/iptables/rules
diff --git a/systemvm/patches/debian/etc/issue b/systemvm/debian/etc/issue
similarity index 100%
rename from systemvm/patches/debian/etc/issue
rename to systemvm/debian/etc/issue
diff --git a/systemvm/patches/debian/etc/logrotate.conf b/systemvm/debian/etc/logrotate.conf
similarity index 100%
rename from systemvm/patches/debian/etc/logrotate.conf
rename to systemvm/debian/etc/logrotate.conf
diff --git a/systemvm/patches/debian/etc/logrotate.d/apache2 b/systemvm/debian/etc/logrotate.d/apache2
similarity index 100%
rename from systemvm/patches/debian/etc/logrotate.d/apache2
rename to systemvm/debian/etc/logrotate.d/apache2
diff --git a/systemvm/patches/debian/etc/logrotate.d/cloud b/systemvm/debian/etc/logrotate.d/cloud
similarity index 100%
rename from systemvm/patches/debian/etc/logrotate.d/cloud
rename to systemvm/debian/etc/logrotate.d/cloud
diff --git a/systemvm/patches/debian/etc/logrotate.d/conntrackd b/systemvm/debian/etc/logrotate.d/conntrackd
similarity index 100%
rename from systemvm/patches/debian/etc/logrotate.d/conntrackd
rename to systemvm/debian/etc/logrotate.d/conntrackd
diff --git a/systemvm/patches/debian/etc/logrotate.d/dnsmasq b/systemvm/debian/etc/logrotate.d/dnsmasq
similarity index 100%
rename from systemvm/patches/debian/etc/logrotate.d/dnsmasq
rename to systemvm/debian/etc/logrotate.d/dnsmasq
diff --git a/systemvm/patches/debian/etc/logrotate.d/haproxy b/systemvm/debian/etc/logrotate.d/haproxy
similarity index 100%
rename from systemvm/patches/debian/etc/logrotate.d/haproxy
rename to systemvm/debian/etc/logrotate.d/haproxy
diff --git a/systemvm/patches/debian/etc/logrotate.d/ppp b/systemvm/debian/etc/logrotate.d/ppp
similarity index 100%
rename from systemvm/patches/debian/etc/logrotate.d/ppp
rename to systemvm/debian/etc/logrotate.d/ppp
diff --git a/systemvm/patches/debian/etc/logrotate.d/rsyslog b/systemvm/debian/etc/logrotate.d/rsyslog
similarity index 100%
rename from systemvm/patches/debian/etc/logrotate.d/rsyslog
rename to systemvm/debian/etc/logrotate.d/rsyslog
diff --git a/systemvm/patches/debian/etc/modprobe.d/aesni_intel.conf b/systemvm/debian/etc/modprobe.d/aesni_intel.conf
similarity index 100%
rename from systemvm/patches/debian/etc/modprobe.d/aesni_intel.conf
rename to systemvm/debian/etc/modprobe.d/aesni_intel.conf
diff --git a/systemvm/patches/debian/etc/modprobe.d/pcspkr.conf b/systemvm/debian/etc/modprobe.d/pcspkr.conf
similarity index 100%
rename from systemvm/patches/debian/etc/modprobe.d/pcspkr.conf
rename to systemvm/debian/etc/modprobe.d/pcspkr.conf
diff --git a/systemvm/patches/debian/etc/ppp/options.xl2tpd b/systemvm/debian/etc/ppp/options.xl2tpd
similarity index 100%
rename from systemvm/patches/debian/etc/ppp/options.xl2tpd
rename to systemvm/debian/etc/ppp/options.xl2tpd
diff --git a/systemvm/patches/debian/etc/profile.d/cloud.sh b/systemvm/debian/etc/profile.d/cloud.sh
similarity index 100%
rename from systemvm/patches/debian/etc/profile.d/cloud.sh
rename to systemvm/debian/etc/profile.d/cloud.sh
diff --git a/systemvm/patches/debian/etc/rc.local b/systemvm/debian/etc/rc.local
similarity index 100%
rename from systemvm/patches/debian/etc/rc.local
rename to systemvm/debian/etc/rc.local
diff --git a/systemvm/patches/debian/etc/rsyslog.conf b/systemvm/debian/etc/rsyslog.conf
similarity index 100%
rename from systemvm/patches/debian/etc/rsyslog.conf
rename to systemvm/debian/etc/rsyslog.conf
diff --git a/systemvm/patches/debian/etc/ssh/sshd_config b/systemvm/debian/etc/ssh/sshd_config
similarity index 99%
rename from systemvm/patches/debian/etc/ssh/sshd_config
rename to systemvm/debian/etc/ssh/sshd_config
index 4931cdb..f277574 100644
--- a/systemvm/patches/debian/etc/ssh/sshd_config
+++ b/systemvm/debian/etc/ssh/sshd_config
@@ -57,7 +57,6 @@ AuthorizedKeysFile .ssh/authorized_keys
 #IgnoreRhosts yes
 
 # To disable tunneled clear text passwords, change to no here!
-#PasswordAuthentication yes
 #PermitEmptyPasswords no
 PasswordAuthentication no
 
diff --git a/systemvm/patches/debian/etc/sysctl.conf b/systemvm/debian/etc/sysctl.conf
similarity index 100%
rename from systemvm/patches/debian/etc/sysctl.conf
rename to systemvm/debian/etc/sysctl.conf
diff --git a/systemvm/debian/etc/systemd/system/cloud-early-config.service b/systemvm/debian/etc/systemd/system/cloud-early-config.service
new file mode 100644
index 0000000..2af5276
--- /dev/null
+++ b/systemvm/debian/etc/systemd/system/cloud-early-config.service
@@ -0,0 +1,18 @@
+[Unit]
+Description=CloudStack post-boot patching service using cmdline
+DefaultDependencies=no
+
+Before=network-pre.target
+Wants=network-pre.target
+
+Requires=local-fs.target
+After=local-fs.target
+
+[Install]
+WantedBy=multi-user.target
+
+[Service]
+Type=oneshot
+ExecStart=/opt/cloud/bin/setup/cloud-early-config
+RemainAfterExit=true
+TimeoutStartSec=5min
diff --git a/systemvm/patches/debian/etc/systemd/system/cloud-password-server@.service b/systemvm/debian/etc/systemd/system/cloud-password-server@.service
similarity index 100%
rename from systemvm/patches/debian/etc/systemd/system/cloud-password-server@.service
rename to systemvm/debian/etc/systemd/system/cloud-password-server@.service
diff --git a/systemvm/patches/debian/etc/systemd/system/cloud-postinit.service b/systemvm/debian/etc/systemd/system/cloud-postinit.service
similarity index 100%
rename from systemvm/patches/debian/etc/systemd/system/cloud-postinit.service
rename to systemvm/debian/etc/systemd/system/cloud-postinit.service
diff --git a/systemvm/patches/debian/etc/systemd/system/cloud.service b/systemvm/debian/etc/systemd/system/cloud.service
similarity index 100%
rename from systemvm/patches/debian/etc/systemd/system/cloud.service
rename to systemvm/debian/etc/systemd/system/cloud.service
diff --git a/systemvm/patches/debian/etc/vpcdnsmasq.conf b/systemvm/debian/etc/vpcdnsmasq.conf
similarity index 100%
rename from systemvm/patches/debian/etc/vpcdnsmasq.conf
rename to systemvm/debian/etc/vpcdnsmasq.conf
diff --git a/systemvm/patches/debian/etc/xl2tpd/xl2tpd.conf b/systemvm/debian/etc/xl2tpd/xl2tpd.conf
similarity index 100%
rename from systemvm/patches/debian/etc/xl2tpd/xl2tpd.conf
rename to systemvm/debian/etc/xl2tpd/xl2tpd.conf
diff --git a/systemvm/patches/debian/opt/cloud/bin/baremetal-vr.py b/systemvm/debian/opt/cloud/bin/baremetal-vr.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/baremetal-vr.py
rename to systemvm/debian/opt/cloud/bin/baremetal-vr.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/baremetal_snat.sh b/systemvm/debian/opt/cloud/bin/baremetal_snat.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/baremetal_snat.sh
rename to systemvm/debian/opt/cloud/bin/baremetal_snat.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/bumpup_priority.sh b/systemvm/debian/opt/cloud/bin/bumpup_priority.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/bumpup_priority.sh
rename to systemvm/debian/opt/cloud/bin/bumpup_priority.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/checkbatchs2svpn.sh b/systemvm/debian/opt/cloud/bin/checkbatchs2svpn.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/checkbatchs2svpn.sh
rename to systemvm/debian/opt/cloud/bin/checkbatchs2svpn.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/checkrouter.sh b/systemvm/debian/opt/cloud/bin/checkrouter.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/checkrouter.sh
rename to systemvm/debian/opt/cloud/bin/checkrouter.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/checks2svpn.sh b/systemvm/debian/opt/cloud/bin/checks2svpn.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/checks2svpn.sh
rename to systemvm/debian/opt/cloud/bin/checks2svpn.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/cloud-nic.sh b/systemvm/debian/opt/cloud/bin/cloud-nic.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cloud-nic.sh
rename to systemvm/debian/opt/cloud/bin/cloud-nic.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/configure.py b/systemvm/debian/opt/cloud/bin/configure.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/configure.py
rename to systemvm/debian/opt/cloud/bin/configure.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs/CsAddress.py b/systemvm/debian/opt/cloud/bin/cs/CsAddress.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs/CsAddress.py
rename to systemvm/debian/opt/cloud/bin/cs/CsAddress.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs/CsApp.py b/systemvm/debian/opt/cloud/bin/cs/CsApp.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs/CsApp.py
rename to systemvm/debian/opt/cloud/bin/cs/CsApp.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs/CsConfig.py b/systemvm/debian/opt/cloud/bin/cs/CsConfig.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs/CsConfig.py
rename to systemvm/debian/opt/cloud/bin/cs/CsConfig.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs/CsDatabag.py b/systemvm/debian/opt/cloud/bin/cs/CsDatabag.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs/CsDatabag.py
rename to systemvm/debian/opt/cloud/bin/cs/CsDatabag.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs/CsDhcp.py b/systemvm/debian/opt/cloud/bin/cs/CsDhcp.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs/CsDhcp.py
rename to systemvm/debian/opt/cloud/bin/cs/CsDhcp.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs/CsFile.py b/systemvm/debian/opt/cloud/bin/cs/CsFile.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs/CsFile.py
rename to systemvm/debian/opt/cloud/bin/cs/CsFile.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs/CsGuestNetwork.py b/systemvm/debian/opt/cloud/bin/cs/CsGuestNetwork.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs/CsGuestNetwork.py
rename to systemvm/debian/opt/cloud/bin/cs/CsGuestNetwork.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs/CsHelper.py b/systemvm/debian/opt/cloud/bin/cs/CsHelper.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs/CsHelper.py
rename to systemvm/debian/opt/cloud/bin/cs/CsHelper.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs/CsLoadBalancer.py b/systemvm/debian/opt/cloud/bin/cs/CsLoadBalancer.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs/CsLoadBalancer.py
rename to systemvm/debian/opt/cloud/bin/cs/CsLoadBalancer.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs/CsMonitor.py b/systemvm/debian/opt/cloud/bin/cs/CsMonitor.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs/CsMonitor.py
rename to systemvm/debian/opt/cloud/bin/cs/CsMonitor.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs/CsNetfilter.py b/systemvm/debian/opt/cloud/bin/cs/CsNetfilter.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs/CsNetfilter.py
rename to systemvm/debian/opt/cloud/bin/cs/CsNetfilter.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs/CsProcess.py b/systemvm/debian/opt/cloud/bin/cs/CsProcess.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs/CsProcess.py
rename to systemvm/debian/opt/cloud/bin/cs/CsProcess.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs/CsRedundant.py b/systemvm/debian/opt/cloud/bin/cs/CsRedundant.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs/CsRedundant.py
rename to systemvm/debian/opt/cloud/bin/cs/CsRedundant.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs/CsRoute.py b/systemvm/debian/opt/cloud/bin/cs/CsRoute.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs/CsRoute.py
rename to systemvm/debian/opt/cloud/bin/cs/CsRoute.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs/CsRule.py b/systemvm/debian/opt/cloud/bin/cs/CsRule.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs/CsRule.py
rename to systemvm/debian/opt/cloud/bin/cs/CsRule.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs/CsStaticRoutes.py b/systemvm/debian/opt/cloud/bin/cs/CsStaticRoutes.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs/CsStaticRoutes.py
rename to systemvm/debian/opt/cloud/bin/cs/CsStaticRoutes.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs/__init__.py b/systemvm/debian/opt/cloud/bin/cs/__init__.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs/__init__.py
rename to systemvm/debian/opt/cloud/bin/cs/__init__.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs_cmdline.py b/systemvm/debian/opt/cloud/bin/cs_cmdline.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs_cmdline.py
rename to systemvm/debian/opt/cloud/bin/cs_cmdline.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs_dhcp.py b/systemvm/debian/opt/cloud/bin/cs_dhcp.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs_dhcp.py
rename to systemvm/debian/opt/cloud/bin/cs_dhcp.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs_firewallrules.py b/systemvm/debian/opt/cloud/bin/cs_firewallrules.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs_firewallrules.py
rename to systemvm/debian/opt/cloud/bin/cs_firewallrules.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs_forwardingrules.py b/systemvm/debian/opt/cloud/bin/cs_forwardingrules.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs_forwardingrules.py
rename to systemvm/debian/opt/cloud/bin/cs_forwardingrules.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs_guestnetwork.py b/systemvm/debian/opt/cloud/bin/cs_guestnetwork.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs_guestnetwork.py
rename to systemvm/debian/opt/cloud/bin/cs_guestnetwork.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs_ip.py b/systemvm/debian/opt/cloud/bin/cs_ip.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs_ip.py
rename to systemvm/debian/opt/cloud/bin/cs_ip.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs_loadbalancer.py b/systemvm/debian/opt/cloud/bin/cs_loadbalancer.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs_loadbalancer.py
rename to systemvm/debian/opt/cloud/bin/cs_loadbalancer.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs_monitorservice.py b/systemvm/debian/opt/cloud/bin/cs_monitorservice.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs_monitorservice.py
rename to systemvm/debian/opt/cloud/bin/cs_monitorservice.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs_network_acl.py b/systemvm/debian/opt/cloud/bin/cs_network_acl.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs_network_acl.py
rename to systemvm/debian/opt/cloud/bin/cs_network_acl.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs_remoteaccessvpn.py b/systemvm/debian/opt/cloud/bin/cs_remoteaccessvpn.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs_remoteaccessvpn.py
rename to systemvm/debian/opt/cloud/bin/cs_remoteaccessvpn.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs_site2sitevpn.py b/systemvm/debian/opt/cloud/bin/cs_site2sitevpn.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs_site2sitevpn.py
rename to systemvm/debian/opt/cloud/bin/cs_site2sitevpn.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs_staticroutes.py b/systemvm/debian/opt/cloud/bin/cs_staticroutes.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs_staticroutes.py
rename to systemvm/debian/opt/cloud/bin/cs_staticroutes.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs_vmdata.py b/systemvm/debian/opt/cloud/bin/cs_vmdata.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs_vmdata.py
rename to systemvm/debian/opt/cloud/bin/cs_vmdata.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs_vmp.py b/systemvm/debian/opt/cloud/bin/cs_vmp.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs_vmp.py
rename to systemvm/debian/opt/cloud/bin/cs_vmp.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/cs_vpnusers.py b/systemvm/debian/opt/cloud/bin/cs_vpnusers.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/cs_vpnusers.py
rename to systemvm/debian/opt/cloud/bin/cs_vpnusers.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/dnsmasq.sh b/systemvm/debian/opt/cloud/bin/dnsmasq.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/dnsmasq.sh
rename to systemvm/debian/opt/cloud/bin/dnsmasq.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/edithosts.sh b/systemvm/debian/opt/cloud/bin/edithosts.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/edithosts.sh
rename to systemvm/debian/opt/cloud/bin/edithosts.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/getRouterAlerts.sh b/systemvm/debian/opt/cloud/bin/getRouterAlerts.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/getRouterAlerts.sh
rename to systemvm/debian/opt/cloud/bin/getRouterAlerts.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/get_template_version.sh b/systemvm/debian/opt/cloud/bin/get_template_version.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/get_template_version.sh
rename to systemvm/debian/opt/cloud/bin/get_template_version.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/ilb.sh b/systemvm/debian/opt/cloud/bin/ilb.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/ilb.sh
rename to systemvm/debian/opt/cloud/bin/ilb.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/ipassoc.sh b/systemvm/debian/opt/cloud/bin/ipassoc.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/ipassoc.sh
rename to systemvm/debian/opt/cloud/bin/ipassoc.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/ipsectunnel.sh b/systemvm/debian/opt/cloud/bin/ipsectunnel.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/ipsectunnel.sh
rename to systemvm/debian/opt/cloud/bin/ipsectunnel.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/line_edit.py b/systemvm/debian/opt/cloud/bin/line_edit.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/line_edit.py
rename to systemvm/debian/opt/cloud/bin/line_edit.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/loadbalancer.sh b/systemvm/debian/opt/cloud/bin/loadbalancer.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/loadbalancer.sh
rename to systemvm/debian/opt/cloud/bin/loadbalancer.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/master.py b/systemvm/debian/opt/cloud/bin/master.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/master.py
rename to systemvm/debian/opt/cloud/bin/master.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/merge.py b/systemvm/debian/opt/cloud/bin/merge.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/merge.py
rename to systemvm/debian/opt/cloud/bin/merge.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/monitor_service.sh b/systemvm/debian/opt/cloud/bin/monitor_service.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/monitor_service.sh
rename to systemvm/debian/opt/cloud/bin/monitor_service.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/netusage.sh b/systemvm/debian/opt/cloud/bin/netusage.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/netusage.sh
rename to systemvm/debian/opt/cloud/bin/netusage.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/passwd_server b/systemvm/debian/opt/cloud/bin/passwd_server
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/passwd_server
rename to systemvm/debian/opt/cloud/bin/passwd_server
diff --git a/systemvm/patches/debian/opt/cloud/bin/passwd_server_ip b/systemvm/debian/opt/cloud/bin/passwd_server_ip
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/passwd_server_ip
rename to systemvm/debian/opt/cloud/bin/passwd_server_ip
diff --git a/systemvm/patches/debian/opt/cloud/bin/passwd_server_ip.py b/systemvm/debian/opt/cloud/bin/passwd_server_ip.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/passwd_server_ip.py
rename to systemvm/debian/opt/cloud/bin/passwd_server_ip.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/prepare_pxe.sh b/systemvm/debian/opt/cloud/bin/prepare_pxe.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/prepare_pxe.sh
rename to systemvm/debian/opt/cloud/bin/prepare_pxe.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/savepassword.sh b/systemvm/debian/opt/cloud/bin/savepassword.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/savepassword.sh
rename to systemvm/debian/opt/cloud/bin/savepassword.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/set_redundant.py b/systemvm/debian/opt/cloud/bin/set_redundant.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/set_redundant.py
rename to systemvm/debian/opt/cloud/bin/set_redundant.py
diff --git a/systemvm/patches/debian/etc/init.d/cloud-early-config b/systemvm/debian/opt/cloud/bin/setup/cloud-early-config
similarity index 87%
rename from systemvm/patches/debian/etc/init.d/cloud-early-config
rename to systemvm/debian/opt/cloud/bin/setup/cloud-early-config
index 139e61b..cec2d3c 100755
--- a/systemvm/patches/debian/etc/init.d/cloud-early-config
+++ b/systemvm/debian/opt/cloud/bin/setup/cloud-early-config
@@ -1,12 +1,4 @@
 #!/bin/bash
-### BEGIN INIT INFO
-# Provides:          cloud-early-config
-# Required-Start:    $local_fs
-# Required-Stop:     $local_fs
-# Default-Start:     S
-# Default-Stop:      0 6
-# Short-Description: configures systemvm using cmdline
-### END INIT INFO
 # Licensed to the Apache Software Foundation (ASF) under one
 # or more contributor license agreements.  See the NOTICE file
 # distributed with this work for additional information
@@ -204,6 +196,8 @@ patch() {
 }
 
 start() {
+  log_it "Executing cloud-early-config"
+
   # Clear /tmp for file lock
   rm -f /tmp/*.lock
   rm -f /tmp/rrouter_bumped
@@ -231,41 +225,7 @@ start() {
 
   log_it "Finished setting up systemvm"
 
-  return 0
+  exit 0
 }
 
-case "$1" in
-  start)
-    log_action_begin_msg "Executing cloud-early-config"
-    log_it "Executing cloud-early-config"
-    if start; then
-        log_action_end_msg $?
-    else
-        log_action_end_msg $?
-    fi
-    ;;
-
-  stop)
-    log_action_begin_msg "Stopping cloud-early-config"
-    #Override old system's interface setting
-    setup_default;
-    log_action_end_msg 0
-    ;;
-
-  force-reload|restart)
-    log_warning_msg "Running $0 is deprecated because it may not enable again some interfaces"
-    log_action_begin_msg "Executing cloud-early-config"
-    if start; then
-        log_action_end_msg $?
-    else
-        log_action_end_msg $?
-    fi
-    ;;
-
-  *)
-    echo "Usage: /etc/init.d/cloud-early-config {start|stop}"
-    exit 1
-    ;;
-esac
-
-exit 0
+start
diff --git a/systemvm/patches/debian/opt/cloud/bin/setup/common.sh b/systemvm/debian/opt/cloud/bin/setup/common.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/setup/common.sh
rename to systemvm/debian/opt/cloud/bin/setup/common.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/setup/consoleproxy.sh b/systemvm/debian/opt/cloud/bin/setup/consoleproxy.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/setup/consoleproxy.sh
rename to systemvm/debian/opt/cloud/bin/setup/consoleproxy.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/setup/default.sh b/systemvm/debian/opt/cloud/bin/setup/default.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/setup/default.sh
rename to systemvm/debian/opt/cloud/bin/setup/default.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/setup/dhcpsrvr.sh b/systemvm/debian/opt/cloud/bin/setup/dhcpsrvr.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/setup/dhcpsrvr.sh
rename to systemvm/debian/opt/cloud/bin/setup/dhcpsrvr.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/setup/elbvm.sh b/systemvm/debian/opt/cloud/bin/setup/elbvm.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/setup/elbvm.sh
rename to systemvm/debian/opt/cloud/bin/setup/elbvm.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/setup/ilbvm.sh b/systemvm/debian/opt/cloud/bin/setup/ilbvm.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/setup/ilbvm.sh
rename to systemvm/debian/opt/cloud/bin/setup/ilbvm.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/setup/patchsystemvm.sh b/systemvm/debian/opt/cloud/bin/setup/patchsystemvm.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/setup/patchsystemvm.sh
rename to systemvm/debian/opt/cloud/bin/setup/patchsystemvm.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/setup/postinit.sh b/systemvm/debian/opt/cloud/bin/setup/postinit.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/setup/postinit.sh
rename to systemvm/debian/opt/cloud/bin/setup/postinit.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/setup/router.sh b/systemvm/debian/opt/cloud/bin/setup/router.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/setup/router.sh
rename to systemvm/debian/opt/cloud/bin/setup/router.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/setup/secstorage.sh b/systemvm/debian/opt/cloud/bin/setup/secstorage.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/setup/secstorage.sh
rename to systemvm/debian/opt/cloud/bin/setup/secstorage.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/setup/vpcrouter.sh b/systemvm/debian/opt/cloud/bin/setup/vpcrouter.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/setup/vpcrouter.sh
rename to systemvm/debian/opt/cloud/bin/setup/vpcrouter.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/update_config.py b/systemvm/debian/opt/cloud/bin/update_config.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/update_config.py
rename to systemvm/debian/opt/cloud/bin/update_config.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/vmdata.py b/systemvm/debian/opt/cloud/bin/vmdata.py
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/vmdata.py
rename to systemvm/debian/opt/cloud/bin/vmdata.py
diff --git a/systemvm/patches/debian/opt/cloud/bin/vpc_func.sh b/systemvm/debian/opt/cloud/bin/vpc_func.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/vpc_func.sh
rename to systemvm/debian/opt/cloud/bin/vpc_func.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/vpc_netusage.sh b/systemvm/debian/opt/cloud/bin/vpc_netusage.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/vpc_netusage.sh
rename to systemvm/debian/opt/cloud/bin/vpc_netusage.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/vpc_passwd_server b/systemvm/debian/opt/cloud/bin/vpc_passwd_server
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/vpc_passwd_server
rename to systemvm/debian/opt/cloud/bin/vpc_passwd_server
diff --git a/systemvm/patches/debian/opt/cloud/bin/vpc_snat.sh b/systemvm/debian/opt/cloud/bin/vpc_snat.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/vpc_snat.sh
rename to systemvm/debian/opt/cloud/bin/vpc_snat.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/vpc_staticroute.sh b/systemvm/debian/opt/cloud/bin/vpc_staticroute.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/vpc_staticroute.sh
rename to systemvm/debian/opt/cloud/bin/vpc_staticroute.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/vpn_l2tp.sh b/systemvm/debian/opt/cloud/bin/vpn_l2tp.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/vpn_l2tp.sh
rename to systemvm/debian/opt/cloud/bin/vpn_l2tp.sh
diff --git a/systemvm/patches/debian/opt/cloud/bin/vr_cfg.sh b/systemvm/debian/opt/cloud/bin/vr_cfg.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/bin/vr_cfg.sh
rename to systemvm/debian/opt/cloud/bin/vr_cfg.sh
diff --git a/systemvm/patches/debian/opt/cloud/templates/README b/systemvm/debian/opt/cloud/templates/README
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/templates/README
rename to systemvm/debian/opt/cloud/templates/README
diff --git a/systemvm/patches/debian/opt/cloud/templates/arping_gateways.sh.templ b/systemvm/debian/opt/cloud/templates/arping_gateways.sh.templ
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/templates/arping_gateways.sh.templ
rename to systemvm/debian/opt/cloud/templates/arping_gateways.sh.templ
diff --git a/systemvm/patches/debian/opt/cloud/templates/check_bumpup.sh b/systemvm/debian/opt/cloud/templates/check_bumpup.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/templates/check_bumpup.sh
rename to systemvm/debian/opt/cloud/templates/check_bumpup.sh
diff --git a/systemvm/patches/debian/opt/cloud/templates/check_heartbeat.sh.templ b/systemvm/debian/opt/cloud/templates/check_heartbeat.sh.templ
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/templates/check_heartbeat.sh.templ
rename to systemvm/debian/opt/cloud/templates/check_heartbeat.sh.templ
diff --git a/systemvm/patches/debian/opt/cloud/templates/checkrouter.sh.templ b/systemvm/debian/opt/cloud/templates/checkrouter.sh.templ
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/templates/checkrouter.sh.templ
rename to systemvm/debian/opt/cloud/templates/checkrouter.sh.templ
diff --git a/systemvm/patches/debian/opt/cloud/templates/conntrackd.conf.templ b/systemvm/debian/opt/cloud/templates/conntrackd.conf.templ
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/templates/conntrackd.conf.templ
rename to systemvm/debian/opt/cloud/templates/conntrackd.conf.templ
diff --git a/systemvm/patches/debian/opt/cloud/templates/heartbeat.sh.templ b/systemvm/debian/opt/cloud/templates/heartbeat.sh.templ
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/templates/heartbeat.sh.templ
rename to systemvm/debian/opt/cloud/templates/heartbeat.sh.templ
diff --git a/systemvm/patches/debian/opt/cloud/templates/keepalived.conf.templ b/systemvm/debian/opt/cloud/templates/keepalived.conf.templ
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/templates/keepalived.conf.templ
rename to systemvm/debian/opt/cloud/templates/keepalived.conf.templ
diff --git a/systemvm/patches/debian/opt/cloud/testdata/README b/systemvm/debian/opt/cloud/testdata/README
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/testdata/README
rename to systemvm/debian/opt/cloud/testdata/README
diff --git a/systemvm/patches/debian/opt/cloud/testdata/acl0001.json b/systemvm/debian/opt/cloud/testdata/acl0001.json
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/testdata/acl0001.json
rename to systemvm/debian/opt/cloud/testdata/acl0001.json
diff --git a/systemvm/patches/debian/opt/cloud/testdata/dhcp0001.json b/systemvm/debian/opt/cloud/testdata/dhcp0001.json
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/testdata/dhcp0001.json
rename to systemvm/debian/opt/cloud/testdata/dhcp0001.json
diff --git a/systemvm/patches/debian/opt/cloud/testdata/gn0001.json b/systemvm/debian/opt/cloud/testdata/gn0001.json
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/testdata/gn0001.json
rename to systemvm/debian/opt/cloud/testdata/gn0001.json
diff --git a/systemvm/patches/debian/opt/cloud/testdata/ips0001.json b/systemvm/debian/opt/cloud/testdata/ips0001.json
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/testdata/ips0001.json
rename to systemvm/debian/opt/cloud/testdata/ips0001.json
diff --git a/systemvm/patches/debian/opt/cloud/testdata/ips0002.json b/systemvm/debian/opt/cloud/testdata/ips0002.json
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/testdata/ips0002.json
rename to systemvm/debian/opt/cloud/testdata/ips0002.json
diff --git a/systemvm/patches/debian/opt/cloud/testdata/ips0003.json b/systemvm/debian/opt/cloud/testdata/ips0003.json
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/testdata/ips0003.json
rename to systemvm/debian/opt/cloud/testdata/ips0003.json
diff --git a/systemvm/patches/debian/opt/cloud/testdata/s2s0001.json b/systemvm/debian/opt/cloud/testdata/s2s0001.json
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/testdata/s2s0001.json
rename to systemvm/debian/opt/cloud/testdata/s2s0001.json
diff --git a/systemvm/patches/debian/opt/cloud/testdata/test.sh b/systemvm/debian/opt/cloud/testdata/test.sh
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/testdata/test.sh
rename to systemvm/debian/opt/cloud/testdata/test.sh
diff --git a/systemvm/patches/debian/opt/cloud/testdata/vmp0001.json b/systemvm/debian/opt/cloud/testdata/vmp0001.json
similarity index 100%
rename from systemvm/patches/debian/opt/cloud/testdata/vmp0001.json
rename to systemvm/debian/opt/cloud/testdata/vmp0001.json
diff --git a/systemvm/patches/debian/root/.ssh/authorized_keys b/systemvm/debian/root/.ssh/authorized_keys
similarity index 100%
rename from systemvm/patches/debian/root/.ssh/authorized_keys
rename to systemvm/debian/root/.ssh/authorized_keys
diff --git a/systemvm/patches/debian/root/clearUsageRules.sh b/systemvm/debian/root/clearUsageRules.sh
similarity index 100%
rename from systemvm/patches/debian/root/clearUsageRules.sh
rename to systemvm/debian/root/clearUsageRules.sh
diff --git a/systemvm/patches/debian/root/func.sh b/systemvm/debian/root/func.sh
similarity index 100%
rename from systemvm/patches/debian/root/func.sh
rename to systemvm/debian/root/func.sh
diff --git a/systemvm/patches/debian/root/monitorServices.py b/systemvm/debian/root/monitorServices.py
similarity index 100%
rename from systemvm/patches/debian/root/monitorServices.py
rename to systemvm/debian/root/monitorServices.py
diff --git a/systemvm/patches/debian/root/reconfigLB.sh b/systemvm/debian/root/reconfigLB.sh
similarity index 100%
rename from systemvm/patches/debian/root/reconfigLB.sh
rename to systemvm/debian/root/reconfigLB.sh
diff --git a/systemvm/patches/debian/var/www/html/latest/.htaccess b/systemvm/debian/var/www/html/latest/.htaccess
similarity index 100%
rename from systemvm/patches/debian/var/www/html/latest/.htaccess
rename to systemvm/debian/var/www/html/latest/.htaccess
diff --git a/systemvm/patches/debian/var/www/html/userdata/.htaccess b/systemvm/debian/var/www/html/userdata/.htaccess
similarity index 100%
rename from systemvm/patches/debian/var/www/html/userdata/.htaccess
rename to systemvm/debian/var/www/html/userdata/.htaccess
diff --git a/systemvm/pom.xml b/systemvm/pom.xml
index c22f71c..e5d2523 100644
--- a/systemvm/pom.xml
+++ b/systemvm/pom.xml
@@ -88,7 +88,7 @@
                   </includes>
                 </resource>
                 <resource>
-                  <directory>patches/debian/root/.ssh</directory>
+                  <directory>debian/root/.ssh</directory>
                   <includes>
                     <include>authorized_keys</include>
                   </includes>
@@ -112,7 +112,7 @@
                 <mkdir dir="${basedir}/dist" />
                 <mkdir dir="${basedir}/target/build-patch" />
                 <copy overwrite="true" todir="${basedir}/target/build-patch">
-                  <fileset dir="${basedir}/patches/debian/">
+                  <fileset dir="${basedir}/debian/">
                     <include name="**/*" />
                   </fileset>
                 </copy>
diff --git a/systemvm/test/runtests.sh b/systemvm/test/runtests.sh
index 3b62eee..04290e7 100644
--- a/systemvm/test/runtests.sh
+++ b/systemvm/test/runtests.sh
@@ -18,12 +18,12 @@
 
 # requires netaddr
 
-export PYTHONPATH="../patches/debian/opt/cloud/bin/"
+export PYTHONPATH="../debian/opt/cloud/bin/"
 export PYTHONDONTWRITEBYTECODE=False
 
 echo "Running pep8 to check systemvm/python code for errors"
 pep8 --max-line-length=179 *py
-pep8 --max-line-length=179 --exclude=monitorServices.py,baremetal-vr.py,passwd_server_ip.py `find ../patches -name \*.py`
+pep8 --max-line-length=179 --exclude=monitorServices.py,baremetal-vr.py,passwd_server_ip.py `find ../debian -name \*.py`
 if [ $? -gt 0 ]
 then
     echo "Pylint failed, please check your code"
@@ -32,7 +32,7 @@ fi
 
 echo "Running pylint to check systemvm/python code for errors"
 pylint --disable=R,C,W *.py
-pylint --disable=R,C,W `find ../patches -name \*.py`
+pylint --disable=R,C,W `find ../debian -name \*.py`
 if [ $? -gt 0 ]
 then
     echo "Pylint failed, please check your code"
diff --git a/tools/appliance/definitions/systemvmtemplate/apt_upgrade.sh b/tools/appliance/definitions/systemvmtemplate/apt_upgrade.sh
index eb9b790..6f37e34 100644
--- a/tools/appliance/definitions/systemvmtemplate/apt_upgrade.sh
+++ b/tools/appliance/definitions/systemvmtemplate/apt_upgrade.sh
@@ -19,6 +19,15 @@
 set -e
 set -x
 
+function remove_reserved_blocks() {
+  for partition in $(blkid -o list | grep ext | awk '{print $1}')
+  do
+    tune2fs -m0 $partition
+  done
+  fdisk -l
+  df -h
+}
+
 function add_backports() {
   sed -i '/cdrom/d' /etc/apt/sources.list
   sed -i '/deb-src/d' /etc/apt/sources.list
@@ -33,6 +42,7 @@ function apt_upgrade() {
   # Setup sudo
   echo 'cloud ALL=(ALL) NOPASSWD: ALL' > /etc/sudoers.d/cloud
 
+  remove_reserved_blocks
   add_backports
 
   rm -fv /root/*.iso
@@ -40,8 +50,6 @@ function apt_upgrade() {
   apt-get autoclean
   apt-get -q -y update
   apt-get -q -y upgrade
-
-  df -h
 }
 
 return 2>/dev/null || apt_upgrade
diff --git a/tools/appliance/definitions/systemvmtemplate/cleanup.sh b/tools/appliance/definitions/systemvmtemplate/cleanup.sh
index 444cc94..00f068d 100644
--- a/tools/appliance/definitions/systemvmtemplate/cleanup.sh
+++ b/tools/appliance/definitions/systemvmtemplate/cleanup.sh
@@ -20,8 +20,11 @@ set -e
 set -x
 
 function cleanup_apt() {
-  apt-get -y remove dictionaries-common busybox isc-dhcp-client isc-dhcp-common
-  apt-get -y autoremove
+  apt-get -y remove --purge dictionaries-common busybox isc-dhcp-client isc-dhcp-common \
+    task-english task-ssh-server tasksel tasksel-data laptop-detect nano wamerican \
+    debconf-i18n sharutils gnupg gnupg-agent keyboard-configuration
+
+  apt-get -y autoremove --purge
   apt-get autoclean
   apt-get clean
 }
@@ -40,13 +43,28 @@ function cleanup_dev() {
 }
 
 function cleanup_misc() {
+  # Scripts
   rm -fr /home/cloud/cloud_scripts*
+  rm -f /usr/share/cloud/cloud-scripts.tar
   rm -f /root/.rnd
   rm -f /var/www/html/index.html
+  # Logs
   rm -f /var/log/*.log
   rm -f /var/log/apache2/*
   rm -f /var/log/messages
   rm -f /var/log/syslog
+  rm -f /var/log/messages
+  rm -fr /var/log/apt
+  rm -fr /var/log/installer
+  # Docs and data files
+  rm -fr /var/lib/apt/*
+  rm -fr /var/cache/apt/*
+  rm -fr /usr/lib/gnupg*
+  rm -fr /usr/share/doc
+  rm -fr /usr/share/man
+  rm -fr /usr/share/info
+  rm -fr /usr/share/lintian
+  find /usr/share/locale -type f | grep -v en | xargs rm -fr
 }
 
 function cleanup() {
diff --git a/tools/appliance/definitions/systemvmtemplate/configure_login.sh b/tools/appliance/definitions/systemvmtemplate/configure_login.sh
index d5f80b1..1d9de06 100644
--- a/tools/appliance/definitions/systemvmtemplate/configure_login.sh
+++ b/tools/appliance/definitions/systemvmtemplate/configure_login.sh
@@ -27,54 +27,22 @@ function configure_user() {
   usermod -a -G admin cloud
   mkdir -p /home/cloud/.ssh
   chmod 700 /home/cloud/.ssh
-  echo "cloud:`openssl rand -base64 32`" | chpasswd
   echo "root:password" | chpasswd
 }
 
-function configure_sudoers() {
-  cat >/etc/sudoers <<END
-Defaults	env_reset
-Defaults	exempt_group=admin
-Defaults	mail_badpass
-Defaults	secure_path="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
-
-root	  ALL=(ALL:ALL) ALL
-%admin	ALL=NOPASSWD:/bin/chmod, /bin/cp, /bin/mkdir, /bin/mount, /bin/umount
-
-#includedir /etc/sudoers.d
-END
-  echo 'cloud ALL=NOPASSWD:/bin/chmod, /bin/cp, /bin/mkdir, /bin/mount, /bin/umount, /sbin/halt' > /etc/sudoers.d/cloud
-}
-
-# sshd_config is overwritten from cloud_scripts
-#function configure_sshd() {
-#  grep "UseDNS no" /etc/ssh/sshd_config && \
-#      grep "PasswordAuthentication no" /etc/ssh/sshd_config && \
-#      return
-#  # Tweak sshd to prevent DNS resolution (speed up logins)
-#  echo 'UseDNS no' >> /etc/ssh/sshd_config
-#
-#  # Require ssh keys for login
-#  sed -i -e 's/^.*PasswordAuthentication .*$/PasswordAuthentication no/g' /etc/ssh/sshd_config
-#}
-
 function configure_inittab() {
   # Fix inittab
   cat >> /etc/inittab << EOF
 
+0:2345:respawn:/sbin/getty -L 115200 ttyS0 vt102
 vc:2345:respawn:/sbin/getty 38400 hvc0
 EOF
 }
 
 function configure_login() {
-  # configure_sshd
   configure_inittab
   add_admin_group
-  configure_sudoers
   configure_user
-  rm -fv /home/cloud/configure_login.sh
-  sync
-  halt -p
 }
 
 return 2>/dev/null || configure_login
diff --git a/tools/appliance/definitions/systemvmtemplate/configure_systemvm_services.sh b/tools/appliance/definitions/systemvmtemplate/configure_systemvm_services.sh
index 4789e65..84cb590 100644
--- a/tools/appliance/definitions/systemvmtemplate/configure_systemvm_services.sh
+++ b/tools/appliance/definitions/systemvmtemplate/configure_systemvm_services.sh
@@ -34,9 +34,8 @@ function configure_apache2() {
 function install_cloud_scripts() {
   # ./cloud_scripts/ has been put there by ../../cloud_scripts_shar_archive.sh
   rsync -av ./cloud_scripts/ /
-  chmod +x /opt/cloud/bin/* \
+  chmod +x /opt/cloud/bin/* /opt/cloud/bin/setup/* \
     /root/{clearUsageRules.sh,reconfigLB.sh,monitorServices.py} \
-    /etc/init.d/cloud-early-config \
     /etc/profile.d/cloud.sh
 
   chmod -x /etc/systemd/system/*
diff --git a/tools/appliance/definitions/systemvmtemplate/definition.rb b/tools/appliance/definitions/systemvmtemplate/definition.rb
index 33c8e8b..03be568 100644
--- a/tools/appliance/definitions/systemvmtemplate/definition.rb
+++ b/tools/appliance/definitions/systemvmtemplate/definition.rb
@@ -81,11 +81,11 @@ config = {
         'configure_systemvm_services.sh',
         'authorized_keys.sh',
         'configure_persistent_config.sh',
+        # setup login stuff
+        'configure_login.sh',
         # cleanup & space-saving
         'cleanup.sh',
-        'zerodisk.sh',
-        # setup login stuff
-        'configure_login.sh'
+        'finalize.sh'
     ],
     :postinstall_timeout => '10000'
 }
diff --git a/tools/appliance/definitions/systemvmtemplate/zerodisk.sh b/tools/appliance/definitions/systemvmtemplate/finalize.sh
similarity index 68%
rename from tools/appliance/definitions/systemvmtemplate/zerodisk.sh
rename to tools/appliance/definitions/systemvmtemplate/finalize.sh
index d002316..1a25e39 100644
--- a/tools/appliance/definitions/systemvmtemplate/zerodisk.sh
+++ b/tools/appliance/definitions/systemvmtemplate/finalize.sh
@@ -19,6 +19,26 @@
 set -e
 set -x
 
+function configure_misc() {
+  rm -fv /home/cloud/*.sh
+  echo "cloud:`openssl rand -base64 32`" | chpasswd
+}
+
+function configure_sudoers() {
+  cat >/etc/sudoers <<END
+Defaults	env_reset
+Defaults	exempt_group=admin
+Defaults	mail_badpass
+Defaults	secure_path="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
+
+root	  ALL=(ALL:ALL) ALL
+%admin	ALL=NOPASSWD:/bin/chmod, /bin/cp, /bin/mkdir, /bin/mount, /bin/umount
+
+#includedir /etc/sudoers.d
+END
+  echo 'cloud ALL=NOPASSWD:/bin/chmod, /bin/cp, /bin/mkdir, /bin/mount, /bin/umount, /sbin/halt' > /etc/sudoers.d/cloud
+}
+
 # clean up stuff copied in by veewee
 function cleanup_veewee() {
   # this has to be here since it is the last file to run (and we remove ourselves)
@@ -31,19 +51,22 @@ function cleanup_veewee() {
 
 # Zero out the free space to save space in the final image:
 function zero_disk() {
-  cleanup_veewee
-
   for path in / /boot /var/log /tmp
   do
     dd if=/dev/zero of=${path}/zero bs=1M || true
     sync
     rm -f ${path}/zero
   done
+  df -h
+}
 
-  for partition in $(blkid -o list | grep ext | awk '{print $1}')
-  do
-    tune2fs -m0 $partition
-  done
+function finalize() {
+  configure_misc
+  configure_sudoers
+  cleanup_veewee
+  sync
+  zero_disk
+  halt -p
 }
 
-return 2>/dev/null || zero_disk
+return 2>/dev/null || finalize
diff --git a/tools/appliance/definitions/systemvmtemplate/install_systemvm_packages.sh b/tools/appliance/definitions/systemvmtemplate/install_systemvm_packages.sh
index 2cceb98..40ff6df 100644
--- a/tools/appliance/definitions/systemvmtemplate/install_systemvm_packages.sh
+++ b/tools/appliance/definitions/systemvmtemplate/install_systemvm_packages.sh
@@ -53,7 +53,7 @@ function install_packages() {
   fi
 
   ${apt_get} install grub-legacy \
-    rsyslog logrotate cron net-tools ifupdown vim tmux netbase iptables \
+    rsyslog logrotate cron net-tools ifupdown vim netbase iptables \
     openssh-server e2fsprogs tcpdump socat wget \
     python bzip2 sed gawk diffutils grep gzip less tar telnet ftp rsync traceroute psmisc lsof procps \
     inetutils-ping iputils-arping httping  curl \
@@ -67,7 +67,6 @@ function install_packages() {
     xenstore-utils libxenstore3.0 \
     ipvsadm conntrackd libnetfilter-conntrack3 \
     keepalived irqbalance \
-    libnl-3-200 libnl-genl-3-200 \
     ipcalc \
     openjdk-8-jre-headless \
     ipset \
@@ -80,16 +79,14 @@ function install_packages() {
     strongswan libcharon-extra-plugins libstrongswan-extra-plugins \
     virt-what open-vm-tools qemu-guest-agent hyperv-daemons
 
+  apt-get -y autoremove --purge
+  apt-get autoclean
+  apt-get clean
+
   # Install xenserver guest utilities as debian repos don't have it
   wget https://mirrors.kernel.org/ubuntu/pool/universe/x/xe-guest-utilities/xe-guest-utilities_7.4.0-0ubuntu1_amd64.deb
   dpkg -i xe-guest-utilities_7.4.0-0ubuntu1_amd64.deb
   rm -f xe-guest-utilities_7.4.0-0ubuntu1_amd64.deb
-
-  apt-get autoclean
-  apt-get clean
-
-  apt-get update
-  apt-get -y upgrade
 }
 
 return 2>/dev/null || install_packages
diff --git a/tools/appliance/definitions/systemvmtemplate/preseed.cfg b/tools/appliance/definitions/systemvmtemplate/preseed.cfg
index 99bd6eb..5a8e2d9 100644
--- a/tools/appliance/definitions/systemvmtemplate/preseed.cfg
+++ b/tools/appliance/definitions/systemvmtemplate/preseed.cfg
@@ -57,7 +57,7 @@ d-i partman-auto/method string regular
 d-i partman-auto/choose_recipe select atomic
 d-i partman-auto/expert_recipe string                         \
       boot-root ::                                            \
-              80 50 100 ext2                                  \
+              50 50 50 ext2                                   \
                       $primary{ } $bootable{ }                \
                       method{ format } format{ }              \
                       use_filesystem{ } filesystem{ ext2 }    \
@@ -68,17 +68,12 @@ d-i partman-auto/expert_recipe string                         \
                       use_filesystem{ } filesystem{ ext4 }    \
                       mountpoint{ / }                         \
               .                                               \
-              300 50 300 ext4                                 \
+              350 50 400 ext4                                 \
                       method{ format } format{ }              \
                       use_filesystem{ } filesystem{ ext4 }    \
                       mountpoint{ /var/log }                  \
               .                                               \
-              100 90 100 ext4                                 \
-                      method{ format } format{ }              \
-                      use_filesystem{ } filesystem{ ext4 }    \
-                      mountpoint{ /tmp }                      \
-              .                                               \
-              100 100 200 linux-swap                          \
+              100 100 100 linux-swap                          \
                       method{ swap } format{ }                \
               .
 
diff --git a/tools/appliance/shar_cloud_scripts.sh b/tools/appliance/shar_cloud_scripts.sh
index d67f889..30ae2cb 100755
--- a/tools/appliance/shar_cloud_scripts.sh
+++ b/tools/appliance/shar_cloud_scripts.sh
@@ -37,10 +37,10 @@ TEMP_DIR=`mktemp -d ${TMPDIR}/shar_cloud.XXXXXXXX`
 cd ${TEMP_DIR}
 mkdir cloud_scripts
 mkdir -p cloud_scripts/opt/cloudstack
-cp -r ${CLOUDSTACK_DIR}/systemvm/patches/debian/* cloud_scripts/
+cp -r ${CLOUDSTACK_DIR}/systemvm/debian/* cloud_scripts/
 
 mkdir -p cloud_scripts/usr/share/cloud
-cd ${CLOUDSTACK_DIR}/systemvm/patches/debian
+cd ${CLOUDSTACK_DIR}/systemvm/debian
 tar -cf ${TEMP_DIR}/cloud_scripts/usr/share/cloud/cloud-scripts.tar *
 
 cd ${TEMP_DIR}
diff --git a/tools/whisker/LICENSE b/tools/whisker/LICENSE
index d14a974..e107c4f 100644
--- a/tools/whisker/LICENSE
+++ b/tools/whisker/LICENSE
@@ -2758,7 +2758,7 @@ Within the deps/awsapi-lib directory
         from VMware, Inc  http://www.vmware.com/ 
             rabbitmq-client.jar  from http://www.rabbitmq.com/java-client.html
 
-Within the patches/systemvm/debian/config/etc directory
+Within the systemvm/debian/etc directory
     placed in the public domain
         by Adiscon GmbH  http://www.adiscon.com/ 
             rsyslog.conf 
@@ -2766,14 +2766,14 @@ Within the patches/systemvm/debian/config/etc directory
             dnsmasq.conf 
             vpcdnsmasq.conf 
 
-Within the patches/systemvm/debian/config/etc/apache2 directory
+Within the systemvm/debian/config/etc/apache2 directory
     licensed under the Apache License, Version 2 http://www.apache.org/licenses/LICENSE-2.0.txt  (as above)
     Copyright (c) 2012 The Apache Software Foundation
         from The Apache Software Foundation  http://www.apache.org/ 
             httpd.conf 
             vhost.template
 
-Within the patches/systemvm/debian/config/etc/ssh/ directory
+Within the systemvm/debian/etc/ssh/ directory
     licensed under the BSD (2-clause) http://www.opensource.org/licenses/BSD-2-Clause  (as follows)
  
             
@@ -2804,7 +2804,7 @@ Within the patches/systemvm/debian/config/etc/ssh/ directory
         from OpenSSH Project  http://www.openssh.org/ 
             sshd_config 
 
-Within the patches/systemvm/debian/config/root/redundant_router directory
+Within the systemvm/debian/root/redundant_router directory
     placed in the public domain
         by The netfilter.org project  http://www.netfilter.org/ 
             conntrackd.conf.templ 
diff --git a/tools/whisker/descriptor-for-packaging.xml b/tools/whisker/descriptor-for-packaging.xml
index 579e9d7..2d2e719 100644
--- a/tools/whisker/descriptor-for-packaging.xml
+++ b/tools/whisker/descriptor-for-packaging.xml
@@ -2452,7 +2452,7 @@ This product includes software developed at
 The Apache Software Foundation (http://www.apache.org/).
     </primary-notice>
     <primary-organisation id='apache.org'/> 
-    <within dir='patches/systemvm/debian/config/etc/apache2'>
+    <within dir='systemvm/debian/etc/apache2'>
         <with-license id='ApacheLicenseVersion2'>
             <copyright-notice>
 Copyright (c) 2012 The Apache Software Foundation
@@ -2463,7 +2463,7 @@ Copyright (c) 2012 The Apache Software Foundation
             </by-organisation>
         </with-license>
     </within>
-    <within dir='patches/systemvm/debian/config/etc'>
+    <within dir='systemvm/debian/etc'>
         <public-domain>
             <by-organisation id='adiscon.com'>
                 <resource name='rsyslog.conf' />
@@ -2474,14 +2474,14 @@ Copyright (c) 2012 The Apache Software Foundation
             </by-organisation>
         </public-domain>
     </within>
-    <within dir='patches/systemvm/debian/config/root/redundant_router'>
+    <within dir='systemvm/debian/root/redundant_router'>
         <public-domain>
             <by-organisation id='netfilter.org'>
                 <resource name='conntrackd.conf.templ' />
             </by-organisation>
         </public-domain>
     </within>
-    <within dir='patches/systemvm/debian/config/etc/ssh/'>
+    <within dir='systemvm/debian/etc/ssh/'>
         <with-license id='BSD2ClauseGeneric'>
             <copyright-notice />
             <by-organisation id='openssh.org'>
diff --git a/tools/whisker/descriptor.xml b/tools/whisker/descriptor.xml
index 0b6ded5..fdd8da2 100644
--- a/tools/whisker/descriptor.xml
+++ b/tools/whisker/descriptor.xml
@@ -2436,7 +2436,7 @@ This product includes software developed at
 The Apache Software Foundation (http://www.apache.org/).
     </primary-notice>
     <primary-organisation id='apache.org'/> 
-    <within dir='patches/systemvm/debian/config/etc/apache2'>
+    <within dir='systemvm/debian/etc/apache2'>
         <with-license id='ApacheLicenseVersion2'>
             <copyright-notice>
 Copyright (c) 2012 The Apache Software Foundation
@@ -2447,7 +2447,7 @@ Copyright (c) 2012 The Apache Software Foundation
             </by-organisation>
         </with-license>
     </within>
-    <within dir='patches/systemvm/debian/config/etc'>
+    <within dir='systemvm/debian/etc'>
         <public-domain>
             <by-organisation id='adiscon.com'>
                 <resource name='rsyslog.conf' />
@@ -2458,14 +2458,14 @@ Copyright (c) 2012 The Apache Software Foundation
             </by-organisation>
         </public-domain>
     </within>
-    <within dir='patches/systemvm/debian/config/root/redundant_router'>
+    <within dir='systemvm/debian/root/redundant_router'>
         <public-domain>
             <by-organisation id='netfilter.org'>
                 <resource name='conntrackd.conf.templ' />
             </by-organisation>
         </public-domain>
     </within>
-    <within dir='patches/systemvm/debian/config/etc/ssh/'>
+    <within dir='systemvm/debian/etc/ssh/'>
         <with-license id='BSD2ClauseGeneric'>
             <copyright-notice />
             <by-organisation id='openssh.org'>
diff --git a/utils/src/main/java/com/cloud/utils/nio/Link.java b/utils/src/main/java/com/cloud/utils/nio/Link.java
index 35211c8..25f6662 100644
--- a/utils/src/main/java/com/cloud/utils/nio/Link.java
+++ b/utils/src/main/java/com/cloud/utils/nio/Link.java
@@ -505,7 +505,7 @@ public class Link {
             s_logger.error(String.format("SSL error caught during unwrap data: %s, for local address=%s, remote address=%s. The client may have invalid ca-certificates.",
                     sslException.getMessage(), socketChannel.getLocalAddress(), socketChannel.getRemoteAddress()));
             sslEngine.closeOutbound();
-            return new HandshakeHolder(peerAppData, peerNetData, true);
+            return new HandshakeHolder(peerAppData, peerNetData, false);
         }
         if (result == null) {
             return new HandshakeHolder(peerAppData, peerNetData, false);

-- 
To stop receiving notification emails like this one, please contact
"commits@cloudstack.apache.org" <co...@cloudstack.apache.org>.