A minimal but flexible directory listing server
Find a file
2020-08-30 09:38:02 +02:00
.clang-format Read from template files with placeholder replacement 2020-08-28 00:46:08 +02:00
.drone.yml Read from template files with placeholder replacement 2020-08-28 00:46:08 +02:00
.gitignore Read from template files with placeholder replacement 2020-08-28 00:46:08 +02:00
arg.h Correct arg.h license 2018-07-16 11:49:51 +02:00
config.def.h Read from template files with placeholder replacement 2020-08-28 00:46:08 +02:00
config.mk Be extra pedantic again and remove all warnings 2018-03-05 00:30:53 +01:00
dirl.c Find template in root, don't search tail dir twice 2020-08-30 09:38:02 +02:00
dirl.h Find template in root, don't search tail dir twice 2020-08-30 09:38:02 +02:00
http.c Read dirlist from templates 2020-08-25 21:08:23 +02:00
http.h Rename "target" to "URI" where appropriate 2020-08-22 23:38:38 +02:00
LICENSE Use timegm() instead of mktime() to generate UNIX-timestamp 2020-07-23 16:48:34 +02:00
main.c Rename s to srv 2020-08-23 11:03:18 +02:00
Makefile Read dirlist from templates 2020-08-25 21:08:23 +02:00
quark.1 Mention default behaviour in the manual when the host is not given 2020-08-23 13:36:56 +02:00
README.md Add patch to README 2020-08-18 21:27:53 +02:00
resp.c Find template in root, don't search tail dir twice 2020-08-30 09:38:02 +02:00
resp.h Refactor http_send_response() into http_prepare_response() 2020-08-22 23:20:00 +02:00
sock.c Refactor sock_get_uds() a bit 2020-08-23 13:35:49 +02:00
sock.h Ensure const-correctness where possible and refactor parse_range() 2020-08-05 18:28:21 +02:00
util.c Refactoring 2020-08-30 08:43:10 +02:00
util.h Refactoring 2020-08-30 08:43:10 +02:00

Build Status

This is my private tree of quark. Upstream can be found at https://git.suckless.org/quark.

Quark is a small http server.

Issues

fork: Resource temporarily unavailable

When running quark (#6606994) on my system with sudo ./quark -p 9763 -u <user> -g <group> it dies with ./quark: fork: Resource temporarily unavailable at fork().

Reason being that by default quark sets the RLIMIT_NPROC to 512 processes. When running as a non-exclusive user this limit is easily reached before even starting quark.

resource-depletion-fix contains a small forkbomb (minibomb.c) to simulate a user with > 512 processes. Compile it with make minibomb. When running the minibomb and quark with the same user quark fails.

The resource-depletion-fix branch contains a fix by setting the RLIMIT_NPROC only if the current system limit is lower than what would be set by quark. You can download the patch, or compile from the resource-depletion-fix branch.

Note that quark also has a -n parameter with which the max number of processes can be set as an alternative to this patch.

Github Users

If you are visiting this repository on GitHub, you are on a mirror of https://git.friedl.net/playground/suckless-quark. This mirror is regularily updated with my other GitHub mirrors. In contrast to other projects I do not intend to move this tree to GitHub in the future. It is meant to stay a read-only mirror.

You are welcome to pull any changes from this repository into your quark tree. If you want to contribute consider contributing directly to upstream.

If you still - for whichever reasons - want to contribute to my tree directly, feel free to send patches to dev[at]friedl[dot]net. Alternatviely you can issue a pull request on GitHub which will be cherry picked into my tree.