caddysave

package module
v0.0.0-...-9f25965 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 24, 2024 License: Unlicense Imports: 8 Imported by: 0

README

caddy-save

caddy handler to save request body to specified file

Usage

Self-updating Caddyfile with caddy-exec

route /caddy {
	basic_auth {
		Deployment <hashed password>
	}
	save Caddyfile
	exec caddy reload
}

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Save

type Save struct {
	FilePath string `json:"file_path,omitempty"`
}

func (Save) CaddyModule

func (Save) CaddyModule() caddy.ModuleInfo

func (Save) ServeHTTP

func (s Save) ServeHTTP(w http.ResponseWriter, r *http.Request, next caddyhttp.Handler) error

func (*Save) UnmarshalCaddyfile

func (s *Save) UnmarshalCaddyfile(d *caddyfile.Dispenser) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL