Merge lp:~moon127/charms/precise/daisy/schema-connect-cassandra into lp:~daisy-pluckers/charms/precise/daisy/trunk

Proposed by Gareth Woolridge on 2016-08-01
Status: Merged
Merged at revision: 83
Proposed branch: lp:~moon127/charms/precise/daisy/schema-connect-cassandra
Merge into: lp:~daisy-pluckers/charms/precise/daisy/trunk
Diff against target: 12 lines (+1/-1)
1 file modified
hooks/config-changed (+1/-1)
To merge this branch: bzr merge lp:~moon127/charms/precise/daisy/schema-connect-cassandra
Reviewer Review Type Date Requested Status
Daisy Pluckers 2016-08-01 Pending
Review via email:

Description of the change

The call to oops-respository's fails unless we also pass the cassandra username and password.

This fix allowed me to rerun a failing upgrade-charm hook and get a fresh DSE casssandra env for staging redeploy to initialise.

Note the daisy charm leaks credentials quite extensively - while this change makes that no worse - it would be a good practise to work to eradicate secrets from the juju logs.

To post a comment you must log in.
Brian Murray (brian-murray) wrote :

This looks good, thanks!

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'hooks/config-changed'
2--- hooks/config-changed 2016-07-29 18:07:47 +0000
3+++ hooks/config-changed 2016-08-01 15:54:36 +0000
4@@ -38,7 +38,7 @@
5 # Setup the database schema
6 for host in $($(dirname $0)/print-cassandra-hosts $LOCAL_CONFIG_PATH); do
7 if PYTHONPATH=$LOCAL_CONFIG_LOCATION "$(dirname $0)/create-keyspace" -u "$cassandra_username" -p "$cassandra_password" "$host"; then
8- OOPS_KEYSPACE=crashdb OOPS_HOST="$host" python \
9+ OOPS_KEYSPACE=crashdb OOPS_HOST="$host" OOPS_USERNAME="$cassandra_username" OOPS_PASSWORD="$cassandra_password" python \
10 /usr/share/pyshared/oopsrepository/
11 fi
12 done


People subscribed via source and target branches