diff options
author | Ben Howard <ben.howard@ubuntu.com> | 2012-11-14 10:59:37 -0700 |
---|---|---|
committer | usd-importer <ubuntu-server@lists.ubuntu.com> | 2012-11-15 16:03:16 +0000 |
commit | 074820494a3cc1c70be94a549495ca6dfcb843cc (patch) | |
tree | 9eefea25850e2c4797e8f44576cb332033c0f407 /debian/patches/001-strip-init-d.patch | |
parent | 470cd9bfb81f02f79474324818b8020572d17b11 (diff) | |
parent | a1061b7fbd4cf0a999b23622d139fa6f95de7a14 (diff) | |
download | vyos-walinuxagent-074820494a3cc1c70be94a549495ca6dfcb843cc.tar.gz vyos-walinuxagent-074820494a3cc1c70be94a549495ca6dfcb843cc.zip |
Import patches-applied version 1.1-0ubuntu1 to applied/ubuntu/raring-proposed
Imported using git-ubuntu import.
Changelog parent: 470cd9bfb81f02f79474324818b8020572d17b11
Unapplied parent: a1061b7fbd4cf0a999b23622d139fa6f95de7a14
New changelog entries:
* New upstream version (LP: #1078074, #1077147).
* Moved upstart job to be managed by packaging.
Diffstat (limited to 'debian/patches/001-strip-init-d.patch')
-rw-r--r-- | debian/patches/001-strip-init-d.patch | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/debian/patches/001-strip-init-d.patch b/debian/patches/001-strip-init-d.patch new file mode 100644 index 0000000..0d88fe4 --- /dev/null +++ b/debian/patches/001-strip-init-d.patch @@ -0,0 +1,36 @@ +--- a/waagent ++++ b/waagent +@@ -2141,18 +2141,21 @@ def Install(): + os.remove(GetLastPathElement(a)) + shutil.move(a, ".") + Warn("Moved " + a + " -> " + LibDir + "/" + GetLastPathElement(a) ) +- filename = "waagent" +- filepath = "/etc/init.d/" + filename +- distro = IsRedHat() + IsDebian() * 2 + IsSuse() * 3 +- if distro == 0: +- Error("Unable to detect Linux Distribution.") +- return 1 +- init = [[Init_RedHat, "chkconfig --add " + filename], +- [Init_Debian, "update-rc.d " + filename + " defaults"], +- [Init_Suse, "insserv " + filename]][distro - 1] +- SetFileContents(filepath, init[0]) +- os.chmod(filepath, 0755) +- Run(init[1]) ++ ++ if not IsUbuntu(): ++ filename = "waagent" ++ filepath = "/etc/init.d/" + filename ++ distro = IsRedHat() + IsDebian() * 2 + IsSuse() * 3 ++ if distro == 0: ++ Error("Unable to detect Linux Distribution.") ++ return 1 ++ init = [[Init_RedHat, "chkconfig --add " + filename], ++ [Init_Debian, "update-rc.d " + filename + " defaults"], ++ [Init_Suse, "insserv " + filename]][distro - 1] ++ SetFileContents(filepath, init[0]) ++ os.chmod(filepath, 0755) ++ Run(init[1]) ++ + if os.path.isfile("/etc/waagent.conf"): + try: + os.remove("/etc/waagent.conf.old") |