Apache windows directory alias
Viewed 50k times. Improve this question. Add a comment. Active Oldest Votes. Improve this answer. Worked for me perfectly. And don't forget to restart Apache — Onimusha. To accomplish your list of needs. Stefan Michev. In httpd. Note that link-only answers are discouraged, SO answers should be the end-point of a search for a solution vs.
From a general perspective, a shortcut is basically a regular file containing path data: we can think on them as text files which only contain a URI for a file, a folder or any other external resource UNC share, HTTP s address, and so on : that URI gets executed whenever the user clicks on executes them, as long as the operating system allows it — which is the default behaviour by default, but can be disabled for security reasons.
Conversely from aliases, NTFS symbolic links also known as symlink have been implemented to function just like the UNIX aliases: for that very reason, they are transparent to users and applications. They do appear just any other standard file or folder, and can be acted upon by the user or application in the same manner. On Windows Vista and later, including Windows 10, symbolic links can be created uisng the mklink. In Windows XP, where mklink. December 17, November 22, November 22, November 19, November 19, In Terminal type the following command to put a Symlink to that folder.
Certainly, you need to change the destination path. One thing that distinguishes Symlink from Shortcut or the Alias Folder is that a Symlink will be treated like the original file. Symlink can be accessed through Terminal and can also be added to any GUI application. In SublimeText, for instance, you can add the Symlink, instead of the original source as a Project. We would not be able for doing so with a Shortcut and an Alias folder.
Aside from creating a Symlink folder, we can also use Apache Alias. If you need to specify the name of the service you want to install, use the following command. You have to do this if you have several different service installations of Apache on your computer. If you specify a name during the install, you have to also specify it during any other -k operation. If you need to have specifically named configuration files for different services, you must use this:. If you use the first command without any special parameters except -k install , the service will be called Apache2.
Before starting Apache as a service by any means, you should test the service's configuration file by using:. You can control an Apache service by its command line switches, too. To start an installed Apache service you'll use this:.
You can also restart a running service and force it to reread its configuration file by using:. By default, all Apache services are registered to run as the system user the LocalSystem account. It has, however, wide privileges locally. It is recommended that users create a separate account for running Apache service s. If you have to access network resources via Apache, this is required. If you allow the account to log in as a user and as a service, then you can log on with that account and test that the account has the privileges to execute the scripts, read the web pages, and that you can start Apache in a console window.
If this works, and you have followed the steps above, Apache should execute as a service with no problems. When starting Apache as a service you may encounter an error message from the Windows Service Control Manager. For example, if you try to start Apache by using the Services applet in the Windows Control Panel, you may get the following message:. Could not start the Apache2. You will get this generic error if there is any problem with starting the Apache service. In order to see what is really causing the problem you should follow the instructions for Running Apache for Windows from the Command Prompt.
If you are having problems with the service, it is suggested you follow the instructions below to try starting httpd. Running Apache as a service is usually the recommended way to use it, but it is sometimes easier to work from the command line, especially during initial configuration and testing. This will open a console window and start Apache inside it.
If you don't have Apache installed as a service, the window will remain visible until you stop Apache by pressing Control-C in the console window where Apache is running in. The server will exit in a few seconds. However, if you do have Apache installed as a service, the shortcut starts the service. If the Apache service is running already, the shortcut doesn't do anything.
If Apache is running as a service, you can tell it to stop by opening another console window and entering:. Running as a service should be preferred over running in a console window because this lets Apache end any current operations and clean up gracefully. But if the server is running in a console window, you can only stop it by pressing Control-C in the same window.
0コメント