mirror of
				https://github.com/caddyserver/caddy.git
				synced 2025-11-04 03:27:23 -05:00 
			
		
		
		
	
		
			Some checks are pending
		
		
	
	Tests / test (./cmd/caddy/caddy, ~1.22.3, macos-14, 0, 1.22, mac) (push) Waiting to run
				
			Tests / test (./cmd/caddy/caddy, ~1.22.3, ubuntu-latest, 0, 1.22, linux) (push) Waiting to run
				
			Tests / test (./cmd/caddy/caddy, ~1.23.0, macos-14, 0, 1.23, mac) (push) Waiting to run
				
			Tests / test (./cmd/caddy/caddy, ~1.23.0, ubuntu-latest, 0, 1.23, linux) (push) Waiting to run
				
			Tests / test (./cmd/caddy/caddy.exe, ~1.22.3, windows-latest, True, 1.22, windows) (push) Waiting to run
				
			Tests / test (./cmd/caddy/caddy.exe, ~1.23.0, windows-latest, True, 1.23, windows) (push) Waiting to run
				
			Tests / test (s390x on IBM Z) (push) Waiting to run
				
			Tests / goreleaser-check (push) Waiting to run
				
			Cross-Build / build (~1.22.3, 1.22, aix) (push) Waiting to run
				
			Cross-Build / build (~1.22.3, 1.22, darwin) (push) Waiting to run
				
			Cross-Build / build (~1.22.3, 1.22, dragonfly) (push) Waiting to run
				
			Cross-Build / build (~1.22.3, 1.22, freebsd) (push) Waiting to run
				
			Cross-Build / build (~1.22.3, 1.22, illumos) (push) Waiting to run
				
			Cross-Build / build (~1.22.3, 1.22, linux) (push) Waiting to run
				
			Cross-Build / build (~1.22.3, 1.22, netbsd) (push) Waiting to run
				
			Cross-Build / build (~1.22.3, 1.22, openbsd) (push) Waiting to run
				
			Cross-Build / build (~1.22.3, 1.22, solaris) (push) Waiting to run
				
			Cross-Build / build (~1.22.3, 1.22, windows) (push) Waiting to run
				
			Cross-Build / build (~1.23.0, 1.23, aix) (push) Waiting to run
				
			Cross-Build / build (~1.23.0, 1.23, darwin) (push) Waiting to run
				
			Cross-Build / build (~1.23.0, 1.23, dragonfly) (push) Waiting to run
				
			Cross-Build / build (~1.23.0, 1.23, freebsd) (push) Waiting to run
				
			Cross-Build / build (~1.23.0, 1.23, illumos) (push) Waiting to run
				
			Cross-Build / build (~1.23.0, 1.23, linux) (push) Waiting to run
				
			Cross-Build / build (~1.23.0, 1.23, netbsd) (push) Waiting to run
				
			Cross-Build / build (~1.23.0, 1.23, openbsd) (push) Waiting to run
				
			Cross-Build / build (~1.23.0, 1.23, solaris) (push) Waiting to run
				
			Cross-Build / build (~1.23.0, 1.23, windows) (push) Waiting to run
				
			Lint / lint (macos-14, mac) (push) Waiting to run
				
			Lint / lint (ubuntu-latest, linux) (push) Waiting to run
				
			Lint / lint (windows-latest, windows) (push) Waiting to run
				
			Lint / govulncheck (push) Waiting to run
				
			
		
			
				
	
	
		
			189 lines
		
	
	
		
			3.2 KiB
		
	
	
	
		
			Plaintext
		
	
	
	
	
	
			
		
		
	
	
			189 lines
		
	
	
		
			3.2 KiB
		
	
	
	
		
			Plaintext
		
	
	
	
	
	
:80 {
 | 
						|
	header Denis "Ritchie"
 | 
						|
	header +Edsger "Dijkstra"
 | 
						|
	header ?John "von Neumann"
 | 
						|
	header -Wolfram
 | 
						|
	header {
 | 
						|
		Grace: "Hopper" # some users habitually suffix field names with a colon
 | 
						|
		+Ray "Solomonoff"
 | 
						|
		?Tim "Berners-Lee"
 | 
						|
		defer
 | 
						|
	}
 | 
						|
	@images path /images/*
 | 
						|
	header @images {
 | 
						|
		Cache-Control "public, max-age=3600, stale-while-revalidate=86400"
 | 
						|
		match {
 | 
						|
			status 200
 | 
						|
		}
 | 
						|
	}
 | 
						|
	header {
 | 
						|
		+Link "Foo"
 | 
						|
		+Link "Bar"
 | 
						|
		match status 200
 | 
						|
	}
 | 
						|
	header >Set Defer
 | 
						|
	header >Replace Deferred Replacement
 | 
						|
}
 | 
						|
----------
 | 
						|
{
 | 
						|
	"apps": {
 | 
						|
		"http": {
 | 
						|
			"servers": {
 | 
						|
				"srv0": {
 | 
						|
					"listen": [
 | 
						|
						":80"
 | 
						|
					],
 | 
						|
					"routes": [
 | 
						|
						{
 | 
						|
							"match": [
 | 
						|
								{
 | 
						|
									"path": [
 | 
						|
										"/images/*"
 | 
						|
									]
 | 
						|
								}
 | 
						|
							],
 | 
						|
							"handle": [
 | 
						|
								{
 | 
						|
									"handler": "headers",
 | 
						|
									"response": {
 | 
						|
										"require": {
 | 
						|
											"status_code": [
 | 
						|
												200
 | 
						|
											]
 | 
						|
										},
 | 
						|
										"set": {
 | 
						|
											"Cache-Control": [
 | 
						|
												"public, max-age=3600, stale-while-revalidate=86400"
 | 
						|
											]
 | 
						|
										}
 | 
						|
									}
 | 
						|
								}
 | 
						|
							]
 | 
						|
						},
 | 
						|
						{
 | 
						|
							"handle": [
 | 
						|
								{
 | 
						|
									"handler": "headers",
 | 
						|
									"response": {
 | 
						|
										"set": {
 | 
						|
											"Denis": [
 | 
						|
												"Ritchie"
 | 
						|
											]
 | 
						|
										}
 | 
						|
									}
 | 
						|
								},
 | 
						|
								{
 | 
						|
									"handler": "headers",
 | 
						|
									"response": {
 | 
						|
										"add": {
 | 
						|
											"Edsger": [
 | 
						|
												"Dijkstra"
 | 
						|
											]
 | 
						|
										}
 | 
						|
									}
 | 
						|
								},
 | 
						|
								{
 | 
						|
									"handler": "headers",
 | 
						|
									"response": {
 | 
						|
										"require": {
 | 
						|
											"headers": {
 | 
						|
												"John": null
 | 
						|
											}
 | 
						|
										},
 | 
						|
										"set": {
 | 
						|
											"John": [
 | 
						|
												"von Neumann"
 | 
						|
											]
 | 
						|
										}
 | 
						|
									}
 | 
						|
								},
 | 
						|
								{
 | 
						|
									"handler": "headers",
 | 
						|
									"response": {
 | 
						|
										"deferred": true,
 | 
						|
										"delete": [
 | 
						|
											"Wolfram"
 | 
						|
										]
 | 
						|
									}
 | 
						|
								},
 | 
						|
								{
 | 
						|
									"handler": "headers",
 | 
						|
									"response": {
 | 
						|
										"add": {
 | 
						|
											"Ray": [
 | 
						|
												"Solomonoff"
 | 
						|
											]
 | 
						|
										},
 | 
						|
										"deferred": true,
 | 
						|
										"set": {
 | 
						|
											"Grace": [
 | 
						|
												"Hopper"
 | 
						|
											]
 | 
						|
										}
 | 
						|
									}
 | 
						|
								},
 | 
						|
								{
 | 
						|
									"handler": "headers",
 | 
						|
									"response": {
 | 
						|
										"require": {
 | 
						|
											"headers": {
 | 
						|
												"Tim": null
 | 
						|
											}
 | 
						|
										},
 | 
						|
										"set": {
 | 
						|
											"Tim": [
 | 
						|
												"Berners-Lee"
 | 
						|
											]
 | 
						|
										}
 | 
						|
									}
 | 
						|
								},
 | 
						|
								{
 | 
						|
									"handler": "headers",
 | 
						|
									"response": {
 | 
						|
										"add": {
 | 
						|
											"Link": [
 | 
						|
												"Foo",
 | 
						|
												"Bar"
 | 
						|
											]
 | 
						|
										},
 | 
						|
										"require": {
 | 
						|
											"status_code": [
 | 
						|
												200
 | 
						|
											]
 | 
						|
										}
 | 
						|
									}
 | 
						|
								},
 | 
						|
								{
 | 
						|
									"handler": "headers",
 | 
						|
									"response": {
 | 
						|
										"deferred": true,
 | 
						|
										"set": {
 | 
						|
											"Set": [
 | 
						|
												"Defer"
 | 
						|
											]
 | 
						|
										}
 | 
						|
									}
 | 
						|
								},
 | 
						|
								{
 | 
						|
									"handler": "headers",
 | 
						|
									"response": {
 | 
						|
										"deferred": true,
 | 
						|
										"replace": {
 | 
						|
											"Replace": [
 | 
						|
												{
 | 
						|
													"replace": "Replacement",
 | 
						|
													"search_regexp": "Deferred"
 | 
						|
												}
 | 
						|
											]
 | 
						|
										}
 | 
						|
									}
 | 
						|
								}
 | 
						|
							]
 | 
						|
						}
 | 
						|
					]
 | 
						|
				}
 | 
						|
			}
 | 
						|
		}
 | 
						|
	}
 | 
						|
}
 |