mirror of
https://gitlab.crans.org/bde/nk20-scripts
synced 2025-06-29 09:50:54 +02:00
restart postgres to disconnect everybody
This commit is contained in:
@ -1,4 +1,6 @@
|
|||||||
#!/usr/bin/sh
|
#!/usr/bin/sh
|
||||||
|
sudo service postgresql stop
|
||||||
|
sudo service postgresql start
|
||||||
sudo -u postgres sh -c "dropdb note_db && psql -c 'CREATE DATABASE note_db OWNER note;'";
|
sudo -u postgres sh -c "dropdb note_db && psql -c 'CREATE DATABASE note_db OWNER note;'";
|
||||||
echo 'reset db';
|
echo 'reset db';
|
||||||
find apps/ -path "*/migrations/*.py*" -not -name "__init__.py" -delete
|
find apps/ -path "*/migrations/*.py*" -not -name "__init__.py" -delete
|
||||||
|
Reference in New Issue
Block a user