mirror of
https://github.com/0rangebananaspy/authelia.git
synced 2024-09-14 22:47:21 +07:00
2acf8bf21c
This reduce the size of the docker image and avoid confusing users. We keep the commands in authelia-scripts too in order to keep the current workflow of developers.
18 lines
406 B
Go
18 lines
406 B
Go
package commands
|
|
|
|
import (
|
|
"fmt"
|
|
|
|
"github.com/authelia/authelia/internal/authentication"
|
|
"github.com/spf13/cobra"
|
|
)
|
|
|
|
var HashPasswordCmd = &cobra.Command{
|
|
Use: "hash-password [password]",
|
|
Short: "Hash a password to be used in file-based users database",
|
|
Run: func(cobraCmd *cobra.Command, args []string) {
|
|
fmt.Println(authentication.HashPassword(args[0], ""))
|
|
},
|
|
Args: cobra.MinimumNArgs(1),
|
|
}
|