Skip to content

Instantly share code, notes, and snippets.

View coocheenin's full-sized avatar

Konstantin Kuchinin coocheenin

View GitHub Profile
@coocheenin
coocheenin / caddy-install-guide.md
Last active June 18, 2022 17:28
This is in-depth guide how to install a Caddy web server as service, that running from regular unprivileged user.

How to install and configure Caddy, a modern web server, running as a service on CentOS 6.8. You will also obtain a free SSL-Certificate for a website automatically.

This is in-depth guide how to install a modern web server named Caddy as service, that running from regular unprivileged user. You will also obtain a Free SSL-Certificate for a Website automatically.

Why Caddy?

Apache and Nginx are the two most common web servers in the world. Apache is a classical solution, but due to it's memory consumption (because to it's nature of creating a new process for each request) we will leave it for another occasion. Nginx is very fast and the RAM consumption is very-very low, if we need to serve static pages. But Nginx's configuration is not to easy read and understand, this is why we will try more flexible and clear solution, which is more intended for newbies.

Caddy is written is Go, open-source and pretty fast web server. If you're looking for low-memory solution the Cadd

@coocheenin
coocheenin / caddy
Last active June 13, 2017 20:54 — forked from monobilisim/caddy
Caddy init.d script for CentOS 6 (Unprivileged User Edition)
#!/bin/sh
### BEGIN INIT INFO
# Provides: caddy
# Required-Start: $local_fs $network $named $time $syslog
# Required-Stop: $local_fs $network $named $time $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: starts the caddy web server
# Description: starts caddy using start-stop-daemon
### END INIT INFO