Skip to content

Commit 28fe29b

Browse files
kadern0alexellis
authored andcommitted
Added architecture check to allow only x86-64 installations
Signed-off-by: kadernO <kaderno@gmail.com>
1 parent d6bc565 commit 28fe29b

File tree

2 files changed

+14
-0
lines changed

2 files changed

+14
-0
lines changed

cmd/apps/mongodb_app.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,13 @@ func MakeInstallMongoDB() *cobra.Command {
4444

4545
namespace, _ := command.Flags().GetString("namespace")
4646

47+
arch := getNodeArchitecture()
48+
fmt.Printf("Node architecture: %q\n", arch)
49+
50+
if arch != IntelArch {
51+
return fmt.Errorf(`only Intel, i.e. PC architecture is supported for this app`)
52+
}
53+
4754
userPath, err := config.InitUserDir()
4855
if err != nil {
4956
return err

cmd/apps/postgres_app.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,13 @@ func MakeInstallPostgresql() *cobra.Command {
4545

4646
fmt.Printf("Using kubeconfig: %s\n", kubeConfigPath)
4747

48+
arch := getNodeArchitecture()
49+
fmt.Printf("Node architecture: %q\n", arch)
50+
51+
if arch != IntelArch {
52+
return fmt.Errorf(`only Intel, i.e. PC architecture is supported for this app`)
53+
}
54+
4855
userPath, err := config.InitUserDir()
4956
if err != nil {
5057
return err

0 commit comments

Comments
 (0)