mirror of
https://github.com/openziti/zrok.git
synced 2024-11-22 08:03:49 +01:00
Merge pull request #428 from openziti/reserved_metadata_fix
sdk fixes to re-instate reserved share metadata (#427)
This commit is contained in:
commit
94d17abee6
@ -87,6 +87,7 @@ func (cmd *reserveCommand) run(_ *cobra.Command, args []string) {
|
||||
}
|
||||
|
||||
req := &sdk.ShareRequest{
|
||||
Reserved: true,
|
||||
BackendMode: sdk.BackendMode(cmd.backendMode),
|
||||
ShareMode: shareMode,
|
||||
BasicAuth: cmd.basicAuth,
|
||||
|
@ -20,6 +20,7 @@ const (
|
||||
)
|
||||
|
||||
type ShareRequest struct {
|
||||
Reserved bool
|
||||
BackendMode BackendMode
|
||||
ShareMode ShareMode
|
||||
Target string
|
||||
|
@ -25,6 +25,7 @@ func CreateShare(root env_core.Root, request *ShareRequest) (*Share, error) {
|
||||
default:
|
||||
return nil, errors.Errorf("unknown share mode '%v'", request.ShareMode)
|
||||
}
|
||||
out.Body.Reserved = request.Reserved
|
||||
|
||||
if len(request.BasicAuth) > 0 {
|
||||
out.Body.AuthScheme = string(Basic)
|
||||
|
Loading…
Reference in New Issue
Block a user