This repository has been archived by the owner on Jun 12, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy pathCService-Web
89 lines (71 loc) · 4.11 KB
/
CService-Web
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
____ _ __ __ _
/ ___|___ ___ _ ____ _(_) ___ ___ \ \ / /__| |__
| | / __|/ _ \ '__\ \ / / |/ __/ _ \____\ \ /\ / / _ \ '_ \
| |___\__ \ __/ | \ V /| | (_| __/_____\ V V / __/ |_) |
The \____|___/\___|_| \_/ |_|\___\___| \_/\_/ \___|_.__/ Guide #4
--------------------------------------------------------------------------
Test OS: Ubuntu 20.04.2 LTS \n \l - Server
[ by: ARI3L | y2k ]
--------------------------------------------------------------------------
CSERVICE-WEB PHP 7.4. - OFFICIAL VERSION WITH BUGS FIXED
THE ORIGINAL THEME IS NOW GONE.
--------------------------------------------------------------------------
#1. Prepare the system by installing the necessary components.
root@ircd:~# apt install apache2 apache2-bin apache2-data apache2-dev apache2-doc apache2-ssl-dev apache2-utils libapache2-mod-php
php7.4 php7.4-cgi php7.4-cli php7.4-common php7.4-curl php7.4-dev php7.4-gd php7.4-json php7.4-mysql php7.4-pgsql php7.4-readline
php7.4-sqlite3 php7.4-xml php7.4-xmlrpc libreadline-dev libssl-dev openssl zlib1g zlib1g-dev postfix
root@ircd:~# updatedb
root@ircd:~# nano /etc/php/7.4/apache2/php.ini
NOW: Go to the line 187 and change short_open_tag (from Off to On)
Save the file with (CTRL+O)
root@ircd:~# service apache2 restart
root@ircd:~# curl -sS https://getcomposer.org/installer | php && mv composer.phar /usr/local/bin/composer
#2. Now We going to download the GNUWorld cservice-web part!
root@ircd:~#
root@ircd:~# su - gnuworld
gnuworld@ircd:~$
gnuworld@ircd:~$ git clone https://github.com/GNUWorldChannel/cservice-web-php7.4.git
gnuworld@ircd:~$ mv cservice-web-php7.4 cservice-web
gnuworld@ircd:~$ cd cservice-web
gnuworld@ircd:~/gnuworld/cservice-web$ composer install
gnuworld@ircd:~/gnuworld/cservice-web$ cd php_includes
gnuworld@ircd:~/gnuworld/cservice-web/php_includes$ cp config.inc.dist config.inc
gnuworld@ircd:~/gnuworld/cservice-web/php_includes$ cp cmaster.inc.dist cmaster.inc
gnuworld@ircd:~/gnuworld/cservice-web/php_includes$ cp blackhole.inc.dist blackhole.inc
EDIT: inc files (With your own values)
gnuworld@ircd:~/gnuworld/cservice-web/php_includes$ cd ..
gnuworld@ircd:~/gnuworld/cservice-web/ cd ..
gnuworld@ircd:~/gnuworld$
#3. Now we back to root user, for some user permission.
gnuworld@ircd:~/gnuworld$ su
root@ircd:~# cd /var/www/html/
root@ircd:/var/www/html#
root@ircd:/var/www/html# chmod 711 ~gnuworld
root@ircd:/var/www/html# chmod 711 ~gnuworld/cservice-web
root@ircd:/var/www/html# chmod 755 ~gnuworld/cservice-web/php_includes
root@ircd:/var/www/html# chmod 644 ~gnuworld/cservice-web/php_includes/config.inc
root@ircd:/var/www/html# chmod 755 ~gnuworld/cservice-web/docs/gnuworld/
root@ircd:/var/www/html# ln -s /home/gnuworld/cservice-web/docs/gnuworld
root@ircd:/var/www/html# cd ..
root@ircd:/var/www# cd ..
root@ircd:/var# cd ..
root@ircd~#
root@ircd~# cd /etc/apache2/sites-enabled
root@ircd~# nano 000-default.conf
(check the correct shortcut there where is located cservice-web.)
#4. We back again into gnuworld user
root@ircd:~# cd
root@ircd:~# su - gnuworld
gnuworld@ircd:~/gnuworld$ cd /gnuworld/cservice-web/php_includes
gnuworld@ircd:~/gnuworld/cservice-web/php_includes$
NOTE: This entry is for the first username created in the db. (Admin or your custom username)
NOW: nano ipr.sql
Write your own ip. We show you as an example the first entry if you are trying to access locally.
insert into ip_restrict (id, user_id, added_by, added, type, expiry, value) values (1, 1, 1, now()::abstime::int4, 1, 0, '192.168.1.0/24');
Save the file with (CTRL+O)
With the gnuworld running, perform:
gnuworld@ircd:~/gnuworld/cservice-web/php_includes$ /usr/local/pgsql/bin/psql -h 127.0.0.1 cservice < ipr.sql
NOW you are able to login into cservice-web with Admin + temPass if you didn´t change it with the ip provided.
You can add more ips from user edit via web, so no need to use twice ipr.sql.
That´s all :)
REVIEW: y2k - ARI3L