mirror of
https://github.com/ko-build/ko.git
synced 2025-07-15 23:54:17 +02:00
Add build.Limiter (#79)
* Add build.Limiter You can limit the number of concurrent builds with -j (a la make). The default value for this is GOMAXPROCS, which seems reasonable.
This commit is contained in:
@ -32,9 +32,9 @@ func addCreate(topLevel *cobra.Command) {
|
||||
no := &options.NameOptions{}
|
||||
fo := &options.FilenameOptions{}
|
||||
ta := &options.TagsOptions{}
|
||||
do := &options.DebugOptions{}
|
||||
so := &options.SelectorOptions{}
|
||||
sto := &options.StrictOptions{}
|
||||
bo := &options.BuildOptions{}
|
||||
create := &cobra.Command{
|
||||
Use: "create -f FILENAME",
|
||||
Short: "Create the input files with image references resolved to built/pushed image digests.",
|
||||
@ -64,7 +64,7 @@ func addCreate(topLevel *cobra.Command) {
|
||||
cat config.yaml | ko create -f -`,
|
||||
Args: cobra.NoArgs,
|
||||
Run: func(cmd *cobra.Command, args []string) {
|
||||
builder, err := makeBuilder(do)
|
||||
builder, err := makeBuilder(bo)
|
||||
if err != nil {
|
||||
log.Fatalf("error creating builder: %v", err)
|
||||
}
|
||||
@ -130,9 +130,9 @@ func addCreate(topLevel *cobra.Command) {
|
||||
options.AddNamingArgs(create, no)
|
||||
options.AddFileArg(create, fo)
|
||||
options.AddTagsArg(create, ta)
|
||||
options.AddDebugArg(create, do)
|
||||
options.AddSelectorArg(create, so)
|
||||
options.AddStrictArg(create, sto)
|
||||
options.AddBuildOptions(create, bo)
|
||||
|
||||
// Collect the ko-specific apply flags before registering the kubectl global
|
||||
// flags so that we can ignore them when passing kubectl global flags through
|
||||
|
Reference in New Issue
Block a user