aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVikraman Choudhury <vikraman.choudhury@gmail.com>2011-05-12 23:46:14 +0530
committerVikraman Choudhury <vikraman.choudhury@gmail.com>2011-05-12 23:46:14 +0530
commitf71aa99801b8588d9060feee06f501c18613cfa6 (patch)
tree20b8bffb59c4fd91fd8cd5591b7eccd01af842d6
parentfixes after code review (diff)
downloadgentoostats-f71aa99801b8588d9060feee06f501c18613cfa6.tar.gz
gentoostats-f71aa99801b8588d9060feee06f501c18613cfa6.tar.bz2
gentoostats-f71aa99801b8588d9060feee06f501c18613cfa6.zip
added setup instructions
-rw-r--r--docs/setup.txt48
-rwxr-xr-xserver/main.py4
-rw-r--r--server/sql/init.sql2
-rw-r--r--server/sql/setup.sql2
4 files changed, 52 insertions, 4 deletions
diff --git a/docs/setup.txt b/docs/setup.txt
new file mode 100644
index 0000000..b80d255
--- /dev/null
+++ b/docs/setup.txt
@@ -0,0 +1,48 @@
+
+Gentoostats
+===========
+
+Server
+======
+Dependencies
+------------
+dev-db/mysql
+dev-python/mysql-python
+dev-python/webpy
+=dev-lang/python-2.*
+
+Instructions
+------------
+* Start the mysql server
+* Execute server/sql/init.sql as mysql root user
+
+ mysql -u root -p < server/sql/init.sql
+
+* Execute server/sql/setup.sql as user gentoo, password gentoo
+
+ mysql -u gentoo -p < server/sql/setup.sql
+
+* Start the main.py script, either from the server/ directory or
+ by exporting PYTHONPATH
+
+ export PYTHONPATH=server/
+ server/main.py
+
+
+Client
+======
+Dependencies
+------------
+=dev-lang/python-2.*
+app-portage/gentoolkit
+
+Instructions
+------------
+* Set host uuid and password in client/bin/client
+* Execute client/bin/client as root or some user in portage group
+
+ export PYTHONPATH=client/
+ client/bin/client
+
+
+P.S. All paths are relative to source directory
diff --git a/server/main.py b/server/main.py
index 7796aba..08b8509 100755
--- a/server/main.py
+++ b/server/main.py
@@ -13,8 +13,8 @@ urls = (
db = web.database(
dbn='mysql',
- user='vh4x0r',
- pw='vh4x0r',
+ user='gentoo',
+ pw='gentoo',
db='gentoostats'
)
diff --git a/server/sql/init.sql b/server/sql/init.sql
index 68d309f..c0588cd 100644
--- a/server/sql/init.sql
+++ b/server/sql/init.sql
@@ -1,5 +1,5 @@
--- run as 'vh4x0r'@'localhost' identified by 'vh4x0r'
+-- run as 'gentoo'@'localhost' identified by 'gentoo'
use gentoostats;
drop table if exists hosts;
diff --git a/server/sql/setup.sql b/server/sql/setup.sql
index 98126d7..f57ed9b 100644
--- a/server/sql/setup.sql
+++ b/server/sql/setup.sql
@@ -1,3 +1,3 @@
-- run as root
create database gentoostats;
-grant all on gentoostats.* to 'vh4x0r'@'localhost' identified by 'vh4x0r';
+grant all on gentoostats.* to 'gentoo'@'localhost' identified by 'gentoo';