-
Notifications
You must be signed in to change notification settings - Fork 36
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added update command. Refactored terraform init. Enabled zone list that allows you to specify node pool zones in the cluster config. Refactored ASM mesh install scripts to take advantage of the Fleets mesh api and use connect gw. Co-authored-by: Nick Eberts <[email protected]>
- Loading branch information
1 parent
333ceec
commit b2904a8
Showing
31 changed files
with
331 additions
and
578 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -100,3 +100,5 @@ cli/*.yaml | |
|
||
# Ignore users' kubeconfigs | ||
*kubeconfig* | ||
|
||
.idea/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
/* | ||
Copyright © 2020 Google Inc. | ||
Licensed under the Apache License, Version 2.0 (the "License"); | ||
you may not use this file except in compliance with the License. | ||
You may obtain a copy of the License at | ||
http://www.apache.org/licenses/LICENSE-2.0 | ||
Unless required by applicable law or agreed to in writing, software | ||
distributed under the License is distributed on an "AS IS" BASIS, | ||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
See the License for the specific language governing permissions and | ||
limitations under the License. | ||
*/ | ||
package cmd | ||
|
||
import ( | ||
"gkekitctl/pkg/config" | ||
"gkekitctl/pkg/lifecycle" | ||
|
||
log "github.com/sirupsen/logrus" | ||
|
||
"github.com/spf13/cobra" | ||
) | ||
|
||
// createCmd represents the create command | ||
var updateCmd = &cobra.Command{ | ||
Use: "update", | ||
Short: "update your gke toolkit environment", | ||
Example: `gkekitctl update --config <file.yaml>`, | ||
Run: func(cmd *cobra.Command, args []string) { | ||
log.Info("👟 Started config validation...") | ||
conf := config.InitConf(cfgFile) | ||
log.Info("👟 Started generating TFVars...") | ||
|
||
config.GenerateTfvars(conf) | ||
|
||
if conf.VpcConfig.VpcType == "shared" { | ||
lifecycle.InitTF("shared_vpc") | ||
lifecycle.ApplyTF("shared_vpc") | ||
} | ||
lifecycle.InitTF("cluster_build") | ||
lifecycle.ApplyTF("cluster_build") | ||
}, | ||
} | ||
|
||
func init() { | ||
rootCmd.AddCommand(updateCmd) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.