MagicStack / MagicStack/vmbench
proxy settings
Open
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 189
- Forks
- 48
- PR merge metrics
- No merged PRs in 30d
Description
I had hard times configuring Docker for corporate proxy. It looks like there is just no way to do it externally w.r.t. your Dockerfile, so I had to modify it with the following patch:
diff --git a/Dockerfile b/Dockerfile
index c9a3022..e8a95ef 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,6 +1,9 @@
FROM ubuntu:16.04
MAINTAINER elvis@magic.io
-
+ARG http_proxy
+ENV http_proxy=$http_proxy
+ARG https_proxy
+ENV https_proxy=$https_proxy
RUN DEBIAN_FRONTEND=noninteractive \
apt-get update && apt-get install -y \
language-pack-en
diff --git a/build.sh b/build.sh
index 8e128c7..88957b9 100755
--- a/build.sh
+++ b/build.sh
@@ -1,3 +1,3 @@
#!/bin/bash
-docker build -t magic/benchmark $(dirname $0)
+docker build --build-arg http_proxy="$http_proxy" --build-arg https_proxy="$https_proxy" -t magic/benchmark $(dirname $0)
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with Dockerfile and build.sh, then inspect the existing docker build command and how its build context is assembled. Confirm that proxy settings can be supplied externally during the image build without editing Dockerfile, and verify the image still builds successfully when proxy variables are available.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- bash, docker
- Domain
- build-system, devops
- Issue type
- Feature
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 48/100