summaryrefslogtreecommitdiff
path: root/debian/patches/000_no_udev_rule_removal.patch
diff options
context:
space:
mode:
authorBen Howard <ben.howard@ubuntu.com>2013-06-11 14:09:58 -0600
committerusd-importer <ubuntu-server@lists.ubuntu.com>2013-07-02 14:33:26 +0000
commitec11b39b409497fbe12c51d89938f8e928a4becc (patch)
treeb75bc5b887bb445681678c8e6ee2e28273423091 /debian/patches/000_no_udev_rule_removal.patch
parent16e235429a403078c00c17d79018431d259633b0 (diff)
parentd01d989b1f959655bc5bb6eb443835e10d6decd6 (diff)
downloadvyos-walinuxagent-ec11b39b409497fbe12c51d89938f8e928a4becc.tar.gz
vyos-walinuxagent-ec11b39b409497fbe12c51d89938f8e928a4becc.zip
Import patches-applied version 1.3.2-0ubuntu2 to applied/ubuntu/saucy-proposed
Imported using git-ubuntu import. Changelog parent: 16e235429a403078c00c17d79018431d259633b0 Unapplied parent: d01d989b1f959655bc5bb6eb443835e10d6decd6 New changelog entries: * Added logic to prevent udev rules.d movement (LP: #1188753)
Diffstat (limited to 'debian/patches/000_no_udev_rule_removal.patch')
-rw-r--r--debian/patches/000_no_udev_rule_removal.patch42
1 files changed, 42 insertions, 0 deletions
diff --git a/debian/patches/000_no_udev_rule_removal.patch b/debian/patches/000_no_udev_rule_removal.patch
new file mode 100644
index 0000000..40a10d0
--- /dev/null
+++ b/debian/patches/000_no_udev_rule_removal.patch
@@ -0,0 +1,42 @@
+--- a/waagent
++++ b/waagent
+@@ -701,12 +701,13 @@ class EnvMonitor(object):
+ dhcpcmd = "pidof dhclient3"
+ dhcppid = RunGetOutput(dhcpcmd,chk_err=False)[1]
+ while not self.shutdown:
+- for a in RulesFiles:
+- if os.path.isfile(a):
+- if os.path.isfile(GetLastPathElement(a)):
+- os.remove(GetLastPathElement(a))
+- shutil.move(a, ".")
+- Log("EnvMonitor: Moved " + a + " -> " + LibDir)
++ if not IsDebian():
++ for a in RulesFiles:
++ if os.path.isfile(a):
++ if os.path.isfile(GetLastPathElement(a)):
++ os.remove(GetLastPathElement(a))
++ shutil.move(a, ".")
++ Log("EnvMonitor: Moved " + a + " -> " + LibDir)
+ if publish != None and publish.lower().startswith("y"):
+ try:
+ if socket.gethostname() != self.HostName:
+@@ -2318,12 +2319,13 @@ def Install():
+ if UsesDpkg() and not Run("dpkg-query -s network-manager >/dev/null 2>&1",chk_err=False): # We want this to fail - supress error logging on error.
+ Error(GuestAgentLongName + " is not compatible with network-manager.")
+ return 1
+- for a in RulesFiles:
+- if os.path.isfile(a):
+- if os.path.isfile(GetLastPathElement(a)):
+- os.remove(GetLastPathElement(a))
+- shutil.move(a, ".")
+- Warn("Moved " + a + " -> " + LibDir + "/" + GetLastPathElement(a) )
++ if not IsDebian():
++ for a in RulesFiles:
++ if os.path.isfile(a):
++ if os.path.isfile(GetLastPathElement(a)):
++ os.remove(GetLastPathElement(a))
++ shutil.move(a, ".")
++ Warn("Moved " + a + " -> " + LibDir + "/" + GetLastPathElement(a) )
+
+ if IsUbuntu() and not IsPackagedUbuntu():
+ # Support for Ubuntu's upstart configuration