diff --git a/cmd/get.go b/cmd/get.go index 33126dc3..8e378078 100644 --- a/cmd/get.go +++ b/cmd/get.go @@ -69,27 +69,27 @@ var getProjectCmd = &cobra.Command{ return nil } - DevEnvironments := 0 + devEnvironments := 0 productionRoute := "" - deploymentsDisabled, err := strconv.ParseBool(strconv.Itoa(int(project.DeploymentsDisabled))) + deploymentsDisabled, err := strconv.ParseBool(strconv.Itoa(int(*project.DeploymentsDisabled))) if err != nil { return err } - autoIdle, err := strconv.ParseBool(strconv.Itoa(int(project.AutoIdle))) + autoIdle, err := strconv.ParseBool(strconv.Itoa(int(*project.AutoIdle))) if err != nil { return err } - factsUI, err := strconv.ParseBool(strconv.Itoa(int(project.FactsUI))) + factsUI, err := strconv.ParseBool(strconv.Itoa(int(*project.FactsUI))) if err != nil { return err } - problemsUI, err := strconv.ParseBool(strconv.Itoa(int(project.ProblemsUI))) + problemsUI, err := strconv.ParseBool(strconv.Itoa(int(*project.ProblemsUI))) if err != nil { return err } for _, environment := range project.Environments { if environment.EnvironmentType == "development" { - DevEnvironments++ + devEnvironments++ } if environment.EnvironmentType == "production" { productionRoute = environment.Route @@ -102,7 +102,7 @@ var getProjectCmd = &cobra.Command{ returnNonEmptyString(fmt.Sprintf("%v", project.GitURL)), returnNonEmptyString(fmt.Sprintf("%v", project.ProductionEnvironment)), returnNonEmptyString(fmt.Sprintf("%v", productionRoute)), - returnNonEmptyString(fmt.Sprintf("%v/%v", DevEnvironments, project.DevelopmentEnvironmentsLimit)), + returnNonEmptyString(fmt.Sprintf("%v/%v", devEnvironments, *project.DevelopmentEnvironmentsLimit)), } projHeader := []string{"ID", "ProjectName", "GitUrl", "ProductionEnvironment", "ProductionRoute", "DevEnvironments"} if wide { diff --git a/cmd/list.go b/cmd/list.go index d08bc247..c20f0817 100644 --- a/cmd/list.go +++ b/cmd/list.go @@ -39,6 +39,10 @@ var listProjectsCmd = &cobra.Command{ if err != nil { return err } + // wide, err := cmd.Flags().GetBool("wide") + // if err != nil { + // return err + // } current := lagoonCLIConfig.Current token := lagoonCLIConfig.Lagoons[current].Token lc := lclient.New( @@ -65,21 +69,40 @@ var listProjectsCmd = &cobra.Command{ productionRoute = environment.Route } } - - data = append(data, []string{ + projData := []string{ returnNonEmptyString(fmt.Sprintf("%d", project.ID)), returnNonEmptyString(fmt.Sprintf("%v", project.Name)), returnNonEmptyString(fmt.Sprintf("%v", project.GitURL)), returnNonEmptyString(fmt.Sprintf("%v", project.ProductionEnvironment)), returnNonEmptyString(fmt.Sprintf("%v", productionRoute)), - returnNonEmptyString(fmt.Sprintf("%v/%v", devEnvironments, project.DevelopmentEnvironmentsLimit)), - }) + returnNonEmptyString(fmt.Sprintf("%v/%v", devEnvironments, *project.DevelopmentEnvironmentsLimit)), + } + // if wide { + // projData = append(projData, returnNonEmptyString(fmt.Sprintf("%v", project.AutoIdle))) + // projData = append(projData, returnNonEmptyString(fmt.Sprintf("%v", project.Branches))) + // projData = append(projData, returnNonEmptyString(fmt.Sprintf("%v", project.PullRequests))) + // projData = append(projData, returnNonEmptyString(fmt.Sprintf("%v", project.RouterPattern))) + // projData = append(projData, returnNonEmptyString(fmt.Sprintf("%v", project.FactsUI))) + // projData = append(projData, returnNonEmptyString(fmt.Sprintf("%v", project.ProblemsUI))) + // projData = append(projData, returnNonEmptyString(fmt.Sprintf("%v", project.DeploymentsDisabled))) + // } + data = append(data, projData) } if len(data) == 0 { outputOptions.Error = "No access to any projects in Lagoon\n" } + projHeader := []string{"ID", "ProjectName", "GitUrl", "ProductionEnvironment", "ProductionRoute", "DevEnvironments"} + // if wide { + // projHeader = append(projHeader, "AutoIdle") + // projHeader = append(projHeader, "Branches") + // projHeader = append(projHeader, "PullRequests") + // projHeader = append(projHeader, "RouterPattern") + // projHeader = append(projHeader, "FactsUI") + // projHeader = append(projHeader, "ProblemsUI") + // projHeader = append(projHeader, "DeploymentsDisabled") + // } dataMain := output.Table{ - Header: []string{"ID", "ProjectName", "GitUrl", "ProductionEnvironment", "ProductionRoute", "DevEnvironments"}, + Header: projHeader, Data: data, } r := output.RenderOutput(dataMain, outputOptions) @@ -101,6 +124,14 @@ var listDeployTargetsCmd = &cobra.Command{ if err != nil { return err } + wide, err := cmd.Flags().GetBool("wide") + if err != nil { + return err + } + showToken, err := cmd.Flags().GetBool("show-token") + if err != nil { + return err + } current := lagoonCLIConfig.Current token := lagoonCLIConfig.Lagoons[current].Token lc := lclient.New( @@ -115,40 +146,50 @@ var listDeployTargetsCmd = &cobra.Command{ } data := []output.Data{} for _, deploytarget := range *deploytargets { - data = append(data, []string{ + depTarget := []string{ returnNonEmptyString(fmt.Sprintf("%v", deploytarget.ID)), returnNonEmptyString(fmt.Sprintf("%v", deploytarget.Name)), - returnNonEmptyString(fmt.Sprintf("%v", deploytarget.ConsoleURL)), - returnNonEmptyString(fmt.Sprintf("%v", deploytarget.BuildImage)), - returnNonEmptyString(fmt.Sprintf("%v", deploytarget.Token)), + returnNonEmptyString(fmt.Sprintf("%v", deploytarget.RouterPattern)), returnNonEmptyString(fmt.Sprintf("%v", deploytarget.SSHHost)), returnNonEmptyString(fmt.Sprintf("%v", deploytarget.SSHPort)), - returnNonEmptyString(fmt.Sprintf("%v", deploytarget.CloudRegion)), - returnNonEmptyString(fmt.Sprintf("%v", deploytarget.CloudProvider)), - returnNonEmptyString(fmt.Sprintf("%v", deploytarget.FriendlyName)), - returnNonEmptyString(fmt.Sprintf("%v", deploytarget.RouterPattern)), - returnNonEmptyString(fmt.Sprintf("%v", deploytarget.Created)), - returnNonEmptyString(fmt.Sprintf("%v", deploytarget.MonitoringConfig)), - }) + returnNonEmptyString(fmt.Sprintf("%v", deploytarget.BuildImage)), + returnNonEmptyString(fmt.Sprintf("%v", deploytarget.ConsoleURL)), + } + if wide { + depTarget = append(depTarget, returnNonEmptyString(fmt.Sprintf("%v", deploytarget.CloudRegion))) + depTarget = append(depTarget, returnNonEmptyString(fmt.Sprintf("%v", deploytarget.CloudProvider))) + depTarget = append(depTarget, returnNonEmptyString(fmt.Sprintf("%v", deploytarget.FriendlyName))) + depTarget = append(depTarget, returnNonEmptyString(fmt.Sprintf("%v", deploytarget.MonitoringConfig))) + depTarget = append(depTarget, returnNonEmptyString(fmt.Sprintf("%v", deploytarget.Created))) + } + if showToken { + depTarget = append(depTarget, returnNonEmptyString(fmt.Sprintf("%v", deploytarget.Token))) + } + data = append(data, depTarget) } outputOptions.MultiLine = true + header := []string{ + "ID", + "Name", + "RouterPattern", + "SshHost", + "SshPort", + "BuildImage", + "ConsoleUrl", + } + if wide { + header = append(header, "CloudRegion") + header = append(header, "CloudProvider") + header = append(header, "FriendlyName") + header = append(header, "MonitoringConfig") + header = append(header, "Created") + } + if showToken { + header = append(header, "Token") + } r := output.RenderOutput(output.Table{ - Header: []string{ - "ID", - "Name", - "ConsoleUrl", - "BuildImage", - "Token", - "SshHost", - "SshPort", - "CloudRegion", - "CloudProvider", - "FriendlyName", - "RouterPattern", - "Created", - "MonitoringConfig", - }, - Data: data, + Header: header, + Data: data, }, outputOptions) fmt.Fprintf(cmd.OutOrStdout(), "%s", r) return nil @@ -1149,6 +1190,9 @@ var ListOrganizationAdminsCmd = &cobra.Command{ if user.Owner { role = "owner" } + if user.Admin { + role = "admin" + } data = append(data, []string{ returnNonEmptyString(user.ID.String()), returnNonEmptyString(user.Email), @@ -1253,4 +1297,8 @@ func init() { listOrganizationGroupsCmd.Flags().StringP("organization-name", "O", "", "Name of the organization to list associated groups for") listOrganizationDeployTargetsCmd.Flags().StringP("organization-name", "O", "", "Name of the organization to list associated deploy targets for") listOrganizationDeployTargetsCmd.Flags().Uint("id", 0, "ID of the organization to list associated deploy targets for") + listDeployTargetsCmd.Flags().Bool("wide", false, "Display additional information about deploytargets") + listDeployTargetsCmd.Flags().Bool("show-token", false, "Display the token for deploytargets") + // TODO: support wide on list projects (machinery update required to add additional fields to all projects query) + // listProjectsCmd.Flags().Bool("wide", false, "Display additional information about projects") } diff --git a/cmd/project.go b/cmd/project.go index 5d01dd48..fe64dd40 100644 --- a/cmd/project.go +++ b/cmd/project.go @@ -111,14 +111,17 @@ var addProjectCmd = &cobra.Command{ if err != nil { return err } - storageCalc, err := cmd.Flags().GetUint("storage-calc") + developmentEnvironmentsLimitProvided := cmd.Flags().Lookup("development-environments-limit").Changed + storageCalc, err := cmd.Flags().GetBool("storage-calc") if err != nil { return err } - autoIdle, err := cmd.Flags().GetUint("auto-idle") + storageCalcProvided := cmd.Flags().Lookup("storage-calc").Changed + autoIdle, err := cmd.Flags().GetBool("auto-idle") if err != nil { return err } + autoIdleProvided := cmd.Flags().Lookup("auto-idle").Changed subfolder, err := cmd.Flags().GetString("subfolder") if err != nil { return err @@ -135,6 +138,7 @@ var addProjectCmd = &cobra.Command{ if err != nil { return err } + orgOwnerProvided := cmd.Flags().Lookup("owner").Changed routerPattern, err := cmd.Flags().GetString("router-pattern") if err != nil { return err @@ -155,7 +159,6 @@ var addProjectCmd = &cobra.Command{ projectInput := schema.AddProjectInput{ Name: cmdProjectName, - AddOrgOwner: orgOwner, GitURL: gitUrl, ProductionEnvironment: productionEnvironment, StandbyProductionEnvironment: standbyProductionEnvironment, @@ -163,17 +166,26 @@ var addProjectCmd = &cobra.Command{ PullRequests: pullrequests, OpenshiftProjectPattern: deploytargetProjectPattern, Openshift: deploytarget, - DevelopmentEnvironmentsLimit: developmentEnvironmentsLimit, - StorageCalc: storageCalc, - AutoIdle: autoIdle, Subfolder: subfolder, PrivateKey: privateKey, BuildImage: buildImage, RouterPattern: routerPattern, } + if orgOwnerProvided { + projectInput.AddOrgOwner = &orgOwner + } + if storageCalcProvided { + projectInput.StorageCalc = nullBoolToUint(storageCalc) + } + if autoIdleProvided { + projectInput.AutoIdle = nullBoolToUint(autoIdle) + } + if developmentEnvironmentsLimitProvided { + projectInput.DevelopmentEnvironmentsLimit = nullUintCheck(developmentEnvironmentsLimit) + } // if organizationid is provided, use it over the name if organizationID != 0 { - projectInput.Organization = organizationID + projectInput.Organization = &organizationID } // otherwise if name is provided use it if organizationName != "" && organizationID == 0 { @@ -186,7 +198,7 @@ var addProjectCmd = &cobra.Command{ if organization.Name == "" { return fmt.Errorf("error querying organization by name") } - projectInput.Organization = organization.ID + projectInput.Organization = &organization.ID } project := schema.Project{} @@ -255,14 +267,16 @@ var updateProjectCmd = &cobra.Command{ return err } developmentEnvironmentsLimit, err := cmd.Flags().GetUint("development-environments-limit") + developmentEnvironmentsLimitProvided := cmd.Flags().Lookup("development-environments-limit").Changed if err != nil { return err } - storageCalc, err := cmd.Flags().GetUint("storage-calc") + storageCalc, err := cmd.Flags().GetBool("storage-calc") if err != nil { return err } - autoIdle, err := cmd.Flags().GetUint("auto-idle") + storageCalcProvided := cmd.Flags().Lookup("storage-calc").Changed + autoIdle, err := cmd.Flags().GetBool("auto-idle") if err != nil { return err } @@ -284,12 +298,12 @@ var updateProjectCmd = &cobra.Command{ if err != nil { return err } - factsUi, err := cmd.Flags().GetUint("facts-ui") + factsUi, err := cmd.Flags().GetBool("facts-ui") if err != nil { return err } factsUIProvided := cmd.Flags().Lookup("facts-ui").Changed - problemsUi, err := cmd.Flags().GetUint("problems-ui") + problemsUi, err := cmd.Flags().GetBool("problems-ui") if err != nil { return err } @@ -298,19 +312,21 @@ var updateProjectCmd = &cobra.Command{ if err != nil { return err } - deploymentsDisabled, err := cmd.Flags().GetUint("deployments-disabled") + deploymentsDisabled, err := cmd.Flags().GetBool("deployments-disabled") if err != nil { return err } deploymentsDisabledProvided := cmd.Flags().Lookup("deployments-disabled").Changed - ProductionBuildPriority, err := cmd.Flags().GetUint("production-build-priority") + productionBuildPriority, err := cmd.Flags().GetUint("production-build-priority") if err != nil { return err } - DevelopmentBuildPriority, err := cmd.Flags().GetUint("development-build-priority") + productionBuildPriorityProvided := cmd.Flags().Lookup("production-build-priority").Changed + developmentBuildPriority, err := cmd.Flags().GetUint("development-build-priority") if err != nil { return err } + developmentBuildPriorityProvided := cmd.Flags().Lookup("development-build-priority").Changed if err := requiredInputCheck("Project name", cmdProjectName); err != nil { return err @@ -333,17 +349,9 @@ var updateProjectCmd = &cobra.Command{ Branches: nullStrCheck(branches), Pullrequests: nullStrCheck(pullrequests), OpenshiftProjectPattern: nullStrCheck(deploytargetProjectPattern), - DevelopmentEnvironmentsLimit: nullUintCheck(developmentEnvironmentsLimit), - StorageCalc: nullUintCheck(storageCalc), - AutoIdle: nullUintCheck(autoIdle), Subfolder: nullStrCheck(subfolder), PrivateKey: nullStrCheck(privateKey), - FactsUI: nullUintCheck(factsUi), - ProblemsUI: nullUintCheck(problemsUi), RouterPattern: nullStrCheck(routerPattern), - DeploymentsDisabled: nullUintCheck(deploymentsDisabled), - ProductionBuildPriority: nullUintCheck(ProductionBuildPriority), - DevelopmentBuildPriority: nullUintCheck(DevelopmentBuildPriority), Name: nullStrCheck(projectName), } @@ -351,17 +359,29 @@ var updateProjectCmd = &cobra.Command{ ProjectAvailability := schema.ProjectAvailability(strings.ToUpper(availability)) projectPatch.Availability = &ProjectAvailability } + if storageCalcProvided { + projectPatch.StorageCalc = nullBoolToUint(storageCalc) + } if autoIdleProvided { - projectPatch.AutoIdle = &autoIdle + projectPatch.AutoIdle = nullBoolToUint(autoIdle) } if deploymentsDisabledProvided { - projectPatch.DeploymentsDisabled = &deploymentsDisabled + projectPatch.DeploymentsDisabled = nullBoolToUint(deploymentsDisabled) } if factsUIProvided { - projectPatch.FactsUI = &factsUi + projectPatch.FactsUI = nullBoolToUint(factsUi) } if problemsUIProvided { - projectPatch.ProblemsUI = &problemsUi + projectPatch.ProblemsUI = nullBoolToUint(problemsUi) + } + if productionBuildPriorityProvided { + projectPatch.ProductionBuildPriority = nullUintCheck(productionBuildPriority) + } + if developmentBuildPriorityProvided { + projectPatch.DevelopmentBuildPriority = nullUintCheck(developmentBuildPriority) + } + if developmentEnvironmentsLimitProvided { + projectPatch.DevelopmentEnvironmentsLimit = nullUintCheck(developmentEnvironmentsLimit) } if buildImageProvided { if buildImage == "null" { @@ -727,14 +747,14 @@ func init() { updateProjectCmd.Flags().Uint("production-build-priority", 0, "Set the priority of the production build") updateProjectCmd.Flags().Uint("development-build-priority", 0, "Set the priority of the development build") - updateProjectCmd.Flags().UintP("auto-idle", "a", 0, "Auto idle setting of the project") - updateProjectCmd.Flags().UintP("storage-calc", "C", 0, "Should storage for this environment be calculated") + updateProjectCmd.Flags().BoolP("auto-idle", "a", false, "Auto idle setting of the project. Set to enable, --auto-idle=false to disable") + updateProjectCmd.Flags().BoolP("storage-calc", "C", false, "Should storage for this environment be calculated. Set to enable, --storage-calc=false to disable") updateProjectCmd.Flags().UintP("development-environments-limit", "L", 0, "How many environments can be deployed at one time") updateProjectCmd.Flags().UintP("deploytarget", "S", 0, "Reference to Deploytarget(Kubernetes) this Project should be deployed to") - updateProjectCmd.Flags().UintP("deployments-disabled", "", 0, "Admin only flag for disabling deployments on a project, 1 to disable deployments, 0 to enable") + updateProjectCmd.Flags().BoolP("deployments-disabled", "", false, "Admin only flag for disabling deployments on a project. Set to disable deployments, --deployments-disabled=false to enable") - updateProjectCmd.Flags().UintP("facts-ui", "", 0, "Enables the Lagoon insights Facts tab in the UI. Set to 1 to enable, 0 to disable") - updateProjectCmd.Flags().UintP("problems-ui", "", 0, "Enables the Lagoon insights Problems tab in the UI. Set to 1 to enable, 0 to disable") + updateProjectCmd.Flags().BoolP("facts-ui", "", false, "Enables the Lagoon insights Facts tab in the UI. Set to enable, --facts-ui=false to disable") + updateProjectCmd.Flags().BoolP("problems-ui", "", false, "Enables the Lagoon insights Problems tab in the UI. Set to enable, --problems-ui=false to disable") addProjectCmd.Flags().StringP("json", "j", "", "JSON string to patch") @@ -748,8 +768,8 @@ func init() { addProjectCmd.Flags().String("standby-production-environment", "", "Which environment(the name) should be marked as the standby production environment") addProjectCmd.Flags().StringP("deploytarget-project-pattern", "", "", "Pattern of Deploytarget(Kubernetes) Project/Namespace that should be generated") - addProjectCmd.Flags().UintP("auto-idle", "a", 0, "Auto idle setting of the project") - addProjectCmd.Flags().UintP("storage-calc", "C", 0, "Should storage for this environment be calculated") + addProjectCmd.Flags().BoolP("auto-idle", "a", false, "Auto idle setting of the project. Set to enable, --auto-idle=false to disable") + addProjectCmd.Flags().BoolP("storage-calc", "C", false, "Should storage for this environment be calculated. Set to enable, --storage-calc=false to disable") addProjectCmd.Flags().UintP("development-environments-limit", "L", 0, "How many environments can be deployed at one time") addProjectCmd.Flags().UintP("deploytarget", "S", 0, "Reference to Deploytarget(Kubernetes) target this Project should be deployed to") addProjectCmd.Flags().StringP("build-image", "", "", "Build Image for the project") diff --git a/cmd/shared.go b/cmd/shared.go index 2cc479d1..a81c72a4 100644 --- a/cmd/shared.go +++ b/cmd/shared.go @@ -80,6 +80,14 @@ func nullUintCheck(i uint) *uint { return &i } +func nullBoolToUint(b bool) *uint { + t := uint(0) + if b { + t = uint(1) + } + return &t +} + func nullIntCheck(i int) *int { if i == 0 { return nil diff --git a/cmd/users.go b/cmd/users.go index 73baaa7a..71ef3cf7 100644 --- a/cmd/users.go +++ b/cmd/users.go @@ -538,10 +538,12 @@ var addAdministratorToOrganizationCmd = &cobra.Command{ } switch strings.ToLower(role) { case "viewer": + case "admin": + userInput.Admin = true case "owner": userInput.Owner = true default: - return fmt.Errorf(`role '%s' is not valid - valid roles include "viewer", "owner"`, role) + return fmt.Errorf(`role '%s' is not valid - valid roles include "viewer", "admin", or "owner"`, role) } current := lagoonCLIConfig.Current @@ -717,7 +719,7 @@ func init() { getAllUserKeysCmd.Flags().StringP("name", "N", "", "Name of the group to list users in (if not specified, will default to all groups)") addAdministratorToOrganizationCmd.Flags().StringP("organization-name", "O", "", "Name of the organization") addAdministratorToOrganizationCmd.Flags().StringP("email", "E", "", "Email address of the user") - addAdministratorToOrganizationCmd.Flags().StringP("role", "R", "", "Role in the organization [owner, viewer]") + addAdministratorToOrganizationCmd.Flags().StringP("role", "R", "", "Role in the organization [owner, admin, viewer]") removeAdministratorFromOrganizationCmd.Flags().StringP("organization-name", "O", "", "Name of the organization") removeAdministratorFromOrganizationCmd.Flags().StringP("email", "E", "", "Email address of the user") resetPasswordCmd.Flags().StringP("email", "E", "", "Email address of the user") diff --git a/docs/commands/lagoon_add_organization-administrator.md b/docs/commands/lagoon_add_organization-administrator.md index 18088df3..27877aff 100644 --- a/docs/commands/lagoon_add_organization-administrator.md +++ b/docs/commands/lagoon_add_organization-administrator.md @@ -16,7 +16,7 @@ lagoon add organization-administrator [flags] -E, --email string Email address of the user -h, --help help for organization-administrator -O, --organization-name string Name of the organization - -R, --role string Role in the organization [owner, viewer] + -R, --role string Role in the organization [owner, admin, viewer] ``` ### Options inherited from parent commands diff --git a/docs/commands/lagoon_add_project.md b/docs/commands/lagoon_add_project.md index d2e40342..6e6c2edd 100644 --- a/docs/commands/lagoon_add_project.md +++ b/docs/commands/lagoon_add_project.md @@ -14,7 +14,7 @@ lagoon add project [flags] ### Options ``` - -a, --auto-idle uint Auto idle setting of the project + -a, --auto-idle Auto idle setting of the project. Set to enable, --auto-idle=false to disable -b, --branches string Which branches should be deployed --build-image string Build Image for the project -S, --deploytarget uint Reference to Deploytarget(Kubernetes) target this Project should be deployed to @@ -31,7 +31,7 @@ lagoon add project [flags] -m, --pullrequests string Which Pull Requests should be deployed -Z, --router-pattern string Router pattern of the project, e.g. '${service}-${environment}-${project}.lagoon.example.com' --standby-production-environment string Which environment(the name) should be marked as the standby production environment - -C, --storage-calc uint Should storage for this environment be calculated + -C, --storage-calc Should storage for this environment be calculated. Set to enable, --storage-calc=false to disable -s, --subfolder string Set if the .lagoon.yml should be found in a subfolder useful if you have multiple Lagoon projects per Git Repository ``` diff --git a/docs/commands/lagoon_list_deploytargets.md b/docs/commands/lagoon_list_deploytargets.md index f4e63cd5..2ac14656 100644 --- a/docs/commands/lagoon_list_deploytargets.md +++ b/docs/commands/lagoon_list_deploytargets.md @@ -13,7 +13,9 @@ lagoon list deploytargets [flags] ### Options ``` - -h, --help help for deploytargets + -h, --help help for deploytargets + --show-token Display the token for deploytargets + --wide Display additional information about deploytargets ``` ### Options inherited from parent commands diff --git a/docs/commands/lagoon_update_project.md b/docs/commands/lagoon_update_project.md index 7ab9897a..6bc62033 100644 --- a/docs/commands/lagoon_update_project.md +++ b/docs/commands/lagoon_update_project.md @@ -9,28 +9,28 @@ lagoon update project [flags] ### Options ``` - -a, --auto-idle uint Auto idle setting of the project + -a, --auto-idle Auto idle setting of the project. Set to enable, --auto-idle=false to disable --availability string Availability of the project -b, --branches string Which branches should be deployed --build-image string Build Image for the project. Set to 'null' to remove the build image - --deployments-disabled uint Admin only flag for disabling deployments on a project, 1 to disable deployments, 0 to enable + --deployments-disabled Admin only flag for disabling deployments on a project. Set to disable deployments, --deployments-disabled=false to enable -S, --deploytarget uint Reference to Deploytarget(Kubernetes) this Project should be deployed to -o, --deploytarget-project-pattern string Pattern of Deploytarget(Kubernetes) Project/Namespace that should be generated --development-build-priority uint Set the priority of the development build -L, --development-environments-limit uint How many environments can be deployed at one time - --facts-ui uint Enables the Lagoon insights Facts tab in the UI. Set to 1 to enable, 0 to disable + --facts-ui Enables the Lagoon insights Facts tab in the UI. Set to enable, --facts-ui=false to disable -g, --git-url string GitURL of the project -h, --help help for project -j, --json string JSON string to patch -N, --name string Change the name of the project by specifying a new name (careful!) -I, --private-key string Private key to use for the project - --problems-ui uint Enables the Lagoon insights Problems tab in the UI. Set to 1 to enable, 0 to disable + --problems-ui Enables the Lagoon insights Problems tab in the UI. Set to enable, --problems-ui=false to disable --production-build-priority uint Set the priority of the production build -E, --production-environment string Which environment(the name) should be marked as the production environment -m, --pullrequests string Which Pull Requests should be deployed -Z, --router-pattern string Router pattern of the project, e.g. '${service}-${environment}-${project}.lagoon.example.com' --standby-production-environment string Which environment(the name) should be marked as the standby production environment - -C, --storage-calc uint Should storage for this environment be calculated + -C, --storage-calc Should storage for this environment be calculated. Set to enable, --storage-calc=false to disable -s, --subfolder string Set if the .lagoon.yml should be found in a subfolder useful if you have multiple Lagoon projects per Git Repository ``` diff --git a/go.mod b/go.mod index 08505142..37f103f8 100644 --- a/go.mod +++ b/go.mod @@ -19,7 +19,7 @@ require ( github.com/spf13/cobra v1.8.0 github.com/spf13/pflag v1.0.5 github.com/stretchr/testify v1.8.2 - github.com/uselagoon/machinery v0.0.24 + github.com/uselagoon/machinery v0.0.27 golang.org/x/crypto v0.21.0 golang.org/x/term v0.18.0 gopkg.in/yaml.v3 v3.0.1 diff --git a/go.sum b/go.sum index cf04cbec..6b01b7af 100644 --- a/go.sum +++ b/go.sum @@ -66,8 +66,8 @@ github.com/stretchr/testify v1.7.4/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= github.com/stretchr/testify v1.8.2 h1:+h33VjcLVPDHtOdpUCuF+7gSuG3yGIftsP1YvFihtJ8= github.com/stretchr/testify v1.8.2/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= -github.com/uselagoon/machinery v0.0.24 h1:Kea7eQiwqrlF1NnG4YmV5dMNM1NxuhiY1vhoahEFkQA= -github.com/uselagoon/machinery v0.0.24/go.mod h1:NbgtEofjK2XY0iUpk9aMYazIo+W/NI56+UF72jv8zVY= +github.com/uselagoon/machinery v0.0.27 h1:luIrdAiVhCPgxAwh2gtPm5iepMnXyTR6sNbuLuBhk80= +github.com/uselagoon/machinery v0.0.27/go.mod h1:NbgtEofjK2XY0iUpk9aMYazIo+W/NI56+UF72jv8zVY= github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=