-
Notifications
You must be signed in to change notification settings - Fork 29
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
Showing
9 changed files
with
230 additions
and
46 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 |
---|---|---|
|
@@ -9,6 +9,7 @@ import ( | |
) | ||
|
||
const DEFAULT_CHARTS = "title=Web application template,description=Deploy any web application. Multiple container image build options available.,name=onechart,repo=https://chart.onechart.dev,version=0.70.0;title=static website template,description=If your build generates static files%2C we will host it in an Nginx container.,name=static-site,repo=https://chart.onechart.dev,version=0.70.0" | ||
const DEFAULT_PLAIN_MODULES_URL = "https://github.com/gimlet-io/plain-modules.git" | ||
|
||
// LoadConfig returns the static config from the environment. | ||
func LoadConfig() (*Config, error) { | ||
|
@@ -35,6 +36,9 @@ func defaults(c *Config) { | |
if c.DefaultCharts == nil { | ||
c.DefaultCharts.Decode(DEFAULT_CHARTS) | ||
} | ||
if c.PlainModulesURL == "" { | ||
c.PlainModulesURL = DEFAULT_PLAIN_MODULES_URL | ||
} | ||
if c.GitSSHAddressFormat == "" { | ||
c.GitSSHAddressFormat = "[email protected]:%s.git" | ||
} | ||
|
@@ -118,6 +122,8 @@ type Config struct { | |
|
||
Instance string `envconfig:"INSTANCE"` | ||
License string `envconfig:"LICENSE"` | ||
|
||
PlainModulesURL string `envconfig:"PLAIN_MODULES_URL"` | ||
} | ||
|
||
// Logging provides the logging configuration. | ||
|
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
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.