forked from autotest/autotest
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
frontend: Re-create autotest-manage-rpc-server and add it to setup.py
This reverts commit a7b2669, and also introduces the install of the script in setup.py. It was pointed out that this script is useful to be on a system wide install since it's necessary for the rpm spec file to install and sync the database tables. Signed-off-by: Lucas Meneghel Rodrigues <[email protected]>
- Loading branch information
Showing
2 changed files
with
21 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
#!/usr/bin/env python | ||
try: | ||
import autotest.common as common | ||
except ImportError: | ||
import common | ||
|
||
from django.core.management import execute_manager | ||
|
||
try: | ||
try: | ||
from autotest.frontend import settings | ||
except ImportError: | ||
import settings | ||
except ImportError: | ||
import sys | ||
sys.stderr.write("Error: Can't find the file 'settings.py' in the directory containing %r. It appears you've customized things.\nYou'll have to run django-admin.py, passing it your settings module.\n(If the file settings.py does indeed exist, it's causing an ImportError somehow.)\n" % __file__) | ||
sys.exit(1) | ||
|
||
if __name__ == "__main__": | ||
execute_manager(settings) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters