Skip to content

Commit

Permalink
feat: add retries to aptly mirror update (#165)
Browse files Browse the repository at this point in the history
  • Loading branch information
rubenruizdegauna authored Feb 3, 2025
1 parent a394093 commit 50b9604
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion publisher/upload/upload.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import (
"net/url"
"os"
"path"
"strconv"
"strings"
"time"

Expand Down Expand Up @@ -345,7 +346,7 @@ func mirrorAPTRepo(conf config.Config, repoUrl string, osVersion string) (err er
utils.Logger.Printf("[✔] Mirror create succesfully APT repo for %s", osVersion)

utils.Logger.Printf("[ ] Mirror update APT repo for %s", osVersion)
if err = utils.ExecLogOutput(utils.Logger, "aptly", commandTimeout, "mirror", "update", "-keyring", conf.GpgKeyRing, "mirror-"+osVersion); err != nil {
if err = utils.ExecLogOutput(utils.Logger, "aptly", commandTimeout, "mirror", "update", "-max-tries", strconv.Itoa(s3Retries), "-keyring", conf.GpgKeyRing, "mirror-"+osVersion); err != nil {
return err
}
utils.Logger.Printf("[✔] Mirror update succesfully APT repo for %s", osVersion)
Expand Down

0 comments on commit 50b9604

Please sign in to comment.