-
Notifications
You must be signed in to change notification settings - Fork 1
Install on Linux or Mac
Kun Yang edited this page Oct 5, 2017
·
10 revisions
Learn how to install mCard on a Mac or Linux from YouTube:
- install Ruby and MySQL, and start MySQL server
git clone https://github.com/KunYang99/mCard.git
- create MySQL database and load default data (e.g. ~/databases/mCard/dumps/seed.sql) You can use Sequel Pro, MySQL Workbench, or command-line to manage MySQL databases and tables
- go to mCard folder, for example:
cd ~/databases/mCard
bundle install
- create config/database.yml to link mCard to MySQL database. An example of database.yml
development:
adapter: mysql2
encoding: utf8
reconnect: false
database: mcard_dev
pool: 5
username: root
password: root
hostname: localhost
socket: /tmp/mysql.sock
rails s puma
- Congrats, your own mCard system is online: http://localhost:3000. You will see a page like this:
- The default username and password for administrator is root:root. You can change the password via "Manage Your Account" or "Administration Portal".
- Now you are ready to use mCard to manage your own data.
If it is the first time that you install mCard on the computer or the address of mCard is changed, you need to update reCAPTCHA settings. To set up reCAPTCHA:
-
Register new site follow instructions on the page. When choosing the type of reCAPTCHA, select reCAPTCHA V2 (validate users with the "I am not a robot" checkbox)
-
After registration, you will get the new key and secret
-
Update environment variables. Add or update the following two lines in ~/.bashrc:
export reCAPTCHA_key="YOUR_KEY" export reCAPTCHA_secret="YOUR_SECRET"
-
reload configuration:
source ~/.bashrc
-
start or restart mCard