forked from ualbertalib/DMPonline_v4
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathinstall.txt
106 lines (66 loc) · 2.14 KB
/
install.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# DMPOnline - Ubuntu 14.04.03
### Utilities ###
sudo apt-get install openssh-server
sudo apt-get install git
# TODO: wkhtmltopdf
# libcurl
sudo apt-get install libcurl4-openssl-dev
# Install and set root password for mysql
sudo apt-get install mysql-server
sudo apt-get install libmysqlclient-dev
### Apache & Phusion Passenger ###
sudo apt-get install apache2
# https://www.phusionpassenger.com/library/install/apache/install/
# Install our PGP key and add HTTPS support for APT
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 561F9B9CAC40B2F7
sudo apt-get install -y apt-transport-https ca-certificates
# Add our APT repository
sudo sh -c 'echo deb https://oss-binaries.phusionpassenger.com/apt/passenger trusty main > /etc/apt/sources.list.d/passenger.list'
sudo apt-get update
# Install Passenger + Apache module
sudo apt-get install -y libapache2-mod-passenger
# Enable the Passenger Apache module and restart Apache
sudo a2enmod passenger
sudo apache2ctl restart
# Check installation
sudo passenger-config validate-install
sudo passenger-memory-stats
### Ruby ###
gpg --keyserver hkp://keys.gnupg.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3
curl -sSL https://get.rvm.io | bash -s stable --ruby
# rvm setup
source /home/rdm-tech/.rvm/scripts/rvm
# latest ruby - 2.2.1
rvm use 2.2.1
ruby --version
### Gems ###
# mysql ~> 0.3.13
sudo gem install bundler
### Mailcatcher (development only) ###
gem install mailcatcher
# Run mailcatcher @ http://ubuntu.local:1080
mailcatcher --http-ip=ubuntu.local
### DMP Online ###
git clone https://github.com/tomhigginsuom/DMPonline_v4.git
cd DMPonline_v4
bundle update
# Configure DB users
mysql -u root -p
CREATE USER 'mysql'@'localhost' IDENTIFIED BY 'password';
GRANT ALL PRIVILEGES ON *.* TO 'mysql'@'localhost';
FLUSH PRIVILEGES;
# Create config/database.yml
# ...
# Modify other config files
# ...
# Create and populate db tables
rake db:setup
rake db:populate
# Run the system (testing)
rails server
# OR Run the system (passenger)
bundle exec passenger start
# Admin user:
# super_admin@example.com password1
# Test user (needs confirmation):
# test@test.com password