Installing & Configuring Apache: Difference between revisions

From NEOSYS Technical Support Wiki
Jump to navigationJump to search
m (Minor edits)
Line 3: Line 3:
The initial installation and configuration for Apache is performed by initapache_v47.sh. (Location: /Nextcloud/Support/IT/  and use the latest version of the script)
The initial installation and configuration for Apache is performed by initapache_v47.sh. (Location: /Nextcloud/Support/IT/  and use the latest version of the script)


Note: The following in following commands anything within "<__>" must be replaced with corresponding value.
Note: In the following commands, anything within "<__>" must be replaced with corresponding value.


1. If installing client on NEOSYS server (win3) skip to step 9. (to add client site to D:\Apache24\conf\neosys2.conf)
1. If installing client on NEOSYS server (win3) skip to step 9. (to add client site to D:\Apache24\conf\neosys2.conf)
Line 13: Line 13:
<pre>d2u D:/initapache_v47.sh</pre>
<pre>d2u D:/initapache_v47.sh</pre>
4. Execute script.
4. Execute script.
<pre>./initapache_v47.sh <CLIENTHOSTNAME>" </pre>
<pre>./initapache_v47.sh <CLIENTHOSTNAME>" </pre>
5. The script will proceed to do a number of verifications on system. If all test are ok, enter 'Y' to start installation as prompted to do so.
5. The script will proceed to do a number of verifications on system. If all test are okay, enter 'Y' to start installation as prompted to do so.
<pre>
<pre>
Verify OK to proceed
Verify OK to proceed
Line 26: Line 26:
6. A Microsoft Visual C++ 2015-2019 installation window will popup, follow the steps to install. (If already installed like on win3, hit cancel)
6. A Microsoft Visual C++ 2015-2019 installation window will popup, follow the steps to install. (If already installed like on win3, hit cancel)


7. You will then be prompted to install the certificates from nl19/bkup. Follow the instructions to edit /distributecerts.sh. (Script simply copies latest LetsEncrypt certificate into D:/Apache24)
7. You will then be prompted to install the certificates from nl19/bkup. Follow the instructions to edit /distributecerts.sh. (This script simply copies latest LetsEncrypt certificate into D:/Apache24)


8. After script has finished, create a Windows scheduled task to restart Apache hourly to load and newly renewed HTTPS certificates.
8. After the script has finished, create a Windows scheduled task to restart Apache hourly to load any newly renewed HTTPS certificates.
  <pre>Action: D:\Apache24\bin\httpd.exe -k restart</pre>
  <pre>Action: D:\Apache24\bin\httpd.exe -k restart</pre>
9. If client is on win3, add the new client using existing clients as an example in D:\Apache24\conf\neosys2.conf (Make sure to arrange in alphabetical order)
9. If the client is on win3, add the new client using existing clients as an example in D:\Apache24\conf\neosys2.conf (Make sure to arrange in alphabetical order)


10. Test if you can access NEOSYS login.  
10. Test if you can access NEOSYS login.  
*If Client hosted server use: https://localhost.hosts.neosys.com/3/
 
*If on win3 use https://<CLIENTHOSTNAME>.hosts.neosys.com/3/
*If Client hosted server use: https://localhost
*If on win3 use https://<CLIENTHOSTNAME>.hosts.neosys.com
 
11. In the new client's NEOSYS DATA folder, create a text file, enter '720' and save as 'DATA.CFG'.
11. In the new client's NEOSYS DATA folder, create a text file, enter '720' and save as 'DATA.CFG'.

Revision as of 10:58, 16 April 2020

Installing & Configuring Apache

The initial installation and configuration for Apache is performed by initapache_v47.sh. (Location: /Nextcloud/Support/IT/ and use the latest version of the script)

Note: In the following commands, anything within "<__>" must be replaced with corresponding value.

1. If installing client on NEOSYS server (win3) skip to step 9. (to add client site to D:\Apache24\conf\neosys2.conf) 1. Copy the installation script to the server's D drive. (Not necessary if on win3, unless re-installation of Apache required)

scp -P <SSHPORTNO> ~/Nextcloud/support/IT/initapache_v<LATESTVERSIONNO>.sh administrator@<HOSTNAME>.hosts.neosys.com:/cygdrive/d/

2. Open Cygwin as administrator on server. (Shift + Right click)

3. Convert the script into Windows format. (Otherwise script execution will contain syntax errors "\r", due to the different characters use by Linux and windows for new lines)

d2u D:/initapache_v47.sh

4. Execute script.

./initapache_v47.sh <CLIENTHOSTNAME>" 

5. The script will proceed to do a number of verifications on system. If all test are okay, enter 'Y' to start installation as prompted to do so.

Verify OK to proceed
--------------------
Port: 443
Dir:  D:/neosys/neosys.net
Root: /d
-------------------------------------
OK to start? (Y=Yes)

6. A Microsoft Visual C++ 2015-2019 installation window will popup, follow the steps to install. (If already installed like on win3, hit cancel)

7. You will then be prompted to install the certificates from nl19/bkup. Follow the instructions to edit /distributecerts.sh. (This script simply copies latest LetsEncrypt certificate into D:/Apache24)

8. After the script has finished, create a Windows scheduled task to restart Apache hourly to load any newly renewed HTTPS certificates.

Action: D:\Apache24\bin\httpd.exe -k restart

9. If the client is on win3, add the new client using existing clients as an example in D:\Apache24\conf\neosys2.conf (Make sure to arrange in alphabetical order)

10. Test if you can access NEOSYS login.

  • If Client hosted server use: https://localhost
  • If on win3 use https://<CLIENTHOSTNAME>.hosts.neosys.com

11. In the new client's NEOSYS DATA folder, create a text file, enter '720' and save as 'DATA.CFG'.