Skip to content
Browse files

add --umask option to yaws script

Users can use the --umask option to set the process umask for the yaws
daemon. By default the daemon inherits the umask of its parent process.
  • Loading branch information...
1 parent 08fcadd commit ee35df4e305e0818fa04865eb5ee3361527b856e @vinoski vinoski committed Aug 3, 2010
Showing with 9 additions and 1 deletion.
  1. +5 −1 man/yaws.1
  2. +4 −0 scripts/yaws.template
View
6 man/yaws.1
@@ -12,7 +12,7 @@ in interactive mode where it is possible to directly interact
with the webserver. Yaws is particularly good at generating
dynamic content. See the user docs for more information on that topic.
-.SH DEAMON/SERVER options
+.SH DAEMON/SERVER options
.TP
@@ -142,6 +142,10 @@ may interact with the wrong daemon due to finding the wrong "ctl" file.
The daemon may also optionally specify the "id" in the yaws.conf
configuration file.
+.TP
+\fB\--umask MASK\fR
+Set the umask for the daemon to MASK.
+
.SH CONTROL OPTIONS
.PP
The following list of options are are used to control the daemon
View
4 scripts/yaws.template
@@ -63,6 +63,7 @@ help()
echo " --run_erl X -- use run_erl with pipe-id X"
echo " --to_erl X -- connect to pipe-id X"
echo " --disable-kpoll -- pass +K false to erlang"
+ echo " --umask umaskval -- set process umask to umaskval"
echo ""
echo "ctl functions ... "
@@ -288,6 +289,9 @@ while [ $# -gt 0 ]
PIPE_DIR="${vardir}/run/yaws/pipe/$1"
LOG_DIR="${vardir}/log/yaws/erlang-log/$1"
shift;;
+ --umask)
+ umask $1
+ shift;;
*)
help
esac

0 comments on commit ee35df4

Please sign in to comment.
Something went wrong with that request. Please try again.