[#932] adm: Move force-new-epoch to package netmap

Signed-off-by: Anton Nikiforov <an.nikiforov@yadro.com>
This commit is contained in:
Anton Nikiforov 2024-02-01 17:59:53 +03:00
parent ce42547980
commit 9b65f1595a
4 changed files with 33 additions and 31 deletions

View file

@ -98,16 +98,6 @@ var (
},
}
forceNewEpoch = &cobra.Command{
Use: "force-new-epoch",
Short: "Create new FrostFS epoch event in the side chain",
PreRun: func(cmd *cobra.Command, _ []string) {
_ = viper.BindPFlag(util.AlphabetWalletsFlag, cmd.Flags().Lookup(util.AlphabetWalletsFlag))
_ = viper.BindPFlag(util.EndpointFlag, cmd.Flags().Lookup(util.EndpointFlag))
},
RunE: forceNewEpochCmd,
}
dumpContractHashesCmd = &cobra.Command{
Use: "dump-hashes",
Short: "Dump deployed contract hashes",
@ -133,7 +123,7 @@ func init() {
initInitCmd()
initDeployCmd()
initGenerateStorageCmd()
initForceNewEpochCmd()
RootCmd.AddCommand(netmap.ForceNewEpoch)
RootCmd.AddCommand(node.RemoveCmd)
RootCmd.AddCommand(policy.Set)
RootCmd.AddCommand(policy.Dump)
@ -181,13 +171,6 @@ func initDumpContractHashesCmd() {
dumpContractHashesCmd.Flags().String(customZoneFlag, "", "Custom zone to search.")
}
func initForceNewEpochCmd() {
RootCmd.AddCommand(forceNewEpoch)
forceNewEpoch.Flags().String(util.AlphabetWalletsFlag, "", util.AlphabetWalletsFlagDesc)
forceNewEpoch.Flags().StringP(util.EndpointFlag, util.EndpointFlagShort, "", util.EndpointFlagDesc)
forceNewEpoch.Flags().String(util.LocalDumpFlag, "", "Path to the blocks dump file")
}
func initGenerateStorageCmd() {
RootCmd.AddCommand(generateStorageCmd)
generateStorageCmd.Flags().String(util.AlphabetWalletsFlag, "", util.AlphabetWalletsFlagDesc)