github.com/tilotech/tilores-cli@v0.28.0/cmd/plan.go (about)

     1  package cmd
     2  
     3  import (
     4  	"github.com/spf13/cobra"
     5  )
     6  
     7  // planCmd represents the plan command
     8  var planCmd = &cobra.Command{
     9  	Use:   "plan",
    10  	Short: "Plans the " + applicationName + " deployment for your own AWS account.",
    11  	Long:  `Plans the ` + applicationName + ` deployment for your own AWS account.`,
    12  	Run: func(_ *cobra.Command, _ []string) {
    13  		err := deployTiloRes(false)
    14  		cobra.CheckErr(err)
    15  	},
    16  }
    17  
    18  func init() {
    19  	rootCmd.AddCommand(planCmd)
    20  
    21  	planCmd.PersistentFlags().StringVar(&region, "region", "", "The deployments AWS region.")
    22  	_ = planCmd.MarkPersistentFlagRequired("region")
    23  
    24  	planCmd.PersistentFlags().StringVar(&profile, "profile", "", "The AWS credentials profile.")
    25  
    26  	planCmd.PersistentFlags().StringVar(&workspace, "workspace", "default", "The deployments workspace/environment e.g. dev, prod.")
    27  
    28  	planCmd.PersistentFlags().StringVar(&varFile, "var-file", "", "The path to the file that holds the values for terraform variables")
    29  }