-
Notifications
You must be signed in to change notification settings - Fork 141
Jay B. Martin edited this page Oct 17, 2013
·
1 revision
This is an unorthodox way to run MySQL, but possibly also the easiest.
- Download and install MAMP from this website (No need for the Pro version).
- Open the application to turn on a MySQL database (click "Start Servers").
- A website for controlling MySQL (phpMyAdmin) should automatically open; if not there is a button to open it. Use it to create a new user called 'mturk' with an associated database of the same name.
- Add the following line to the config.txt file in your PsiTurk project, changing mturk to something else if you used a different database name:
database_url: mysql://mturk@localhost/mturk?unix_socket=/Applications/MAMP/tmp/mysql/mysql.sock
Now follow the instructions for setting up Python to use MySQL.
This is the traditional way of running a MySQL database.
- Follow the instructions here to install MySQL.
- Create a database for the mysql user called mturk (or whatever you want):
mysql -umysql CREATE DATABASE mturk
Then add the following line to the config.txt file in your PsiTurk project:
database_url: mysql://mysql@localhost:3306/mturk
Install the MySQL connection software using:
sudo easy_install mysql-connector-python sudo easy_install mysql-python
...you may get an error regarding a dylib file. If so follow the instructions here