mirror of
https://github.com/caddyserver/caddy.git
synced 2025-01-13 22:51:08 -05:00
Merge branch 'master' into interface-network-type
This commit is contained in:
commit
32d6798822
2 changed files with 11 additions and 0 deletions
|
@ -74,6 +74,10 @@ func cmdStart(fl Flags) (int, error) {
|
||||||
// sure by giving it some random bytes and having it echo
|
// sure by giving it some random bytes and having it echo
|
||||||
// them back to us)
|
// them back to us)
|
||||||
cmd := exec.Command(os.Args[0], "run", "--pingback", ln.Addr().String())
|
cmd := exec.Command(os.Args[0], "run", "--pingback", ln.Addr().String())
|
||||||
|
// we should be able to run caddy in relative paths
|
||||||
|
if errors.Is(cmd.Err, exec.ErrDot) {
|
||||||
|
cmd.Err = nil
|
||||||
|
}
|
||||||
if configFlag != "" {
|
if configFlag != "" {
|
||||||
cmd.Args = append(cmd.Args, "--config", configFlag)
|
cmd.Args = append(cmd.Args, "--config", configFlag)
|
||||||
}
|
}
|
||||||
|
|
|
@ -128,3 +128,10 @@ var (
|
||||||
_ caddyfile.Unmarshaler = (*StaticIPRange)(nil)
|
_ caddyfile.Unmarshaler = (*StaticIPRange)(nil)
|
||||||
_ IPRangeSource = (*StaticIPRange)(nil)
|
_ IPRangeSource = (*StaticIPRange)(nil)
|
||||||
)
|
)
|
||||||
|
|
||||||
|
// PrivateRangesCIDR returns a list of private CIDR range
|
||||||
|
// strings, which can be used as a configuration shortcut.
|
||||||
|
// Note: this function is used at least by mholt/caddy-l4.
|
||||||
|
func PrivateRangesCIDR() []string {
|
||||||
|
return internal.PrivateRangesCIDR()
|
||||||
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue