Replace pike symlink
This patch fix upgrade if files/pike is symlink.
Change-Id: Ide6128e106c446b4c57bced07104e4faffb2daee
Related-Prod: PROD-17540
diff --git a/debian/changelog b/debian/changelog
index c450d8e..73a69a8 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+salt-formula-glance (2016.12.1-2xenial1) xenial; urgency=medium
+
+ * Fix files/pike symlink
+
+ -- devops <devops@mirantis.com> Tue, 06 Feb 2018 15:40:55 +0200
+
salt-formula-glance (2016.12.1-1xenial1) xenial; urgency=medium
* Build for Ubuntu xenial
diff --git a/debian/salt-formula-glance.postinst b/debian/salt-formula-glance.postinst
new file mode 100644
index 0000000..eaf2500
--- /dev/null
+++ b/debian/salt-formula-glance.postinst
@@ -0,0 +1,10 @@
+#!/bin/sh
+
+set -e
+
+dpkg-maintscript-helper symlink_to_dir \
+ /usr/share/salt-formulas/env/glance/files/pike /usr/share/salt-formulas/env/glance/files/ocata salt-formula-glance -- "$@"
+
+#DEBHELPER#
+
+exit 0
diff --git a/debian/salt-formula-glance.postrm b/debian/salt-formula-glance.postrm
new file mode 100644
index 0000000..eaf2500
--- /dev/null
+++ b/debian/salt-formula-glance.postrm
@@ -0,0 +1,10 @@
+#!/bin/sh
+
+set -e
+
+dpkg-maintscript-helper symlink_to_dir \
+ /usr/share/salt-formulas/env/glance/files/pike /usr/share/salt-formulas/env/glance/files/ocata salt-formula-glance -- "$@"
+
+#DEBHELPER#
+
+exit 0
diff --git a/debian/salt-formula-glance.preinst b/debian/salt-formula-glance.preinst
new file mode 100644
index 0000000..eaf2500
--- /dev/null
+++ b/debian/salt-formula-glance.preinst
@@ -0,0 +1,10 @@
+#!/bin/sh
+
+set -e
+
+dpkg-maintscript-helper symlink_to_dir \
+ /usr/share/salt-formulas/env/glance/files/pike /usr/share/salt-formulas/env/glance/files/ocata salt-formula-glance -- "$@"
+
+#DEBHELPER#
+
+exit 0