Merge lp:~flepied/charms/precise/mongodb/trunk into lp:charms/mongodb

Proposed by Frederic Lepied
Status: Merged
Approved by: Clint Byrum
Approved revision: 18
Merged at revision: 18
Proposed branch: lp:~flepied/charms/precise/mongodb/trunk
Merge into: lp:charms/mongodb
Diff against target: 23 lines (+4/-4)
1 file modified
hooks/install (+4/-4)
To merge this branch: bzr merge lp:~flepied/charms/precise/mongodb/trunk
Reviewer Review Type Date Requested Status
Juan L. Negron (community) Approve
Review via email: mp+104058@code.launchpad.net

Description of the change

fix hardcoded DEFAULT_PORT in install hook

To post a comment you must log in.
Revision history for this message
Juan L. Negron (negronjl) wrote :

Thanks for the updates Fred.

Approved.

-Juan

review: Approve
Revision history for this message
Clint Byrum (clint-fewbar) wrote :

Pushed into precise, this should also be pushed to oneiric but this bug is blocking that:

https://bugs.launchpad.net/charms/+bug/991980

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'hooks/install'
2--- hooks/install 2012-01-27 17:32:55 +0000
3+++ hooks/install 2012-04-30 06:10:22 +0000
4@@ -39,7 +39,7 @@
5 # set. In our case, we have defaulted to "myset".
6 ############################################################################################################
7 # Web Admin UI
8-if [ "$WEB_ADMIN_UI" == "True" ]; then
9+if [ "$WEB_ADMIN_UI" == "yes" ]; then
10 sed -i -e "s/ -- / -- --rest /" /etc/init/mongodb.conf
11 fi
12
13@@ -75,7 +75,7 @@
14 ############################################################################################################
15 # Register the port
16 ############################################################################################################
17-[ -x /usr/bin/open-port ] && open-port 27017/TCP
18-if [ "$WEB_ADMIN_UI" == "True" ]; then
19- [ -x /usr/bin/open-port ] && open-port 28017/TCP
20+[ -x /usr/bin/open-port ] && open-port ${DEFAULT_PORT}/TCP
21+if [ "$WEB_ADMIN_UI" == "yes" ]; then
22+ [ -x /usr/bin/open-port ] && open-port $((${DEFAULT_PORT} + 1000))/TCP
23 fi

Subscribers

People subscribed via source and target branches