UWSGI_LUA52(1)
๐ NAME ๐
uwsgi_lua52 โ fast (pure C), self-healing, developer-friendly WSGI server
okay so hi bestie ๐ซถ this is the UWSGI_LUA52(1) page, filed under User Commands, and yeah it is long. we're doing it in six parts, so hydrate, stretch, and do not panic ๐
โจ SYNOPSIS โจ
uwsgi-core-local [options...]
๐ฆ DESCRIPTION ๐ฆ
so here's the thing โ this whole section is basically the master list of options. every single one. we're not skipping a single flag, not even the ones that look like a typo, because they are real and they are iconic ๐
-s,--socketโ bind to the UNIX/TCP socket you name, using the default protocol-s,--uwsgi-socketโ bind to the UNIX/TCP socket you name, using the uwsgi protocol--suwsgi-socketโ bind to the UNIX/TCP socket you name, using the uwsgi protocol over SSL ๐--ssl-socketโ bind to the UNIX/TCP socket you name, using the uwsgi protocol over SSL ๐--http-socketโ bind to the UNIX/TCP socket you name, using the HTTP protocol--http-socket-modifier1โ force the modifier1 you specify when using the HTTP protocol--http-socket-modifier2โ force the modifier2 you specify when using the HTTP protocol--http11-socketโ bind to the UNIX/TCP socket you name, using the HTTP 1.1 (Keep-Alive) protocol--https-socketโ bind to the UNIX/TCP socket you name, using the HTTPS protocol--https-socket-modifier1โ force the modifier1 you specify when using the HTTPS protocol--https-socket-modifier2โ force the modifier2 you specify when using the HTTPS protocol--fastcgi-socketโ bind to the UNIX/TCP socket you name, using the FastCGI protocol--fastcgi-nph-socketโ bind to the UNIX/TCP socket you name, using the FastCGI protocol (nph mode)--fastcgi-modifier1โ force the modifier1 you specify when using the FastCGI protocol--fastcgi-modifier2โ force the modifier2 you specify when using the FastCGI protocol--scgi-socketโ bind to the UNIX/TCP socket you name, using the SCGI protocol--scgi-nph-socketโ bind to the UNIX/TCP socket you name, using the SCGI protocol (nph mode)--scgi-modifier1โ force the modifier1 you specify when using the SCGI protocol--scgi-modifier2โ force the modifier2 you specify when using the SCGI protocol--raw-socketโ bind to the UNIX/TCP socket you name, using the RAW protocol--raw-modifier1โ force the modifier1 you specify when using the RAW protocol--raw-modifier2โ force the modifier2 you specify when using the RAW protocol--puwsgi-socketโ bind to the UNIX/TCP socket you name, using the persistent uwsgi protocol (puwsgi)--protocolโ force the protocol you specify for default sockets--socket-protocolโ force the protocol you specify for default sockets--shared-socketโ create a shared socket for advanced jailing or ipc ๐--undeferred-shared-socketโ create a shared socket for advanced jailing or ipc (undeferred mode)-p,--processesโ spawn the number of workers/processes you specify-p,--workersโ spawn the number of workers/processes you specify--thunder-lockโ serializeaccept()usage (if possible) โก-t,--harakiriโ set the harakiri timeout--harakiri-verboseโ turn on verbose mode for harakiri--harakiri-no-arhโ do not enable harakiri during after-request-hook--no-harakiri-arhโ do not enable harakiri during after-request-hook--no-harakiri-after-req-hookโ do not enable harakiri during after-request-hook--backtrace-depthโ set the backtrace depth--mule-harakiriโ set the harakiri timeout for mule tasks-x,--xmlconfigโ load config from an xml file-x,--xmlโ load config from an xml file--configโ load configuration using the pluggable system--fallback-configโ re-exec uwsgi with the config you specify when the exit code is 1--strictโ enable strict mode (placeholder cannot be used) ๐ซ--skip-zeroโ skip the check of file descriptor 0--skip-atexitโ skip atexit hooks (ignored by the master)--skip-atexit-teardownโ skip atexit teardown (ignored by the master)-S,--setโ set a placeholder or an option--set-placeholderโ set a placeholder--set-phโ set a placeholder--getโ print the value of the option you specify and exit--declare-optionโ declare a new uWSGI custom option--declare-option2โ declare a new uWSGI custom option (non-immediate)--resolveโ place the result of a dns query in the placeholder you specify, syntax:placeholder=name(immediate option)--forโ (opt logic) for cycle--for-globโ (opt logic) for cycle (expand glob)--for-timesโ (opt logic) for cycle (expand the number you specify to a list starting from 1)--for-readlineโ (opt logic) for cycle (expand the file you specify to a list of lines)--endforโ (opt logic) end for cycle--end-forโ (opt logic) end for cycle--if-optโ (opt logic) check for option--if-not-optโ (opt logic) check for option--if-envโ (opt logic) check for environment variable--if-not-envโ (opt logic) check for environment variable--ifenvโ (opt logic) check for environment variable--if-reloadโ (opt logic) check for reload--if-not-reloadโ (opt logic) check for reload--if-hostnameโ (opt logic) check for hostname--if-not-hostnameโ (opt logic) check for hostname--if-hostname-matchโ (opt logic) try to match the hostname against a regular expression--if-not-hostname-matchโ (opt logic) try to match the hostname against a regular expression--if-existsโ (opt logic) check for file/directory existence--if-not-existsโ (opt logic) check for file/directory existence--ifexistsโ (opt logic) check for file/directory existence--if-pluginโ (opt logic) check for plugin--if-not-pluginโ (opt logic) check for plugin--ifpluginโ (opt logic) check for plugin--if-fileโ (opt logic) check for file existance--if-not-fileโ (opt logic) check for file existance--if-dirโ (opt logic) check for directory existance--if-not-dirโ (opt logic) check for directory existance--ifdirโ (opt logic) check for directory existance--if-directoryโ (opt logic) check for directory existance--endifโ (opt logic) end if--end-ifโ (opt logic) end if--blacklistโ set options blacklist context--end-blacklistโ clear options blacklist context--whitelistโ set options whitelist context--end-whitelistโ clear options whitelist context--ignore-sigpipeโ do not report the (annoying) SIGPIPE--ignore-write-errorsโ do not report the (annoying)write()/writev()errors--write-errors-toleranceโ set the maximum number of allowed write errors (default: no tolerance)--write-errors-exception-onlyโ only raise an exception on write errors, giving control to the app itself--disable-write-exceptionโ disable exception generation onwrite()/writev()--inheritโ use the file you specify as a config template--includeโ include the file you specify as immediate configuration--inject-beforeโ inject a text file before the config file (advanced templating)--inject-afterโ inject a text file after the config file (advanced templating)-d,--daemonizeโ daemonize uWSGI--daemonize2โ daemonize uWSGI after app loading--stopโ stop an instance--reloadโ reload an instance--pauseโ pause an instance--suspendโ suspend an instance--resumeโ resume an instance--connect-and-readโ connect to a socket and wait for data from it--extractโ fetch/dump any supported address to stdout-l,--listenโ set the socket listen queue size-v,--max-varsโ set the amount of internal iovec/vars structures--max-appsโ set the maximum number of per-worker applications-b,--buffer-sizeโ set the internal buffer size-m,--memory-reportโ enable memory report--profilerโ enable the profiler you specify-c,--cgi-modeโ force CGI-mode for plugins supporting it-a,--abstract-socketโ force UNIX socket in abstract mode (Linux only) ๐ง-C,--chmod-socketโ chmod-socket-C,--chmodโ chmod-socket--chown-socketโ chown unix sockets--umaskโ set umask--freebindโ put socket in freebind mode--map-socketโ map sockets to specific workers-T,--enable-threadsโ enable threads ๐งต--no-threads-waitโ do not wait for threads cancellation on quit/reload--auto-procnameโ automatically set processes name to something meaningful--procname-prefixโ add a prefix to the process names--procname-prefix-spacedโ add a spaced prefix to the process names--procname-appendโ append a string to process names--procnameโ set process names--procname-masterโ set master process name-i,--single-interpreterโ do not use multiple interpreters (where available)--need-appโ exit if no app can be loaded-M,--masterโ enable master process--honour-stdinโ do not remap stdin to/dev/null--emperorโ run the Emperor ๐--emperor-proxy-socketโ force the vassal to became an Emperor proxy--emperor-wrapperโ set a binary wrapper for vassals--emperor-wrapper-overrideโ set a binary wrapper for vassals to try before the default one--emperor-wrapper-fallbackโ set a binary wrapper for vassals to try as a last resort--emperor-nofollowโ do not follow symlinks when checking for mtime--emperor-procnameโ set the Emperor process name--emperor-freqโ set the Emperor scan frequency (default 3 seconds)--emperor-required-heartbeatโ set the Emperor tolerance about heartbeats--emperor-curse-toleranceโ set the Emperor tolerance about cursed vassals--emperor-pidfileโ write the Emperor pid in the file you specify--emperor-tyrantโ put the Emperor in Tyrant mode--emperor-tyrant-nofollowโ do not follow symlinks when checking for uid/gid in Tyrant mode--emperor-statsโ run the Emperor stats server--emperor-stats-serverโ run the Emperor stats server
okay that's part 1 bestie, hold on, there's more coming ๐
โจ OPTIONS โจ
okay bestie, deep breath, because this is the list. every single flag uWSGI will hand you, in order, no skips, no "and then some other stuff". grab a snack ๐, we're doing all of them.
--early-emperorโ spawns the emperor as soon as possibile. (yes, "possibile". that's the original's spelling and we respect it ๐ )--emperor-broodlordโ runs the emperor in BroodLord mode. that's genuinely the name. no notes. ๐--emperor-throttleโ sets the throttling level, in milliseconds, for vassals that are behaving badly. default is1000.--emperor-max-throttleโ sets the max throttling level, in milliseconds, for those badly-behaving vassals. default is3 minutes.--emperor-magic-execโ prefixes vassal config files withexec://if they have the executable bit. magic, literally โจ--emperor-on-demand-extensionโ searches for a text file (vassal name + extension) that contains the on demand socket name.--emperor-on-demand-extโ same thing, shorter name. twins ๐ฏ--emperor-on-demand-directoryโ turns on on demand mode, binding to the unix socket in the directory you specify, named like the vassal +.socket.--emperor-on-demand-dirโ the alias of the one above. same energy, fewer letters.--emperor-on-demand-execโ uses the output of the command you give it as the on demand socket name. the vassal name is passed as the only argument.--emperor-extra-extensionโ allows the extension you specify in the Emperor (the vassal will be called with--config).--emperor-extra-extโ alias, again. we love a short form.--emperor-no-blacklistโ disables the Emperor blacklisting subsystem. no blacklist, no drama ๐--emperor-use-cloneโ usesclone()instead offork(), passing the unshare() flags you specify.--emperor-graceful-shutdownโ uses vassals graceful shutdown during ragnarok. yes, ragnarok. iconic naming, honestly.--emperor-capโ set vassals capability.--vassals-capโ set vassals capability.--vassal-capโ set vassals capability.--imperial-monitor-listโ list enabled imperial monitors.--imperial-monitors-listโ list enabled imperial monitors. (one littlesaway from its sibling, that's it)--vassals-inheritโ adds config templates to the vassals config (uses--inherit).--vassals-includeโ includes config templates into the vassals config (uses--includeinstead of--inherit).--vassals-inherit-beforeโ adds config templates to the vassals config (uses--inherit, and parses before the vassal file).--vassals-include-beforeโ includes config templates into the vassals config (uses--includeinstead of--inherit, and parses before the vassal file).--vassals-start-hookโ runs the command you specify before each vassal starts.--vassals-stop-hookโ runs the command you specify after a vassal's death ๐--vassal-sosโ asks the emperor for reinforcement when it's overloaded. ๐--vassal-sos-backlogโ asks the emperor for sos if the backlog queue has more items than the value you specify.--vassals-setโ automatically sets the option you specify (via--set) for every vassal.--vassal-setโ automatically sets the option you specify (via--set) for every vassal.--heartbeatโ announces healthiness to the emperor ๐--reload-mercyโ sets the maximum time, in seconds, that we wait for workers and other processes to die during reload/shutdown.--worker-reload-mercyโ sets the maximum time, in seconds, that a worker can take to reload/shutdown. default is60.--mule-reload-mercyโ sets the maximum time, in seconds, that a mule can take to reload/shutdown. default is60.--exit-on-reloadโ forces an exit even if a reload was requested.--die-on-termโ exit instead of a brutal reload onSIGTERM.--force-gatewayโ forces the spawn of the first registered gateway without a master.-h|--helpโ show this help. hi ๐ซถ-h|--usageโ show this help. same, different name.--print-symโ prints the content of the binary symbol you specify.--print-symbolโ prints the content of the binary symbol you specify.-r|--reaperโ callswaitpid(-1,...)after each request to get rid of zombies ๐ง-R|--max-requestsโ reloads workers after the specified amount of managed requests.--min-worker-lifetimeโ the number of seconds a worker must run before it gets reloaded. default is60.--max-worker-lifetimeโ reloads workers after the specified amount of seconds. default is disabled.--max-worker-lifetime-deltaโ adds (worker_id * delta) seconds to themax_worker_lifetimevalue of each worker.-z|--socket-timeoutโ sets the internal sockets timeout.--no-fd-passingโ disables file descriptor passing.--locksโ creates the specified number of shared locks.--lock-engineโ sets the lock engine.--ftokโ sets the ipcsem key viaftok()for avoiding duplicates.--persistent-ipcsemโ does not remove ipcsems on shutdown.-A|--sharedareaโ creates a raw shared memory area of the specified pages. note: it supports keyval too.--safe-fdโ does not close the file descriptor you specify.--fd-safeโ does not close the file descriptor you specify.--cacheโ creates a shared cache containing the given elements.--cache-blocksizeโ sets the cache blocksize.--cache-storeโ enables persistent cache to disk.--cache-store-syncโ sets the sync frequency for the persistent cache.--cache-no-expireโ disables the auto sweep of expired items.--cache-expire-freqโ sets how often the cache sweeper scans. default is3 seconds.--cache-report-freed-itemsโ constantly reports the cache item freed by the sweeper. > use only for debug.--cache-udp-serverโ binds the cache udp server (used only for set/update/delete) to the socket you specify.--cache-udp-nodeโ sends cache update/deletion to the cache udp server you specify.--cache-syncโ copies the whole content of another uWSGI cache server on server startup.--cache-use-last-modifiedโ updates thelast_modified_attimestamp on every cache item modification. default is disabled.--add-cache-itemโ adds an item in the cache.--load-file-in-cacheโ loads a static file in the cache.--load-file-in-cache-gzipโ loads a static file in the cache with gzip compression.--cache2โ creates a new generation shared cache (keyval syntax).--queueโ enables the shared queue.--queue-blocksizeโ sets the queue blocksize.--queue-storeโ enables persistent queue to disk.--queue-store-syncโ sets the sync frequency for the persistent queue.-Q|--spoolerโ runs a spooler on the directory you specify.--spooler-externalโ maps spooler requests to a spooler directory managed by an external instance.--spooler-orderedโ tries to order the execution of spooler tasks.--spooler-chdirโchdir()s to the directory you specify before each spooler task.--spooler-processesโ sets the number of processes for spoolers.--spooler-quietโ does not be verbose with spooler tasks. (the original's words, not mine, and honestly? a mood)--spooler-max-tasksโ sets the maximum number of tasks to run before recycling a spooler.--spooler-harakiriโ sets the harakiri timeout for spooler tasks.--spooler-frequencyโ sets the spooler frequency.--spooler-freqโ sets the spooler frequency.--muleโ add a mule.--mulesโ adds the specified number of mules.--farmโ add a mule farm. ๐ด--mule-msg-sizeโ sets the mule message buffer size.--signalโ sends a uwsgi signal to a server.--signal-bufsizeโ sets the buffer size for the signal queue.--signals-bufsizeโ sets the buffer size for the signal queue.--signal-timerโ adds a timer (syntax:<signal> <seconds>).--timerโ adds a timer (syntax:<signal> <seconds>).--signal-rbtimerโ adds a redblack timer (syntax:<signal> <seconds>).--rbtimerโ adds a redblack timer (syntax:<signal> <seconds>).--rpc-maxโ maximum number of rpc slots. default:64.-L|--disable-loggingโ disables request logging.--flockโ locks the file you specify before starting, and exits if it's locked.--flock-waitโ locks the file you specify before starting, and waits if it's locked.--flock2โ locks the file you specify after logging/daemon setup, and exits if it's locked.--flock-wait2โ locks the file you specify after logging/daemon setup, and waits if it's locked.--pidfileโ creates a pidfile (before privileges drop).--pidfile2โ creates a pidfile (after privileges drop).--safe-pidfileโ creates a safe pidfile (before privileges drop).--safe-pidfile2โ creates a safe pidfile (after privileges drop).--chrootโchroot()s to the directory you specify.--pivot-rootโpivot_root()s to the directories you specify (new_rootandput_oldmust be separated with a space).--pivot_rootโpivot_root()s to the directories you specify (new_rootandput_oldmust be separated with a space).--uidโ setuid to the user/uid you specify.--gidโ setgid to the group/gid you specify.--add-gidโ adds the group id you specify to the process credentials.--immediate-uidโ setuid to the user/uid you specify IMMEDIATELY. like, right now. no waiting. ๐ฅ--immediate-gidโ setgid to the group/gid you specify IMMEDIATELY.--no-initgroupsโ disables the additional groups set viainitgroups().--capโ sets the process capability.--unshareโunshare()s part of the processes and puts them in a new namespace.--unshare2โunshare()s part of the processes and puts them in a new namespace, but after the rootfs change.--setns-socketโ exposes a unix socket returning namespace fds from/proc/self/ns.--setns-socket-skipโ skips the entry you specify when sending setns file descriptors.--setns-skipโ skips the entry you specify when sending setns file descriptors.--setnsโ joins a namespace created by an external uWSGI instance.--setns-preopenโ opens/proc/self/nsas soon as possible and caches the fds.--jailedโ marks the instance as jailed (forces the execution ofpost_jailhooks).--reforkโfork()s again after the privileges drop. useful for jailing systems.--re-forkโfork()s again after the privileges drop. useful for jailing systems.--refork-as-rootโfork()s again before the privileges drop. useful for jailing systems.--re-fork-as-rootโfork()s again before the privileges drop. useful for jailing systems.
okay bestie we're back and the option list is still going ๐ญ like she's not done, she's never done, and honestly? we respect it. buckle up, keep your <rainbow>little notebook out, bc these are all the lifecycle-spot hooks and friends ๐
--refork-post-jailโfork()again after jailing. genuinely useful for jailing systems, no cap ๐ฆ--re-fork-post-jailโ same energy,fork()again after jailing. also useful for jailing systems โจ
๐ the hook era ๐
okay so these all take a hook and run it at a very specific moment in uWSGI's little life. the way that timing is everything โ iykyk ๐
--hook-asapโ run the specified hook as soon as possible โก--hook-pre-jailโ run the specified hook before jailing ๐--hook-post-jailโ run the specified hook after jailing ๐--hook-in-jailโ run the specified hook in jail after initialization ๐--hook-as-rootโ run the specified hook before privileges drop ๐--hook-as-userโ run the specified hook after privileges drop ๐--hook-as-user-atexitโ run the specified hook before app exit and reload ๐ช--hook-pre-appโ run the specified hook before app loading ๐ฆ--hook-post-appโ run the specified hook after app loading ๐--hook-post-forkโ run the specified hook after each fork ๐ด--hook-acceptingโ run the specified hook after each worker enters the accepting phase ๐ธ--hook-accepting1โ run the specified hook after the first worker enters the accepting phase ๐ฅ--hook-accepting-onceโ run the specified hook after each worker enters the accepting phase (once per-instance) ๐--hook-accepting1-onceโ run the specified hook after the first worker enters the accepting phase (once per instance) ๐--hook-master-startโ run the specified hook when the Master starts ๐โจ--hook-touchโ run the specified hook when the specified file is touched (syntax: <file> <action>) ๐--hook-emperor-startโ run the specified hook when the Emperor starts ๐ฐ--hook-emperor-stopโ run the specified hook when the Emperor sends a stop message ๐--hook-emperor-reloadโ run the specified hook when the Emperor sends a reload message ๐--hook-emperor-lostโ run the specified hook when the Emperor connection is lost ๐--hook-as-vassalโ run the specified hook beforeexec()ing the vassal ๐ง--hook-as-emperorโ run the specified hook in the emperor after the vassal has been started ๐--hook-as-muleโ run the specified hook in each mule ๐ด--hook-as-gatewayโ run the specified hook in each gateway ๐--after-request-hookโ run the specified function/symbol after each request ๐ซถ--after-request-callโ run the specified function/symbol after each request ๐ซถ (yes bestie, same description, she's giving twin energy)
โก exec era โก
same timing drama as the hooks but it runs a command instead of a hook. main character behaviour fr ๐
--exec-asapโ run the specified command as soon as possible โก--exec-pre-jailโ run the specified command before jailing ๐--exec-post-jailโ run the specified command after jailing ๐--exec-in-jailโ run the specified command in jail after initialization ๐--exec-as-rootโ run the specified command before privileges drop ๐--exec-as-userโ run the specified command after privileges drop ๐--exec-as-user-atexitโ run the specified command before app exit and reload ๐ช--exec-pre-appโ run the specified command before app loading ๐ฆ--exec-post-appโ run the specified command after app loading ๐--exec-as-vassalโ run the specified command beforeexec()ing the vassal ๐ง--exec-as-emperorโ run the specified command in the emperor after the vassal has been started ๐
๐ mount / umount era ๐
mounting and unmounting filesystems, but make it โจscheduledโจ
--mount-asapโ mount filesystem as soon as possible โก--mount-pre-jailโ mount filesystem before jailing ๐--mount-post-jailโ mount filesystem after jailing ๐--mount-in-jailโ mount filesystem in jail after initialization ๐--mount-as-rootโ mount filesystem before privileges drop ๐--mount-as-vassalโ mount filesystem beforeexec()ing the vassal ๐ง--mount-as-emperorโ mount filesystem in the emperor after the vassal has been started ๐--umount-asapโ unmount filesystem as soon as possible โก--umount-pre-jailโ unmount filesystem before jailing ๐--umount-post-jailโ unmount filesystem after jailing ๐--umount-in-jailโ unmount filesystem in jail after initialization ๐--umount-as-rootโ unmount filesystem before privileges drop ๐--umount-as-vassalโ unmount filesystem beforeexec()ing the vassal ๐ง--umount-as-emperorโ unmount filesystem in the emperor after the vassal has been started ๐
๐ฆ wait era ๐ฆ
bestie just. wait. for the thing. to show up. patience is a vibe ๐
--wait-for-interfaceโ wait for the specified network interface to come up before running root hooks ๐ก--wait-for-interface-timeoutโ set the timeout for wait-for-interface โณ--wait-interfaceโ wait for the specified network interface to come up before running root hooks ๐ก--wait-interface-timeoutโ set the timeout for wait-for-interface โณ--wait-for-ifaceโ wait for the specified network interface to come up before running root hooks ๐ก--wait-for-iface-timeoutโ set the timeout for wait-for-interface โณ--wait-ifaceโ wait for the specified network interface to come up before running root hooks ๐ก--wait-iface-timeoutโ set the timeout for wait-for-interface โณ--wait-for-fsโ wait for the specified filesystem item to appear before running root hooks ๐--wait-for-fileโ wait for the specified file to appear before running root hooks ๐--wait-for-dirโ wait for the specified directory to appear before running root hooks ๐--wait-for-mountpointโ wait for the specified mountpoint to appear before running root hooks ๐--wait-for-fs-timeoutโ set the timeout forwait-for-fs/file/dirโณ--wait-for-socketโ wait for the specified socket to be ready before loading apps ๐--wait-for-socket-timeoutโ set the timeout for wait-for-socket โณ
๐ call era ๐
like exec, but it calls a function instead of a command. and some of them pass โจargumentsโจ so the signature matters, don't skip those ๐ซถ
--call-asapโ call the specified function as soon as possible โก--call-pre-jailโ call the specified function before jailing ๐--call-post-jailโ call the specified function after jailing ๐--call-in-jailโ call the specified function in jail after initialization ๐--call-as-rootโ call the specified function before privileges drop ๐--call-as-userโ call the specified function after privileges drop ๐--call-as-user-atexitโ call the specified function before app exit and reload ๐ช--call-pre-appโ call the specified function before app loading ๐ฆ--call-post-appโ call the specified function after app loading ๐--call-as-vassalโ call the specifiedfunction()beforeexec()ing the vassal ๐ง--call-as-vassal1โ call the specifiedfunction(char *)beforeexec()ing the vassal ๐ง--call-as-vassal3โ call the specifiedfunction(char *, uid_t, gid_t)beforeexec()ing the vassal ๐ง--call-as-emperorโ call the specifiedfunction()in the emperor after the vassal has been started ๐--call-as-emperor1โ call the specifiedfunction(char *)in the emperor after the vassal has been started ๐--call-as-emperor2โ call the specifiedfunction(char *, pid_t)in the emperor after the vassal has been started ๐--call-as-emperor4โ call the specifiedfunction(char *, pid_t, uid_t, gid_t)in the emperor after the vassal has been started ๐
๐ config loading era ๐
--iniโ load config from ini file ๐-y,--yamlโ load config from yaml file ๐ธ-y,--ymlโ load config from yaml file ๐ธ-j,--jsonโ load config from json file ๐งพ-j,--jsโ load config from json file ๐งพ
โญ modes & weights โญ
--weightโ weight of the instance (used by clustering/lb/subscriptions) โ๏ธ--auto-weightโ set weight of the instance (used by clustering/lb/subscriptions) automatically ๐ค--no-serverโ force no-server mode ๐ซ--command-modeโ force command mode ๐ป
๐ฅ socket behaviour era ๐ฅ
--no-defer-acceptโ disable deferred-accept on sockets ๐ซ--tcp-nodelayโ enable TCP NODELAY on each request ๐--so-keepaliveโ enable TCP KEEPALIVEs ๐--so-send-timeoutโ setSO_SNDTIMEOโณ--socket-send-timeoutโ setSO_SNDTIMEOโณ--so-write-timeoutโ setSO_SNDTIMEOโณ--socket-write-timeoutโ setSO_SNDTIMEOโณ--socket-sndbufโ setSO_SNDBUF๐ค--socket-rcvbufโ setSO_RCVBUF๐ฅ--shutdown-socketsโ force callingshutdown()in addition toclose()when sockets are destroyed ๐
๐ limits & reload drama ๐
bestie these are the "your worker is eating too much and we must intervene" options. the evil- ones are literally called evil, that's not me being dramatic, that's the actual flag name ๐ญ
--limit-asโ limit processes address space/vsz ๐งฑ--limit-nprocโ limit the number of spawnable processes ๐งฑ--reload-on-asโ reload if address space is higher than specified megabytes ๐--reload-on-rssโ reload if rss memory is higher than specified megabytes ๐--evil-reload-on-asโ force the master to reload a worker if its address space is higher than specified megabytes ๐--evil-reload-on-rssโ force the master to reload a worker if its rss memory is higher than specified megabytes ๐--mem-collector-freqโ set the memory collector frequency when evil reloads are in place ๐งน--reload-on-fdโ reload if the specified file descriptor is ready ๐--brutal-reload-on-fdโ brutal reload if the specified file descriptor is ready ๐ฅ
๐ธ kernel & memory era ๐ธ
--ksmโ enable Linux KSM ๐ง--pcre-jitโ enable pcre jit (if available) โก--never-swapโ lock all memory pages avoiding swapping ๐
๐ touch & fs era ๐
the "poke a file and something happens" section. it's giving magic button ๐ฎ
--touch-reloadโ reload uWSGI if the specified file is modified/touched ๐--touch-workers-reloadโ trigger reload of (only) workers if the specified file is modified/touched ๐ท--touch-mules-reloadโ reload mules if the specified file is modified/touched ๐ด--touch-spoolers-reloadโ reload spoolers if the specified file is modified/touched ๐--touch-chain-reloadโ trigger chain reload if the specified file is modified/touched โ๏ธ--touch-logrotateโ trigger logrotation if the specified file is modified/touched ๐--touch-logreopenโ trigger log reopen if the specified file is modified/touched ๐--touch-execโ run command when the specified file is modified/touched (syntax: file command) ๐--touch-signalโ signal when the specified file is modified/touched (syntax: file signal) ๐--fs-reloadโ graceful reload when the specified filesystem object is modified ๐ฟ--fs-brutal-reloadโ brutal reload when the specified filesystem object is modified ๐ฅ--fs-signalโ raise a uwsgi signal when the specified filesystem object is modified (syntax: file signal) ๐ถ
and bestieโฆ we're still not done ๐ญ she keeps going. next part, yeah? ๐ซถ
--check-mountpointโ if a filesystem stops being reachable, the instance gets destroyed. lowkey a lifesaver for reliable Fuse management ๐--mountpoint-checkโ same exact vibe: filesystem goes unreachable โ instance destroyed. yes bestie, it's a twin, not a typo, they're both here. useful for reliable Fuse management ๐ฆ--check-mountโ you guessed it: filesystem unreachable โ instance destroyed. (reliable Fuse management agenda โจ)--mount-checkโ and the fourth twin of the family: unreachable filesystem = destroyed instance. useful for reliable Fuse management ๐--propagate-touchโ an over-engineering option, fr fr, made for systems with flaky signal management ๐--limit-postโ caps the request body. that's it, that's the whole girl โ--no-orphansโ workers get auto-killed if the master dies. > heads up bestie: this can be dangerous for availability, so don't just turn it on and forget it ๐--prioโ set processes/threads priority ๐--cpu-affinityโ set cpu affinity ๐ธ--post-bufferingโ set the size in bytes after which stuff gets buffered to disk instead of memory ๐พ--post-buffering-bufsizeโ set the buffer size forread()when you're in post buffering mode ๐--body-read-warningโ set how much memory allocation (in megabytes) is allowed for a request body before it starts printing a warning at you ๐ข--upload-progressโ enables creation of.jsonfiles in the directory you specify, while a file upload is happening ๐--no-default-appโ do not fallback to default app. no plan B energy ๐ซ--manage-script-nameโ automatically rewritesSCRIPT_NAMEandPATH_INFOโจ--ignore-script-nameโ ignoreSCRIPT_NAMEentirely ๐--catch-exceptionsโ report the exception as http output. > discouraged โ use only for testing, okay? it's giving debugging-only ๐ฌ--reload-on-exceptionโ reload a worker whenever an exception is raised ๐--reload-on-exception-typeโ reload a worker when a specific exception type gets raised ๐ฏ--reload-on-exception-valueโ reload a worker when a specific exception value gets raised ๐ฏ--reload-on-exception-reprโ reload a worker when a specific exception type+value (language-specific, iykyk) gets raised ๐ฏ--exception-handlerโ add an exception handler ๐ซถ--enable-metricsโ turn on the metrics subsystem ๐--metricโ add a custom metric ๐--metric-thresholdโ add a metric threshold/alarm ๐จ--metric-alarmโ add a metric threshold/alarm (same thing, different name, we love options) ๐จ--alarm-metricโ add a metric threshold/alarm (third alias, iconic behavior) ๐จ--metrics-dirโ export metrics as text files into the directory you name ๐--metrics-dir-restoreโ restore the last value taken from the metrics dir โป๏ธ--metric-dirโ export metrics as text files to the specified directory (yes, the singular twin) ๐--metric-dir-restoreโ restore last value taken from the metrics dir โป๏ธ--metrics-no-coresโ disable generation of cores-related metrics ๐ซ--udpโ run the udp server on the address you specify ๐ก--statsโ enable the stats server on the specified address ๐--stats-serverโ enable the stats server on the specified address (same energy, different spelling) ๐--stats-httpโ prefix the stats server json output with http headers ๐--stats-minifiedโ minify the statistics json output ๐๏ธ--stats-minโ minify statistics json output (the short queen) ๐๏ธ--stats-pushโ push the stats json to the destination you specify ๐--stats-pusher-default-freqโ set the default frequency of stats pushers โฑ๏ธ--stats-pushers-default-freqโ set the default frequency of stats pushers (plural bestie, same deal) โฑ๏ธ--stats-no-coresโ disable generation of cores-related stats ๐ซ--stats-no-metricsโ do not include metrics in the stats output ๐--multicastโ subscribe to the multicast group you specify ๐ป--multicast-ttlโ set multicast ttl โณ--multicast-loopโ set multicast loop (default1) ๐--master-fifoโ enable the master fifo ๐๏ธ--notify-socketโ enable the notification socket ๐--subscription-notify-socketโ set the notification socket for subscriptions ๐ฌ--legionโ became a member of a legion โ๏ธ--legion-mcastโ became a member of a legion, but the shortcut way (shortcut for multicast) โก--legion-nodeโ add a node to a legion ๐งฉ--legion-freqโ set the frequency of legion packets ๐ถ--legion-toleranceโ set the tolerance of the legion subsystem ๐๏ธ--legion-death-on-lord-errorโ declare itself as a dead node for the amount of seconds you specify if one of the lord hooks fails ๐--legion-skew-toleranceโ set the clock skew tolerance of the legion subsystem (default30seconds) ๐ฐ๏ธ--legion-lordโ action to call on Lord election ๐--legion-unlordโ action to call on Lord dismiss ๐--legion-setupโ action to call on legion setup ๐ ๏ธ--legion-deathโ action to call on legion death (that's the shutdown of the instance, dramatic but accurate) โฐ๏ธ--legion-joinโ action to call on legion join (first time quorum is reached) ๐ค--legion-node-joinedโ action to call on a new node joining the legion ๐--legion-node-leftโ action to call on a node leaving the legion ๐ช--legion-quorumโ set the quorum of a legion ๐ณ๏ธ--legion-scrollโ set the scroll of a legion ๐--legion-scroll-max-sizeโ set max size of the legion scroll buffer ๐ฆ--legion-scroll-list-max-sizeโ set max size of the legion scroll list buffer ๐ฆ--subscriptions-sign-checkโ set the digest algorithm and certificate directory for the secured subscription system ๐--subscriptions-sign-check-toleranceโ set the maximum tolerance (in seconds) of clock skew for the secured subscription system โฒ๏ธ--subscriptions-sign-skip-uidโ skip signature check for the uid you specify when using unix sockets credentials ๐ชช--subscriptions-credentials-checkโ add a directory to search for subscriptions key credentials ๐--subscriptions-use-credentialsโ enable management ofSCM_CREDENTIALSin subscriptions UNIX sockets ๐--subscription-algoโ set the load balancing algorithm for the subscription system โ๏ธ--subscription-dotsplitโ try to fallback to the next part (dot based) in the subscription key ๐ฏ--subscribe-toโ subscribe to the subscription server you specify ๐จ--stโ subscribe to the specified subscription server (the shortest icon in the set, love that for her) ๐จ--subscribeโ subscribe to the specified subscription server ๐จ--subscribe2โ subscribe to the specified subscription server, but with the advanced keyval syntax โจ--subscribe-freqโ send subscription announce at the interval you specify ๐--subscription-toleranceโ set tolerance for subscription servers ๐ง--unsubscribe-on-graceful-reloadโ force the unsubscribe request even during a graceful reload ๐ฅ--start-unsubscribedโ configure subscriptions but don't actually send them (useful with master fifo) ๐คซ--subscribe-with-modifier1โ force the specififed modifier1 when subscribing (yes, that's exactly how the original spells it, and yes, we're keeping it character for character ๐ญ)--snmpโ enable the embedded snmp server ๐ฒ--snmp-communityโ set the snmp community string ๐ค--ssl-verboseโ be verbose about SSL errors ๐ข--ssl-verify-depthโ set maximum certificate verification depth ๐--sniโ add an SNI-governed SSL context ๐ชช--sni-dirโ check forcert/key/client_cafile in the directory you specify and create a sni/ssl context on demand ๐๏ธ--sni-dir-ciphersโ set ssl ciphers for thesni-diroption ๐--ssl-enable3โ enable SSLv3. > insecure, bestie, we said it ๐จ--ssl-enable-sslv3โ enable SSLv3. > again: insecure ๐จ--ssl-enable-tlsv1โ enable TLSv1. > and again: insecure ๐จ--ssl-optionโ set a raw ssl option (numeric value) ๐ข--sni-regexpโ add an SNI-governed SSL context (the key is a regexp) ๐ง--ssl-tmp-dirโ store ssl-related temp files in the directory you specify ๐๏ธ--check-intervalโ set the interval (in seconds) of master checks โฑ๏ธ--forkbomb-delayโ sleep for the number of seconds you specify when a forkbomb is detected ๐ฃ๐ด--binary-pathโ force binary path ๐--privileged-binary-patchโ patch the uwsgi binary with a new command (before privileges drop) ๐ฉน--unprivileged-binary-patchโ patch the uwsgi binary with a new command (after privileges drop) ๐ฉน--privileged-binary-patch-argโ patch the uwsgi binary with a new command and arguments (before privileges drop) ๐ฉน--unprivileged-binary-patch-argโ patch the uwsgi binary with a new command and arguments (after privileges drop) ๐ฉน--asyncโ enable async mode with the number of cores you specify โก--max-fdโ set maximum number of file descriptors. > requires root privileges ๐--logtoโ set logfile/udp address ๐--logto2โ log to the file or udp address you specify after privileges drop ๐--log-formatโ set advanced format for request logging ๐จ--logformatโ set advanced format for request logging (the no-dash twin) ๐จ--logformat-strftimeโ applystrftimeto logformat output ๐ฐ๏ธ--log-format-strftimeโ applystrftimeto logformat output ๐ฐ๏ธ--logfile-chownโ chown logfiles ๐ค--logfile-chmodโ chmod logfiles ๐ง--log-syslogโ log to syslog ๐ฎ--log-socketโ send logs to the socket you specify ๐--req-loggerโ set/append a request logger ๐ชต--logger-reqโ set/append a request logger (alias bestie) ๐ชต--loggerโ set/append a logger ๐ชต--logger-listโ list enabled loggers ๐--loggers-listโ list enabled loggers ๐--threaded-loggerโ offload log writing to a thread ๐งต--log-encoderโ add an item in the log encoder chain โ๏ธ--log-req-encoderโ add an item in the log req encoder chain โ๏ธ--log-drainโ drain (meaning: do not show) log lines matching the regexp you specify ๐ฐ--log-filterโ show only log lines matching the regexp you specify ๐--log-routeโ log to the named logger you specify if the regexp applied on the logline matches ๐ฃ๏ธ--log-req-routeโ log requests to the named logger you specify if the regexp applied on the logline matches ๐ฃ๏ธ--use-abortโ callabort()on segfault/fpe, which could be useful for generating a core dump ๐งจ--alarmโ create a new alarm, syntax:<alarm> <plugin:args>โฐ--alarm-cheapโ use the main alarm thread rather than creating dedicated threads for curl-based alarms ๐ธ--alarm-freqโ tune the anti-loop alarm system (default3seconds) ๐--alarm-fdโ raise the alarm you specify when an fd is read for read (by default it reads1byte, set8for eventfd) ๐จ--alarm-segfaultโ raise the alarm you specify when the segmentation fault handler is executed ๐ฅ--segfault-alarmโ bestie, when the segfault handler kicks in, raise the alarm you picked. it's giving "tell me when it all goes wrong" ๐--alarm-backlogโ raise the specified alarm when the socket backlog queue is full ๐ฅ--backlog-alarmโ raise the specified alarm when the socket backlog queue is full (same vibe, different name, both valid) โจ--lq-alarmโ raise the specified alarm when the socket backlog queue is full ๐ซถ--alarm-lqโ raise the specified alarm when the socket backlog queue is full ๐--alarm-listen-queueโ raise the specified alarm when the socket backlog queue is full ๐ธ--listen-queue-alarmโ raise the specified alarm when the socket backlog queue is full, no cap ๐--log-alarmโ raise the specified alarm when a log line matches the regexp you gave. syntax is exactly this, don't freestyle it:<alarm>[,alarm...] <regexp>๐--alarm-logโ raise the specified alarm when a log line matches the specified regexp, syntax:<alarm>[,alarm...] <regexp>โ yes it's the same as above, they're twins ๐--not-log-alarmโ the opposite energy: skip the specified alarm when a log line matches that regexp. syntax:<alarm>[,alarm...] <regexp>๐--not-alarm-logโ skip the specified alarm when a log line matches the specified regexp, syntax:<alarm>[,alarm...] <regexp>โ same thing, different spelling ๐--alarm-listโ list out all the enabled alarms, like a little roll call ๐--alarms-listโ list enabled alarms (plural girlies, same result) โจ--alarm-msg-sizeโ set the max size of an alarm message. default is8192, fyi ๐--log-masterโ delegate logging to the master process. let the main character handle it ๐--log-master-bufsizeโ set the buffer size for the master logger. heads up bestie: bigger log messages will be truncated โ๏ธ--log-master-streamโ create the master logpipe asSOCK_STREAM๐งต--log-master-req-streamโ create the master requests logpipe asSOCK_STREAM๐งต--log-reopenโ reopen the log after a reload ๐--log-truncateโ truncate the log on startup. fresh start, clean slate ๐งผ--log-maxsizeโ set the maximum logfile size ๐ฆ--log-backupnameโ set the logfile name to use after rotation ๐--logdateโ prefix your logs with a date, or astrftimestring ๐๏ธ--log-dateโ prefix logs with date or astrftimestring (same deal, dash edition) ๐ซ--log-prefixโ prefix logs with a string of your choosing ๐ท๏ธ--log-zeroโ log responses that have no body ๐ป--log-slowโ log requests slower than the number of milliseconds you specify ๐--log-4xxโ log requests with a 4xx response ๐ซ--log-5xxโ log requests with a 5xx response ๐ฅ--log-bigโ log requestes bigger than the specified size (typo is theirs, keeping it, character for character bestie ๐ญ) ๐--log-sendfileโ log sendfile requests ๐ค--log-ioerrorโ log requests that hit io errors โ ๏ธ--log-microsโ report response time in microseconds instead of milliseconds. so precise โฑ๏ธ--log-x-forwarded-forโ use the ip from theX-Forwarded-Forheader instead ofREMOTE_ADDR๐--master-as-rootโ leave the master process running as root ๐ณ (yes, root. be careful.)--drop-after-initโ run the privileges drop after plugin initialization. note: superseded bydrop-after-appsโฌ๏ธ--drop-after-appsโ run the privileges drop after apps loading. note: superseded bymaster-as-rootโฌ๏ธ--force-cwdโ force the initial working directory to whatever value you hand it ๐--binshโ override/bin/sh(it's used by exec hooks, and it always fallback to/bin/sh) ๐--chdirโchdirto the specified directory before apps loading ๐ช--chdir2โchdirto the specified directory after apps loading ๐ช--lazyโ set lazy mode (load apps in workers instead of master) ๐ฆฅ--lazy-appsโ load apps in each worker instead of the master ๐ฆฅ--cheapโ set cheap mode (spawn workers only after the first request) ๐ธ--cheaperโ set cheaper mode (adaptive process spawning) ๐ฐ--cheaper-initialโ set the initial number of processes to spawn in cheaper mode ๐ข--cheaper-algoโ choose the algorithm used for adaptive process spawning ๐ง--cheaper-stepโ number of additional processes to spawn at each overload ๐--cheaper-overloadโ increase workers after the specified overload โฌ๏ธ--cheaper-algo-listโ list enabled cheapers algorithms ๐--cheaper-algos-listโ list enabled cheapers algorithms (yes, again, they're aliases) ๐--cheaper-listโ list enabled cheapers algorithms ๐--cheaper-rss-limit-softโ don't spawn new workers if the total resident memory usage of all workers is higher than this limit ๐งฎ--cheaper-rss-limit-hardโ if total workers resident memory usage is higher, try to stop workers ๐--idleโ set idle mode (put uWSGI in cheap mode after inactivity) ๐ด--die-on-idleโ shutdown uWSGI when it's idle ๐--mountโ load an application under a mountpoint ๐--worker-mountโ load application under mountpoint in the specified worker, or after workers spawn ๐--threadsโ run each worker in prethreaded mode with the number of threads you specify ๐งต--thread-stacksizeโ set threads stacksize ๐--threads-stacksizeโ set threads stacksize ๐--thread-stack-sizeโ set threads stacksize ๐--threads-stack-sizeโ set threads stacksize ๐ (four ways to say the same thing, iconic honestly)--vhostโ enable virtualhosting mode (based on theSERVER_NAMEvariable) ๐--vhost-hostโ enable virtualhosting mode (based on theHTTP_HOSTvariable) ๐--routeโ add a route ๐ฃ๏ธ--route-hostโ add a route based on theHostheader ๐ฃ๏ธ--route-uriโ add a route based onREQUEST_URI๐ฃ๏ธ--route-qsโ add a route based onQUERY_STRING๐ฃ๏ธ--route-remote-addrโ add a route based onREMOTE_ADDR๐ฃ๏ธ--route-user-agentโ add a route based onHTTP_USER_AGENT๐ฃ๏ธ--route-remote-userโ add a route based onREMOTE_USER๐ฃ๏ธ--route-refererโ add a route based onHTTP_REFERER๐ฃ๏ธ--route-labelโ add a routing label (for use withgoto) ๐ท๏ธ--route-ifโ add a route based on a condition ๐ค--route-if-notโ add a route based on a condition, but the negate version ๐--route-runโ always run the specified route action โถ๏ธ--final-routeโ add a final route ๐--final-route-statusโ add a final route for the specified status ๐--final-route-hostโ add a final route based on theHostheader ๐--final-route-uriโ add a final route based onREQUEST_URI๐--final-route-qsโ add a final route based onQUERY_STRING๐--final-route-remote-addrโ add a final route based onREMOTE_ADDR๐--final-route-user-agentโ add a final route based onHTTP_USER_AGENT๐--final-route-remote-userโ add a final route based onREMOTE_USER๐--final-route-refererโ add a final route based onHTTP_REFERER๐--final-route-labelโ add a final routing label (for use withgoto) ๐ท๏ธ--final-route-ifโ add a final route based on a condition ๐ค--final-route-if-notโ add a final route based on a condition (negate version) ๐--final-route-runโ always run the specified final route action โถ๏ธ--error-routeโ add an error route ๐จ--error-route-statusโ add an error route for the specified status ๐จ--error-route-hostโ add an error route based on theHostheader ๐จ--error-route-uriโ add an error route based onREQUEST_URI๐จ--error-route-qsโ add an error route based onQUERY_STRING๐จ--error-route-remote-addrโ add an error route based onREMOTE_ADDR๐จ--error-route-user-agentโ add an error route based onHTTP_USER_AGENT๐จ--error-route-remote-userโ add an error route based onREMOTE_USER๐จ--error-route-refererโ add an error route based onHTTP_REFERER๐จ--error-route-labelโ add an error routing label (for use withgoto) ๐ท๏ธ--error-route-ifโ add an error route based on a condition ๐ค--error-route-if-notโ add an error route based on a condition (negate version) ๐--error-route-runโ always run the specified error route action โถ๏ธ--response-routeโ add a response route ๐ฌ--response-route-statusโ add a response route for the specified status ๐ฌ--response-route-hostโ add a response route based on theHostheader ๐ฌ--response-route-uriโ add a response route based onREQUEST_URI๐ฌ--response-route-qsโ add a response route based onQUERY_STRING๐ฌ--response-route-remote-addrโ add a response route based onREMOTE_ADDR๐ฌ--response-route-user-agentโ add a response route based onHTTP_USER_AGENT๐ฌ--response-route-remote-userโ add a response route based onREMOTE_USER๐ฌ--response-route-refererโ add a response route based onHTTP_REFERER๐ฌ--response-route-labelโ add a response routing label (for use withgoto) ๐ท๏ธ--response-route-ifโ add a response route based on a condition ๐ค--response-route-if-notโ add a response route based on a condition (negate version) ๐--response-route-runโ always run the specified response route action โถ๏ธ--router-listโ list enabled routers ๐--routers-listโ list enabled routers ๐ (plural twin, same energy)--error-page-403โ add an error page (html) for managed 403 response ๐ซ--error-page-404โ add an error page (html) for managed 404 response ๐--error-page-500โ add an error page (html) for managed 500 response ๐ฅ--websockets-ping-freqโ set the frequency (in seconds) of websockets automatic ping packets ๐--websocket-ping-freqโ set the frequency (in seconds) of websockets automatic ping packets ๐--websockets-pong-toleranceโ set the tolerance (in seconds) of the websockets ping/pong subsystem ๐--websocket-pong-toleranceโ set the tolerance (in seconds) of the websockets ping/pong subsystem ๐--websockets-max-sizeโ set the max allowed size of websocket messages, in Kbytes. default is1024๐ฆ--websocket-max-sizeโ set the max allowed size of websocket messages (in Kbytes, default1024) ๐ฆ--chunked-input-limitโ set the max size of a chunked input part (default1MB, in bytes) ๐งฉ--chunked-input-timeoutโ set the default timeout for chunked input โณ--clockโ set a clock source โฐ--clock-listโ list enabled clocks ๐ฐ๏ธ--clocks-listโ list enabled clocks ๐ฐ๏ธ--add-headerโ automatically add HTTP headers to the response โ--rem-headerโ automatically remove the specified HTTP header from the response โ--del-headerโ automatically remove specified HTTP header from the response โ--collect-headerโ store the specified response header in a request var. syntax:header var๐ฅ--response-header-collectโ store the specified response header in a request var (syntax:header var) ๐--pull-headerโ store the specified response header in a request var and remove it from the response (syntax:header var) โจ--check-staticโ check for static files in the specified directory ๐--check-static-docrootโ check for static files in the requestedDOCUMENT_ROOT๐ฆ--static-checkโ check for static files in the specified directory ๐ธ--static-mapโ map mountpoint to static directory (or file) ๐--static-map2โ likestatic-mapbut completely appending the requested resource to the docroot ๐ฅ--static-skip-extโ skip specified extension from staticfile checks ๐--static-indexโ search for specified file if a directory is requested ๐--static-safeโ skip security checks if the file is under the specified path โญ--static-cache-pathsโ put resolved paths in the uWSGI cache for the specified amount of seconds ๐--static-cache-paths-nameโ use the specified cache for static paths ๐--mimefileโ set mime types file path (default/etc/mime.types) ๐--mime-fileโ set mime types file path (default/etc/mime.types) ๐ง--static-expires-typeโ set theExpiresheader based on content type ๐--static-expires-type-mtimeโ set theExpiresheader based on content type and file mtime โจ--static-expiresโ set theExpiresheader based on filename regexp ๐--static-expires-mtimeโ set theExpiresheader based on filename regexp and file mtime ๐ฆ--static-expires-uriโ set theExpiresheader based onREQUEST_URIregexp ๐ธ--static-expires-uri-mtimeโ set theExpiresheader based onREQUEST_URIregexp and file mtime ๐--static-expires-path-infoโ set theExpiresheader based onPATH_INFOregexp ๐ฅ--static-expires-path-info-mtimeโ set theExpiresheader based onPATH_INFOregexp and file mtime ๐--static-gzipโ if the supplied regexp matches the static file translation it will search for a gzip version ๐--static-gzip-allโ check for a gzip version of all requested static files โญ--static-gzip-dirโ check for a gzip version of all requested static files in the specified dir/prefix ๐--static-gzip-prefixโ check for a gzip version of all requested static files in the specified dir/prefix ๐--static-gzip-extโ check for a gzip version of all requested static files with the specified ext/suffix ๐--static-gzip-suffixโ check for a gzip version of all requested static files with the specified ext/suffix ๐ง--honour-rangeโ enable support for the HTTP Range header ๐--offload-threadsโ set the number of offload threads to spawn (per-worker, default0) โจ--offload-threadโ set the number of offload threads to spawn (per-worker, default0) ๐--file-serve-modeโ set static file serving mode ๐ฆ--fileserve-modeโ set static file serving mode ๐ธ--disable-sendfileโ disablesendfile()and rely on boringread()/write()๐--check-cacheโ check for response data in the specified cache (empty for default cache) ๐ฅ--close-on-execโ set close-on-exec on connection sockets (could be required for spawning processes in requests) ๐--close-on-exec2โ set close-on-exec on server sockets (could be required for spawning processes in requests) ๐--modeโ set uWSGI custom mode โญ--envโ set environment variable ๐--envdirโ load a daemontools compatible envdir ๐--early-envdirโ load a daemontools compatible envdir ASAP ๐--unenvโ unset environment variable ๐ง--vacuumโ try to remove all of the generated file/sockets ๐--file-writeโ write the specified content to the specified file (syntax:file=value) before privileges drop โจ--cgroupโ put the processes in the specified cgroup ๐--cgroup-optโ set value in specified cgroup option ๐ฆ--cgroup-dir-modeโ set permission for cgroup directory (default is700) ๐ธ--namespaceโ run in a new namespace under the specified rootfs ๐--namespace-keep-mountโ keep the specified mountpoint in your namespace ๐ฅ--nsโ run in a new namespace under the specified rootfs ๐--namespace-netโ add network namespace ๐--ns-netโ add network namespace โญ--enable-proxy-protocolโ enable PROXY1 protocol support (only for http parsers) ๐--reuse-portโ enableREUSE_PORTflag on socket (BSD only) ๐--tcp-fast-openโ enableTCP_FASTOPENflag on TCP sockets with the specified qlen value ๐--tcp-fastopenโ enableTCP_FASTOPENflag on TCP sockets with the specified qlen value ๐ง--tcp-fast-open-clientโ usesendto(..., MSG_FASTOPEN, ...)instead ofconnect()if supported ๐--tcp-fastopen-clientโ usesendto(..., MSG_FASTOPEN, ...)instead ofconnect()if supported โจ--zergโ attach to a zerg server ๐--zerg-fallbackโ fallback to normal sockets if the zerg server is not available ๐ฆ--zerg-serverโ enable the zerg server on the specified UNIX socket ๐ธ--cronโ add a cron task ๐--cron2โ add a cron task (key=val syntax) ๐ฅ--unique-cronโ add a unique cron task ๐--cron-harakiriโ set the maximum time (in seconds) we wait for cron command to complete ๐--legion-cronโ add a cron task runnable only when the instance is a lord of the specified legion โญ--cron-legionโ add a cron task runnable only when the instance is a lord of the specified legion ๐--unique-legion-cronโ add a unique cron task runnable only when the instance is a lord of the specified legion ๐--unique-cron-legionโ add a unique cron task runnable only when the instance is a lord of the specified legion ๐--loopโ select the uWSGI loop engine ๐ง--loop-listโ list enabled loop engines ๐--loops-listโ list enabled loop engines โจ--worker-execโ run the specified command as worker ๐--worker-exec2โ run the specified command as worker (after post_fork hook) ๐ฆ--attach-daemonโ attach a command/daemon to the master process (the command has to not go in background) ๐ธ--attach-control-daemonโ attach a command/daemon to the master process (the command has to not go in background), when the daemon dies, the master dies too ๐--smart-attach-daemonโ attach a command/daemon to the master process managed by a pidfile (the command has to daemonize) ๐ฅ--smart-attach-daemon2โ attach a command/daemon to the master process managed by a pidfile (the command has to NOT daemonize) ๐--legion-attach-daemonโ same as--attach-daemonbut daemon runs only on legion lord node ๐--legion-smart-attach-daemonโ same as--smart-attach-daemonbut daemon runs only on legion lord node โญ--legion-smart-attach-daemon2โ same as--smart-attach-daemon2but daemon runs only on legion lord node ๐--daemons-honour-stdinโ do not change the stdin of external daemons to/dev/null๐--attach-daemon2โ attach-daemon keyval variant (supports smart modes too) ๐--pluginsโ load uWSGI plugins ๐ง--pluginโ load uWSGI plugins ๐--need-pluginsโ load uWSGI plugins (exit on error) โจ--need-pluginโ load uWSGI plugins (exit on error) ๐--plugins-dirโ add a directory to uWSGI plugin search path ๐ฆ--plugin-dirโ add a directory to uWSGI plugin search path ๐ธ--plugins-listโ list enabled plugins ๐--plugin-listโ list enabled plugins ๐ฅ--autoloadโ try to automatically load plugins when unknown options are found ๐--dlopenโ blindly load a shared library ๐--allowed-modifiersโ comma separated list of allowed modifiers โญ--remap-modifierโ remap request modifier from one id to another ๐--dump-optionsโ dump the full list of available options ๐--show-configโ show the current config reformatted as ini ๐--binary-append-dataโ return the content of a resource to stdout for appending to a uwsgi binary (fordata://usage) ๐ง--printโ simple print ๐--iprintโ simple print (immediate version) โจ--exitโ forceexit()of the instance ๐--cflagsโ report uWSGI CFLAGS (useful for building external plugins) ๐ฆ--dot-hโ dump theuwsgi.hused for building the core (useful for building external plugins) ๐ธ--config-pyโ dump theuwsgiconfig.pyused for building the core (useful for building external plugins) ๐--build-pluginโ build a uWSGI plugin for the current binary ๐ฅ--versionโ print uWSGI version ๐--response-headers-limitโ set response header maximum size (default:64k) ๐--luaโ load lua wsapi app โญ--lua-loadโ load a lua file ๐--lua-shellโ run the lua interactive shell (debug.debug()) ๐--luashellโ run the lua interactive shell (debug.debug()) ๐--lua-gc-freqโ set the lua gc frequency (default:0, runs after every request) ๐ง
and that's the whole manual page, bestie! no skips, no missing flags, we ate ๐
This was uwsgi_lua52 version 2.0.21-debian, dated May 2023, from UWSGI_LUA52(1). Go forth and configure with main character energy ๐ซถ๐โจ
๐ฆ where this page comes from
- debian bookworm: uwsgi-plugin-lua5.2 2.0.21-5.1 ยท GPL-2.0-only
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms