Update dagger new
cmd to specify architecture when creating an environment
Signed-off-by: Tom Chauveau <tom.chauveau@epitech.eu>
This commit is contained in:
@@ -34,7 +34,7 @@ var newCmd = &cobra.Command{
|
||||
|
||||
st, err := project.Create(ctx, name, state.Plan{
|
||||
Package: viper.GetString("package"),
|
||||
})
|
||||
}, viper.GetString("architecture"))
|
||||
|
||||
if err != nil {
|
||||
lg.Fatal().Err(err).Msg("failed to create environment")
|
||||
@@ -46,6 +46,7 @@ var newCmd = &cobra.Command{
|
||||
|
||||
func init() {
|
||||
newCmd.Flags().StringP("package", "p", "", "references the name of the Cue package within the module to use as a plan. Default: defer to cue loader")
|
||||
newCmd.Flags().StringP("architecture", "a", "", "architecture of the running pipeline. Default: host architecture")
|
||||
if err := viper.BindPFlags(newCmd.Flags()); err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
Reference in New Issue
Block a user