Skip to content

Commit

Permalink
fix: key error
Browse files Browse the repository at this point in the history
  • Loading branch information
yanksyoon committed Jul 4, 2023
1 parent 17985b8 commit b82e003
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -636,13 +636,13 @@ def _wget_install(self, executables: Iterable[WgetExecutable]) -> None:
executable_path = f"/usr/bin/{executable.cmd}"
logger.info("Downloading %s via wget to %s...", executable.url, executable_path)
wget_cmd = ["/usr/bin/wget", executable.url, "-O", executable_path]
if self.config.proxies["http"] or self.config.proxies["https"]:
if self.config.proxies.get("http", None) or self.config.proxies.get("https", None):
wget_cmd += ["-e", "use_proxy=on"]
if self.config.proxies["http"]:
if self.config.proxies.get("http", None):
wget_cmd += ["-e", f"http_proxy={self.config.proxies['http']}"]
if self.config.proxies["https"]:
if self.config.proxies.get("https", None):
wget_cmd += ["-e", f"https_proxy={self.config.proxies['https']}"]
if self.config.proxies["no_proxy"]:
if self.config.proxies.get("no_proxy", None):
wget_cmd += ["-e", f"no_proxy={self.config.proxies['no_proxy']}"]
self.instance.execute(wget_cmd)
self.instance.execute(["/usr/bin/chmod", "+x", executable_path])

0 comments on commit b82e003

Please sign in to comment.