/
INSTALL
92 lines (60 loc) · 1.92 KB
/
INSTALL
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
# Onyx install on Debian Jessie (see https://onxshop.com/download)
wget -O - https://onxshop.com/debian/conf/signing_key.pub | apt-key add -
echo "deb http://onxshop.com/debian/ jessie main" > /etc/apt/sources.list.d/onyx.list
apt-get update && apt-get install onyx-1.7
# Create new project using utils/onyx.sh script
onyx-1.7 create test.local.onxshop.com
# Or create new project manually:
cd /srv/
cp -a /opt/onyx-1.7/project_skeleton/base_with_blog/ ./
mv project_skeleton [HOSTNAME]
cd [HOSTNAME]
chmod a+rwx -R var/
#create symlink to shared onyx folder
ln -s /opt/onyx-1.7 onyx;
# configure [HOSTNAME] vhost
vi /etc/apache2/sites-available/[HOSTNAME].conf
<VirtualHost *:80>
ServerName [HOSTNAME]
VirtualDocumentRoot [PROJECT_DIR]/public_html
</VirtualHost>
a2ensite [HOSTNAME] && service apache2 reload
# create a new database user
sudo su - postgres
createuser -SRdP [NEWUSER]
(choose [NEWPASSWORD])
exit
# create new database under newly created db user
createdb -U [NEWUSER] -h localhost [NEWPROJECT]-1_7
# populate database with project template
psql -U [NEWUSER] -h localhost [NEWPROJECT]-1_7 < onyx/project_skeleton/base_with_blog.sql
# modify deployment.php
vi conf/deployment.php
/**
* Database connection
*/
define('ONYX_DB_TYPE', 'pgsql');
define('ONYX_DB_USER', '[NEWUSER]');
define('ONYX_DB_PASSWORD', ''[NEWPASSWORD);
define('ONYX_DB_HOST', 'localhost');
define('ONYX_DB_PORT', 5432);
define('ONYX_DB_NAME', '[NEWPROJECT]-1_7');
# Website frontend access:
http://[NEWPROJECT]/
# website admin access:
http://[HOSTNAME]/edit
username: [NEWUSER]
password: [NEWPASSWORD]
In case of any problem, i.e. a blank screen, enable debugging for your client IP address:
vi conf/deployment.php
/**
* Application Debug settings
*
* 0 - No debugging
* 3 - Full debugging
* 5 - Full debugging (direct ouput)
*/
$debug_hosts = array(
'[YOUR_CLIENT_IP_ADDRESS]' => 1
);
And also check /var/log/apache2/error.log