summaryrefslogtreecommitdiff
path: root/etc/httpd.conf
blob: f39c8a77b107afd9e07a35a1ed050195ec9e6590 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
types {
	include "/usr/share/misc/mime.types"
}

server "bookcorner.ge" {
	include "/etc/httpd/_listen80.conf"
	include "/etc/httpd/_acme.conf"

	location "*" {
		# HTTP 301 Moved Permanently - enforce HTTPS
		block return 301 "https://bookcorner.ge$REQUEST_URI"
	}
}

server "bookcorner.ge" {
	include "/etc/httpd/_listen443.conf"
	include "/etc/httpd/_acme.conf"

	root "/htdocs/phoenixcart"
	directory index "index.php"

	location "*.php" {
		fastcgi socket "/run/php-fpm.sock"
	}
}

server "www.bookcorner.ge" {
	include "/etc/httpd/_listen80.conf"
	include "/etc/httpd/_listen443.conf"
	include "/etc/httpd/_acme.conf"

	location "*" {
		# HTTP 301 Moved Permanently - enforce non-www site
		block return 301 "https://bookcorner.ge$REQUEST_URI"
	}
}

server "git.bookcorner.ge" {
	include "/etc/httpd/_listen80.conf"
	include "/etc/httpd/_acme.conf"

	location "*" {
		# HTTP 301 Moved Permanently - enforce HTTPS
		block return 301 "https://git.bookcorner.ge$REQUEST_URI"
	}
}

server "git.bookcorner.ge" {
	include "/etc/httpd/_listen443.conf"
	include "/etc/httpd/_acme.conf"

	location "/cgit.*" {
		root "/cgit"
		no fastcgi
	}

	root "/cgi-bin/cgit.cgi"
	fastcgi socket "/run/slowcgi.sock"
}