mirror of
https://github.com/zeromicro/go-zero.git
synced 2025-01-24 01:30:25 +08:00
18 lines
315 B
Go
18 lines
315 B
Go
package docker
|
|
|
|
import (
|
|
"errors"
|
|
|
|
"github.com/tal-tech/go-zero/tools/goctl/gen"
|
|
"github.com/urfave/cli"
|
|
)
|
|
|
|
func DockerCommand(c *cli.Context) error {
|
|
goFile := c.String("go")
|
|
if len(goFile) == 0 {
|
|
return errors.New("-go can't be empty")
|
|
}
|
|
|
|
return gen.GenerateDockerfile(goFile, "-f", "etc/config.yaml")
|
|
}
|