~charmers/charms/oneiric/mediawiki/trunk

« back to all changes in this revision

Viewing changes to hooks/db-relation-changed

  • Committer: Mark Mims
  • Date: 2011-09-30 19:58:14 UTC
  • Revision ID: mark.mims@agiledynamics.com-20110930195814-1wegn5z1yip934lu
cleanup from project rename

Show diffs side-by-side

added added

removed removed

Lines of Context:
56
56
## Uncomment this to disable output compression
57
57
# $wgDisableOutputCompression = true;
58
58
 
59
 
$wgSitename         = "Ensemblized Wiki";
 
59
$wgSitename         = "juju-d Wiki";
60
60
 
61
61
## The URL base path to the directory containing the wiki;
62
62
## defaults for all runtime URL paths are based off of this.
162
162
def setup_mediawiki():
163
163
 
164
164
    hostname = subprocess.check_output(['hostname','-f']).strip()
165
 
    remote_unit = os.environ.get("ENSEMBLE_REMOTE_UNIT")
 
165
    remote_unit = os.environ.get("JUJU_REMOTE_UNIT")
166
166
 
167
167
    print "remote unit", remote_unit
168
168
 
241
241
    cursor = connection.cursor()
242
242
    do_install = None
243
243
    try:
244
 
      # Try to create the "mediawiki_ensemble_setup" table and if its already there, skip some things
245
 
      cursor.execute("create table mediawiki_ensemble_setup (id int)")
 
244
      # Try to create the "mediawiki_juju_setup" table and if its already there, skip some things
 
245
      cursor.execute("create table mediawiki_juju_setup (id int)")
246
246
      do_install = True
247
247
    except Exception as e:
248
248
      # If we can't create that table, it has likely already been initialized
249
 
      print 'Could not create mediawiki_ensemble_setup: ' + str(e)
 
249
      print 'Could not create mediawiki_juju_setup: ' + str(e)
250
250
      do_install = False
251
251
    if do_install:
252
252
      # First time setup, we have to POST to the db and capture the LocalSettings.php
253
 
      postargs = {'Sitename':'Ensemblized Wiki',
 
253
      postargs = {'Sitename':'juju-d Wiki',
254
254
        'EmergencyContact':'webmaster@localhost',
255
255
        'LanguageCode':'en',
256
256
        'License':'none',