-
Notifications
You must be signed in to change notification settings - Fork 43
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
06b4f0c
commit a55367b
Showing
5 changed files
with
82 additions
and
0 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
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,29 @@ | ||
package spark | ||
|
||
import ( | ||
"github.com/awslabs/eksdemo/pkg/application" | ||
"github.com/awslabs/eksdemo/pkg/cmd" | ||
) | ||
|
||
type Options struct { | ||
application.ApplicationOptions | ||
} | ||
|
||
func newOptions() (options *Options, flags cmd.Flags) { | ||
options = &Options{ | ||
ApplicationOptions: application.ApplicationOptions{ | ||
DefaultVersion: &application.LatestPrevious{ | ||
LatestChart: "2.0.0-rc.0", | ||
Latest: "2.0.0-rc.0", | ||
PreviousChart: "2.0.0-rc.0", | ||
Previous: "2.0.0-rc.0", | ||
}, | ||
Namespace: "spark-operator", | ||
ServiceAccount: "spark-operator-controller", | ||
}, | ||
} | ||
|
||
flags = cmd.Flags{} | ||
|
||
return | ||
} |
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,48 @@ | ||
package spark | ||
|
||
import ( | ||
"github.com/awslabs/eksdemo/pkg/application" | ||
"github.com/awslabs/eksdemo/pkg/cmd" | ||
"github.com/awslabs/eksdemo/pkg/installer" | ||
"github.com/awslabs/eksdemo/pkg/template" | ||
) | ||
|
||
// Docs: https://www.kubeflow.org/docs/components/spark-operator/ | ||
// GitHub: https://github.com/kubeflow/spark-operator | ||
// Helm: https://github.com/kubeflow/spark-operator/tree/master/charts/spark-operator-chart | ||
// Repo: https://hub.docker.com/r/kubeflow/spark-operator/ | ||
// Version: Latest is v2.0.0-rc.0 (as of 9/2/24) | ||
|
||
func NewApp() *application.Application { | ||
options, flags := newOptions() | ||
|
||
return &application.Application{ | ||
Command: cmd.Command{ | ||
Name: "spark-operator", | ||
Description: "Kubeflow Spark Operator", | ||
Aliases: []string{"spark"}, | ||
}, | ||
|
||
Flags: flags, | ||
|
||
Installer: &installer.HelmInstaller{ | ||
ChartName: "spark-operator", | ||
ReleaseName: "spark-operator", | ||
RepositoryURL: "https://kubeflow.github.io/spark-operator", | ||
ValuesTemplate: &template.TextTemplate{ | ||
Template: valuesTemplate, | ||
}, | ||
}, | ||
|
||
Options: options, | ||
} | ||
} | ||
|
||
// https://github.com/kubeflow/spark-operator/blob/master/charts/spark-operator-chart/values.yaml | ||
const valuesTemplate = `--- | ||
image: | ||
tag: {{ .Version }} | ||
controller: | ||
serviceAccount: | ||
name: {{ .ServiceAccount }} | ||
` |