13 lines
330 B
Python
13 lines
330 B
Python
import subprocess
|
|
|
|
def run_service():
|
|
bash_cmd = f"""
|
|
source /home/lqs1/app/venv/bin/activate && \
|
|
cd /home/lqs1/app/server/database && \
|
|
alembic revision -m "Initial migration" --autogenerate
|
|
"""
|
|
subprocess.Popen(bash_cmd, shell=True, executable='/bin/bash')
|
|
|
|
if __name__ == '__main__':
|
|
run_service()
|