Set default theme and images when installing
also prompt for user full name
This commit is contained in:
parent
db0b58d45c
commit
211b55647f
|
@ -135,6 +135,28 @@ class Install(commands.Subcommand):
|
|||
subprocess.check_call(cmd)
|
||||
schema_installed = True
|
||||
|
||||
rattail = os.path.join(bindir, 'rattail')
|
||||
|
||||
# set falafel theme
|
||||
cmd = [rattail, '-c', quiet_conf, '--no-versioning',
|
||||
'setting-put', 'tailbone.theme', 'falafel']
|
||||
subprocess.check_call(cmd)
|
||||
|
||||
# set main image
|
||||
cmd = [rattail, '-c', quiet_conf, '--no-versioning',
|
||||
'setting-put', 'tailbone.main_image_url', '/messkit/img/messkit.png']
|
||||
subprocess.check_call(cmd)
|
||||
|
||||
# set header image
|
||||
cmd = [rattail, '-c', quiet_conf, '--no-versioning',
|
||||
'setting-put', 'tailbone.header_image_url', '/messkit/img/messkit-small.png']
|
||||
subprocess.check_call(cmd)
|
||||
|
||||
# set favicon image
|
||||
cmd = [rattail, '-c', quiet_conf, '--no-versioning',
|
||||
'setting-put', 'tailbone.favicon_url', '/messkit/img/messkit-small.png']
|
||||
subprocess.check_call(cmd)
|
||||
|
||||
rprint("\n\tdb schema installed to: [bold green]{}[/bold green]".format(
|
||||
obfuscate_url_pw(dburl)))
|
||||
|
||||
|
@ -150,6 +172,7 @@ class Install(commands.Subcommand):
|
|||
if not confirm or confirm != password:
|
||||
rprint("[bold yellow]passwords did not match[/bold yellow]")
|
||||
password = None
|
||||
fullname = self.basic_prompt('full name')
|
||||
|
||||
rprint()
|
||||
|
||||
|
@ -157,10 +180,12 @@ class Install(commands.Subcommand):
|
|||
rattail = os.path.join(bindir, 'rattail')
|
||||
cmd = [rattail, '-c', quiet_conf, 'make-user', '-A', username,
|
||||
'--password', password]
|
||||
if fullname:
|
||||
cmd.extend(['--full-name', fullname])
|
||||
subprocess.check_call(cmd)
|
||||
|
||||
rprint("\n\tadmin user created: [bold green]{}[/bold green]".format(
|
||||
username))
|
||||
rprint("\n\tadmin user created: [bold green]{}[/bold green]".format(
|
||||
username))
|
||||
|
||||
if self.basic_prompt("make poser dir?", True, is_bool=True):
|
||||
rprint()
|
||||
|
|
BIN
messkit/web/static/img/messkit-small.png
Normal file
BIN
messkit/web/static/img/messkit-small.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 19 KiB |
BIN
messkit/web/static/img/messkit.png
Normal file
BIN
messkit/web/static/img/messkit.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 571 KiB |
Loading…
Reference in a new issue