mirror of
https://github.com/aptly-dev/aptly.git
synced 2026-06-06 05:30:57 +00:00
make serving published repos in api mode configurable
This commit is contained in:
committed by
Benj Fassbind
parent
f74217ed9c
commit
0fdba29d51
@@ -37,6 +37,7 @@ type ConfigStructure struct { // nolint: maligned
|
||||
EnableMetricsEndpoint bool `json:"enableMetricsEndpoint"`
|
||||
LogLevel string `json:"logLevel"`
|
||||
LogFormat string `json:"logFormat"`
|
||||
ServeInAPIMode bool `json:"serveInAPIMode"`
|
||||
}
|
||||
|
||||
// FileSystemPublishRoot describes single filesystem publishing entry point
|
||||
@@ -116,6 +117,7 @@ var Config = ConfigStructure{
|
||||
EnableMetricsEndpoint: false,
|
||||
LogLevel: "debug",
|
||||
LogFormat: "default",
|
||||
ServeInAPIMode: false,
|
||||
}
|
||||
|
||||
// LoadConfig loads configuration from json file
|
||||
|
||||
@@ -136,7 +136,8 @@ func (s *ConfigSuite) TestSaveConfig(c *C) {
|
||||
" \"AsyncAPI\": false,\n"+
|
||||
" \"enableMetricsEndpoint\": false,\n"+
|
||||
" \"logLevel\": \"info\",\n"+
|
||||
" \"logFormat\": \"json\"\n"+
|
||||
" \"logFormat\": \"json\",\n"+
|
||||
" \"serveInAPIMode\": false\n"+
|
||||
"}")
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user