mirror of
https://github.com/aptly-dev/aptly.git
synced 2026-01-12 03:21:33 +00:00
Make downloader type configurable
This commit is contained in:
@@ -12,6 +12,7 @@ type ConfigStructure struct { // nolint: maligned
|
||||
DownloadConcurrency int `json:"downloadConcurrency"`
|
||||
DownloadLimit int64 `json:"downloadSpeedLimit"`
|
||||
DownloadRetries int `json:"downloadRetries"`
|
||||
Downloader string `json:"downloader"`
|
||||
DatabaseOpenAttempts int `json:"databaseOpenAttempts"`
|
||||
Architectures []string `json:"architectures"`
|
||||
DepFollowSuggests bool `json:"dependencyFollowSuggests"`
|
||||
@@ -87,6 +88,7 @@ var Config = ConfigStructure{
|
||||
RootDir: filepath.Join(os.Getenv("HOME"), ".aptly"),
|
||||
DownloadConcurrency: 4,
|
||||
DownloadLimit: 0,
|
||||
Downloader: "default",
|
||||
DatabaseOpenAttempts: -1,
|
||||
Architectures: []string{},
|
||||
DepFollowSuggests: false,
|
||||
|
||||
@@ -63,6 +63,7 @@ func (s *ConfigSuite) TestSaveConfig(c *C) {
|
||||
" \"downloadConcurrency\": 5,\n"+
|
||||
" \"downloadSpeedLimit\": 0,\n"+
|
||||
" \"downloadRetries\": 0,\n"+
|
||||
" \"downloader\": \"\",\n"+
|
||||
" \"databaseOpenAttempts\": 5,\n"+
|
||||
" \"architectures\": null,\n"+
|
||||
" \"dependencyFollowSuggests\": false,\n"+
|
||||
|
||||
Reference in New Issue
Block a user