You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.rst
+66Lines changed: 66 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -48,6 +48,72 @@ We use submodules to include external libraries in sympy-live::
48
48
This is sufficient to clone appropriate repositories in correct versions
49
49
into sympy-live (see git documentation on submodules for information).
50
50
51
+
Setting Up for Testing PR 144
52
+
-----------------------------
53
+
54
+
You must have python3 installed. You can check your version by::
55
+
56
+
$ python3 -V
57
+
58
+
The version must be greater than 3.4. If not present you can install it by::
59
+
60
+
$ sudo apt install python3
61
+
62
+
You need to create the virtual environment and activate it::
63
+
64
+
$ sudo apt-get install python3-venv
65
+
$ python3 -m venv env
66
+
$ source env/bin/activate
67
+
68
+
SymPy Live uses MySQL for database purpose. So you need to setup mysql::
69
+
70
+
$ sudo apt-get install mysql-server
71
+
$ sudo apt-get install libmysqlclient-dev
72
+
$ sudo apt-get install python3-dev
73
+
$ sudo systemctl start mysql
74
+
$ sudo mysql
75
+
76
+
This will open mysql. You will now have to create a new database with name {database_name}. Create a new user {user_name} and password {user_password}. Grant all previleges to <user_name> on {database-name}::
77
+
78
+
mysql> CREATE DATABASE {database_name};
79
+
mysql> UPDATE mysql.user SET authentication_string = PASSWORD('{user_password}') WHERE User = '{user_name}';
80
+
mysql> FLUSH PRIVILEGES;
81
+
mysql> GRANT ALL PRIVILEGES ON *.* TO '{user_name}'@'localhost' IDENTIFIED BY '{user_password}';
82
+
83
+
To ensure that the database server launches after a reboot, run the following command::
84
+
85
+
$ sudo systemctl enable mysql
86
+
87
+
Now in settings.py set up the database for MySQL::
88
+
89
+
DATABASES = {
90
+
'default': {
91
+
'ENGINE': 'django.db.backends.mysql',
92
+
'HOST': '127.0.0.1', # DB's IP address
93
+
'PORT': '3306',
94
+
'NAME': '{database_name}',
95
+
'USER': '{user_name}',
96
+
'PASSWORD': '{user_password}',
97
+
}
98
+
}
99
+
100
+
Install dependencies from requirements.txt::
101
+
102
+
$ pip install -r requirements.txt
103
+
104
+
migrate the changes::
105
+
106
+
$ python3 manage.py makemigrations
107
+
$ python3 manage.py migrate
108
+
$ python3 manage.py createsuperuser # will be used to login into admin panel
109
+
110
+
And fianlly::
111
+
112
+
$ python3 manage.py runserver
113
+
114
+
This runs the site on localhost. But before using the SymPy Live go to admin panel. There you need to create new user 'anonymous'. You can keep password anythong but name must be exactly same.
0 commit comments