X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=debian%2Fopenvswitch-controller.postinst;h=3073dc0427e8457e3e8e55cbc904a7cecde478c0;hb=19c8e9c11bcd441a42ababb8439bc7b24e9e435c;hp=51acfb1ab3b3c16d4a4c49fefceab8d2a6041021;hpb=064af42167bf4fc9aaea2702d80ce08074b889c0;p=sliver-openvswitch.git diff --git a/debian/openvswitch-controller.postinst b/debian/openvswitch-controller.postinst index 51acfb1ab..3073dc042 100755 --- a/debian/openvswitch-controller.postinst +++ b/debian/openvswitch-controller.postinst @@ -21,8 +21,16 @@ set -e case "$1" in configure) cd /etc/openvswitch-controller + + # If cacert.pem is a symlink to the old location for cacert.pem, + # remove it so that we can symlink it to the new location. + if test -h cacert.pem && \ + test X"`readlink cacert.pem`" = X/usr/share/openvswitch/pki/switchca/cacert.pem; then + rm -f cacert.pem + fi + if ! test -e cacert.pem; then - ln -s /usr/share/openvswitch/pki/switchca/cacert.pem cacert.pem + ln -s /var/lib/openvswitch/pki/switchca/cacert.pem cacert.pem fi if ! test -e privkey.pem || ! test -e cert.pem; then oldumask=$(umask)