After purchsing a Synology DS 211j , I have been configuring some of the features I really like such as the web server and the mail station. Since I am currently hosting 2 websites on my Disk Station – or DS – and also the Roundcube mailstation, I decided that running mailstation on a regular http port, 80, will not do.
I found some good mods on the web, so that you can change the main.inc.php file of the Roundcube config, so that the web site redirects the visitor automatically to https (on port 443). Read more about the advantages of the SSL connection over port 443 here.
Here’s the drill:
- Download PuTTY here;
- Ensure that SSH is switched on in the DSM (in my case version 3.1). Do this by going to the control panel, go to terminal and enable SSH Service.;
- Ensure that the SSH service is configured correctly in the firewall of DSM. Do this by going to the control panel, go to firewall, edit the appropriate (local) firewall rule and enable port 22. Now, this is NOT the firewall on your router but the firewall of the DS211j;
- Now start PuTTy and connect to the IP address of the DS;
- Log in with account name root (no… not admin.) root has more privilleges, and uses the same password as admin
- Now go to the following directory. Just copy the following line in the terminal : “cd /volume1/@appstore/MailStation/roundcubemail/config/” and hit enter;
- Being in this correct directory, we are now going to edit the file called main.inc.php. Please perform this with extreme caution and only change what is directed in this post;
- Type the command: “vi main.inc.php” to view the contents of this file
- Scroll down until you see a line which holds $rcmail_config['force_https'] = false
- set the cursor behind false and hit i. Putty is now in edit mode for this file;
- Change false into true;
- Hit ESC to exit the edit mode;
- type :wq to store the changed file;
- Log out and check your Roundcube website by typing http://192.168.1.3/mail (for example). You will notice the website is redirected to https://192.168.1.3/mail (including the s behind http, e.g. communicating over port 443 now)
- Be sure you have also switched on the https feature of the built-in web server. this can be done under the DSM tool by navigating to the control panel and opening web services. Navigate to the tab called http-service and set the appropriate check box.





































































