Configuring Synology NAS Web Server: Difference between revisions

From Littledamien Wiki
Jump to navigation Jump to search
(Created page with "Category:NAS Category:Web Development == Overview == Notes on how to configure a web server on a Synology NAS device. == Enabling the web server == '''DSM''' > '''...")
 
No edit summary
Line 7: Line 7:


'''DSM''' > '''Package Center''' > install '''Web Service'''
'''DSM''' > '''Package Center''' > install '''Web Service'''
== Controlling access and redirects ==
According to sources the "nginx" web server does not support `.htaccess`. It's necessary to use the Apache server to support `.htaccess`.
Some packages can't run on nginx, e.g. phpMyAdmin. It's necessary to edit `/etc/nginx/conf.d/www.phpMyAdmin.conf` to control access <ref>[https://forum.synology.com/enu/viewtopic.php?t=117433 .htaccess - web and >DSM6], Synoloy forums</ref>, e.g.
<syntaxhighlight lang="text">
location ~ ^/phpMyAdmin {
    allow 192.168.1.0/24;              // change to desired IP
    deny all;
    /* other configuration */
}
</syntaxhighlight>


== FTP ==
== FTP ==

Revision as of 18:55, 6 February 2017

Overview

Notes on how to configure a web server on a Synology NAS device.

Enabling the web server

DSM > Package Center > install Web Service

Controlling access and redirects

According to sources the "nginx" web server does not support .htaccess. It's necessary to use the Apache server to support .htaccess.

Some packages can't run on nginx, e.g. phpMyAdmin. It's necessary to edit /etc/nginx/conf.d/www.phpMyAdmin.conf to control access [1], e.g.

location ~ ^/phpMyAdmin {
    allow 192.168.1.0/24;              // change to desired IP
    deny all;
    /* other configuration */
}

FTP

  • DSM > Control Panel > File Sharing group > File Services > FTP tab [2]
    • Enable FTP Service: checked
    • General group > Advanced Settings button
      • Change user root directories: checked
      • Select User button
        • Add button
          • User or Group: Select existing user/group account from dropdown
          • Specify ftp root directory.

Notes

  1. .htaccess - web and >DSM6, Synoloy forums
  2. How to access files on Synology NAS via FTP, DiskStation Manager knowledge base