Index: trunk/testing/installer/installation_system.py |
— | — | @@ -36,6 +36,19 @@ |
37 | 37 | if instance: |
38 | 38 | self.set_instance(instance) |
39 | 39 | |
| 40 | + def instancedir(self): |
| 41 | + if self.instance: |
| 42 | + return os.path.join(settings.instancesdir,self.instance) |
| 43 | + else: |
| 44 | + return None |
| 45 | + |
| 46 | + def dbname(self): |
| 47 | + """find and return an appropriate database name""" |
| 48 | + return settings.dbname_prefix+self.instance |
| 49 | + |
| 50 | + def mysql_allsettings(self): |
| 51 | + return settings.mysql_command+" "+self.dbname() |
| 52 | + |
40 | 53 | def set_instance(self,instance): |
41 | 54 | self.instance=instance |
42 | 55 | |
— | — | @@ -160,6 +173,9 @@ |
161 | 174 | env["REVISION"]=self.revision or '' |
162 | 175 | env["TAG"]=self.tag or '' |
163 | 176 | env["MYSQL_COMMAND"]=settings.mysql_command |
| 177 | + env["MYSQL_ALLSETTINGS"]=self.mysql_allsettings() |
| 178 | + env["DBNAME"]=self.dbname() |
| 179 | + env["INSTANCEDIR"]=self.instancedir() |
164 | 180 | |
165 | 181 | if isinstance(task,str): |
166 | 182 | task2=[task] |