Skip to content

Commit

Permalink
neofs-cli: container set-eacl removal of the no-precheck flag (#2605)
Browse files Browse the repository at this point in the history
Closes: #2496.
  • Loading branch information
roman-khimov authored Oct 2, 2023
2 parents 6a3cd14 + c00a7da commit c817194
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ Changelog for NeoFS Node
- BoltDB open timeout increased from 100ms to 1s (#2499)

### Removed
- deprecated `no-precheck` flag of `neofs-cli container set-eacl` (#2496)

### Updated
- Update minimal supported Go version up to v1.19 (#2485)
Expand Down
6 changes: 1 addition & 5 deletions cmd/neofs-cli/modules/container/set_eacl.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@ import (
)

var flagVarsSetEACL struct {
noPreCheck bool

srcPath string
}

Expand All @@ -41,7 +39,7 @@ Container ID in EACL table will be substituted with ID from the CLI.`,
pk := key.GetOrGenerate(cmd)
cli := internalclient.GetSDKClientByFlag(ctx, cmd, commonflags.RPC)
force, _ := cmd.Flags().GetBool(commonflags.ForceFlag)
if !(force || flagVarsSetEACL.noPreCheck) {
if !force {
common.PrintVerbose(cmd, "Validating eACL table...")
err := util.ValidateEACLTable(eaclTable)
common.ExitOnErr(cmd, "table validation: %w", err)
Expand Down Expand Up @@ -151,6 +149,4 @@ func initContainerSetEACLCmd() {
flags.BoolVar(&containerAwait, "await", false, fmt.Sprintf("block execution until EACL is persisted. "+
"Increases default execution timeout to %.0fs", awaitTimeout.Seconds())) // simple %s notation prints 1m0s https://github.com/golang/go/issues/39064
flags.BoolP(commonflags.ForceFlag, commonflags.ForceFlagShorthand, false, "skip validation checks (ownership, extensibility of the container ACL)")
flags.BoolVar(&flagVarsSetEACL.noPreCheck, "no-precheck", false, "do not pre-check the extensibility of the container ACL")
_ = flags.MarkDeprecated("no-precheck", "use --force flag instead for skipping validation checks")
}

0 comments on commit c817194

Please sign in to comment.