serve: add auth proxy infrastructure
This commit is contained in:
parent
a7eec91d69
commit
e6ab237fcd
5 changed files with 499 additions and 0 deletions
18
cmd/serve/proxy/proxyflags/proxyflags.go
Normal file
18
cmd/serve/proxy/proxyflags/proxyflags.go
Normal file
|
@ -0,0 +1,18 @@
|
|||
// Package proxyflags implements command line flags to set up a proxy
|
||||
package proxyflags
|
||||
|
||||
import (
|
||||
"github.com/rclone/rclone/cmd/serve/proxy"
|
||||
"github.com/rclone/rclone/fs/config/flags"
|
||||
"github.com/spf13/pflag"
|
||||
)
|
||||
|
||||
// Options set by command line flags
|
||||
var (
|
||||
Opt = proxy.DefaultOpt
|
||||
)
|
||||
|
||||
// AddFlags adds the non filing system specific flags to the command
|
||||
func AddFlags(flagSet *pflag.FlagSet) {
|
||||
flags.StringVarP(flagSet, &Opt.AuthProxy, "auth-proxy", "", Opt.AuthProxy, "A program to use to create the backend from the auth.")
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue