background preloader

Synology WebServer

Facebook Twitter

Wake On Lan Center. Advanced Power Manager for Synology DS / Wiki / Home. Send Wake over LAN packages from your Synology diskstation. Wake On LAN Script. VirtualHost Examples. This document attempts to answer the commonly-asked questions about setting up virtual hosts.

VirtualHost Examples

These scenarios are those involving multiple web sites running on a single server, via name-based or IP-based virtual hosts. Running several name-based web sites on a single IP address. Your server has multiple hostnames that resolve to a single address, and you want to respond differently for www.example.com and www.example.org. Note Creating virtual host configurations on your Apache server does not magically cause DNS entries to be created for those host names. . # Ensure that Apache listens on port 80Listen 80<VirtualHost *:80> DocumentRoot "/www/example1" ServerName www.example.com # Other directives here</VirtualHost><VirtualHost *:80> DocumentRoot "/www/example2" ServerName www.example.org # Other directives here</VirtualHost> The asterisks match all addresses, so the main server serves no requests.

You may replace * with a specific IP address on the system. The server has two IP addresses. Configuration Files. This document describes the files used to configure the Apache HTTP server.

Configuration Files

Main Configuration Files Apache is configured by placing directives in plain text configuration files. The main configuration file is usually called httpd.conf. The location of this file is set at compile-time, but may be overridden with the -f command line flag. In addition, other configuration files may be added using the Include directive, and wildcards can be used to include many configuration files. The server also reads a file containing mime document types; the filename is set by the TypesConfig directive, and is mime.types by default.

Syntax of the Configuration Files Apache configuration files contain one directive per line. Directives in the configuration files are case-insensitive, but arguments to directives are often case sensitive. The values of shell environment variables can be used in configuration file lines using the syntax ${ENVVAR}. Modules Apache is a modular server. Scope of Directives. Using the Apache web page access controls. From SynologyWiki What is this Wiki about Apache is the application that runs on your Synology NAS providing the webserver functionality, i.e. Apache delivers up the webpages of websites on the NAS. This wiki details how to implement Apache's web page access controls. If you implement this wiki you can force users to enter a user name and password to access (specific parts of) your web site on your NAS. This wiki was based on Synology's firmware v844, but will almost certainly be valid for later and some earlier versions.

Some things to be aware of Use encrypted connections to make unauthorized interception of data (such as login credentials) more difficult. Pre-requisites You have enabled the web server ("Web Station") on the NAS, e.g. via the Web management GUI. Overview of the procedure We create the password file which will contain the user names and encrypted passwords for your users. The Procedure Enable the Command Line Interface and login as root. You have finished! .htaccess file code. Basic commands to get around the Synology Box using the CLI. From SynologyWiki File Management To edit a text file (using vi) For info on how to use vi see Basic commands for Linux vi Editor To go to a directory Make a directory List contents of Directory Check size of Directory and sub-directories Find a file Delete a file Delete a directory and its content Note: Use this command with great care Move or Rename a file Copy a file Copy groups of files Copy a directory and any sub directories Create a uncompressed tar (.tar) archive To create a uncompressed (.tar) archive of all files directories and subdirectories in the current directory: Create a compressed tar (.tgz) archive To create a compressed (.tgz) archive of all files directories and subdirectories in the current directory: Unpack .tar archives For uncompressed .tar archives: Unpack .tar.gz archives.

Basic commands to get around the Synology Box using the CLI