mirror of
https://github.com/onepanelio/onepanel.git
synced 2025-10-27 23:31:27 +08:00
use an env var for more flexibility
This commit is contained in:
@@ -5,6 +5,7 @@ import (
|
|||||||
"encoding/json"
|
"encoding/json"
|
||||||
"errors"
|
"errors"
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"github.com/onepanelio/core/pkg/util/env"
|
||||||
"github.com/onepanelio/core/pkg/util/extensions"
|
"github.com/onepanelio/core/pkg/util/extensions"
|
||||||
"github.com/onepanelio/core/pkg/util/ptr"
|
"github.com/onepanelio/core/pkg/util/ptr"
|
||||||
"github.com/onepanelio/core/pkg/util/request"
|
"github.com/onepanelio/core/pkg/util/request"
|
||||||
@@ -1168,7 +1169,7 @@ func (c *Client) GenerateWorkflowTemplateManifest(manifest string) (string, erro
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
return "", err
|
return "", err
|
||||||
}
|
}
|
||||||
legalNodePoolValues := []string{"default"}
|
legalNodePoolValues := []string{env.Get("ONEPANEL_TEMPLATE_NODEPOOL_DEFAULT_VALUE", "default")}
|
||||||
for _, opt := range nodePoolOptions {
|
for _, opt := range nodePoolOptions {
|
||||||
legalNodePoolValues = append(legalNodePoolValues, opt.Value)
|
legalNodePoolValues = append(legalNodePoolValues, opt.Value)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user