[
https://issues.apache.org/jira/browse/CLOUDSTACK-9462?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15836388#comment-15836388
]
ASF GitHub Bot commented on CLOUDSTACK-9462:
--------------------------------------------
Github user wido commented on a diff in the pull request:
https://github.com/apache/cloudstack/pull/1916#discussion_r97613140
--- Diff: debian/cloudstack-management.postinst ---
@@ -60,7 +60,26 @@ if [ "$1" = configure ]; then
chmod 0640 ${CONFDIR}/${DBPROPS}
chgrp cloud ${CONFDIR}/${DBPROPS}
- invoke-rc.d tomcat6 stop || true
+
+ if [ -d "/usr/share/tomcat7" ]; then
+ rm -f /usr/share/cloudstack-management/bin
+ rm -f /usr/share/cloudstack-management/lib
+ ln -s /usr/share/tomcat7/bin /usr/share/cloudstack-management/bin
+ ln -s /usr/share/tomcat7/lib /usr/share/cloudstack-management/lib
+ invoke-rc.d tomcat7 stop || true
+ if [ ! -f "/etc/cloudstack/management/server.xml" ]; then
+ ln -s /etc/cloudstack/management/server7-nonssl.xml
/etc/cloudstack/management/server.xml
+ fi
+ elif [ -d "/usr/share/tomcat6" ]; then
+ rm -f /usr/share/cloudstack-management/bin
+ rm -f /usr/share/cloudstack-management/lib
+ ln -s /usr/share/tomcat6/bin /usr/share/cloudstack-management/bin
+ ln -s /usr/share/tomcat6/lib /usr/share/cloudstack-management/lib
+ invoke-rc.d tomcat6 stop || true
+ if [ ! -f "/etc/cloudstack/management/server.xml" ]; then
+ ln -s /etc/cloudstack/management/server-nonssl.xml
/etc/cloudstack/management/server.xml
+ fi
+ fi
--- End diff --
Not sure if we this is the best way. Usually creating directories and
moving symlinks is not the way to go in postinst files.
When cleaning packages or upgrading this might break things. Can you think
of a different way?
> Systemd packaging for Ubuntu 16.04
> ----------------------------------
>
> Key: CLOUDSTACK-9462
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-9462
> Project: CloudStack
> Issue Type: Bug
> Security Level: Public(Anyone can view this level - this is the
> default.)
> Reporter: Rohit Yadav
> Assignee: Rohit Yadav
> Fix For: 4.10.0.0, 4.9.1.0
>
>
> Support for building deb packages that will work on Ubuntu 16.04
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)