aboutsummaryrefslogtreecommitdiffstats
path: root/README.md
diff options
context:
space:
mode:
authorLaurent Bachelier <laurent@bachelier.name>2011-02-17 01:30:17 +0100
committerLaurent Bachelier <laurent@bachelier.name>2011-02-17 01:38:54 +0100
commit06aa341bc2f6d144548b78f267023aec8646d4eb (patch)
treec5d5d1226371023c6b108ef4b087571459bc6d61 /README.md
parentProperly escape the genconf path (diff)
downloadsymfttpd-06aa341bc2f6d144548b78f267023aec8646d4eb.tar.xz
genconf does not require to be in the project directory anymorev1.1.1
If users were changing the config/lighttpd.php file to a non-default one, they still can have this behavior by setting the genconf_cmd option in config/symfttpd.conf.php.
Diffstat (limited to 'README.md')
-rw-r--r--README.md33
1 files changed, 23 insertions, 10 deletions
diff --git a/README.md b/README.md
index 8a13d1c..ec81ce7 100644
--- a/README.md
+++ b/README.md
@@ -149,38 +149,50 @@ while project-level config is for things that only concern your project.
## genconf
-If you don't want to copy/paste lighttpd configs, handle regexps when
-you add files, or fight rewriting issues (which can often happen
+If you don't want to copy/paste lighttpd configs, handle regular expressions
+when you add files, or fight rewriting issues (which can often happen
considering that most available examples are badly written),
then this tool is for you. It is also used internally by `spawn`.
### Quick start
-This first part is unnecessary if you used `mksymlinks`:
-
- cd /path/to/example.com/config
- ln -s /path/to/symfttpd/genconf ./lighttpd.php
-
lighttpd config:
$HTTP["host"] == "example.com" {
- include_shell "/path/to/example.com/config/lighttpd.php"
+ include_shell "/path/to/symfttpd/genconf -p /path/to/example.com/web"
}
or if you want a different default application:
$HTTP["host"] == "mobile.example.com" {
- include_shell "/path/to/example.com/config/lighttpd.php --default=mobile"
+ include_shell "/path/to/symfttpd/genconf -p /path/to/example.com/web -d mobile"
}
If symfttpd is running in single-process mode, or you only running an independent
-lighttpd, you have to restart it each time you add a file the the web/ root.
+lighttpd, you have to restart it each time you add a file in the `web/` root.
Hopefully, it doesn't happen often.
Also, don't forget to run `php symfony plugin:publish-assets`, or even better,
`mksymlinks` before.
+### Alternative
+
+The web directory can be omitted if genconf is present in the project directory.
+It can either be a symbolic link, or a copy shipped with the project
+(it is designed to be independent).
+This first part is unnecessary if you used `mksymlinks`:
+
+ cd /path/to/example.com/config
+ ln -s /path/to/symfttpd/genconf ./lighttpd.php
+
+lighttpd config:
+
+ $HTTP["host"] == "example.com" {
+ include_shell "/path/to/example.com/config/lighttpd.php"
+ }
+
+
### Available options
* `-d <app>` (default): Change the default application (default being `index`)
@@ -189,6 +201,7 @@ Also, don't forget to run `php symfony plugin:publish-assets`, or even better,
(useful for allowing a `_dev` alternative, for example)
* `-n <dir1,dir2>` (nophp): Deny PHP execution in the specified directories
(default being `uploads`).
+* `-p <path>` (path): Path of the `web` directory. Autodected to ../web if not present.
For portability reasons, only short options (one letter) are used.