remove
This commit is contained in:
parent
dcc56bba1d
commit
cf9cc8aaf8
1 changed files with 2 additions and 1 deletions
|
@ -1,10 +1,11 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
app=odoo
|
app=odoo
|
||||||
domain=$(sudo yunohost app setting $app domain)
|
domain=$(sudo yunohost app setting $app domain)
|
||||||
|
database=${domain//./-}
|
||||||
instance=$(sudo yunohost app setting $app instance)
|
instance=$(sudo yunohost app setting $app instance)
|
||||||
|
|
||||||
# Remove database
|
# Remove database
|
||||||
sudo -u postgres dropdb ${domain//./-}
|
sudo -u postgres dropdb $database
|
||||||
|
|
||||||
# If removing master instance, remove Odoo.
|
# If removing master instance, remove Odoo.
|
||||||
if [ "$instance" = "master" ]; then
|
if [ "$instance" = "master" ]; then
|
||||||
|
|
Loading…
Reference in a new issue