Merge branch '1.0'
Conflicts: proxy/common.go weave
This commit is contained in:
commit
9a4bbb55da
2 files changed
+9
-1
No files matched your search
+8
-1
@@ -6,6 +6,7 @@ import (
|
|||||||
"fmt"
|
"fmt"
|
||||||
"io/ioutil"
|
"io/ioutil"
|
||||||
"net/http"
|
"net/http"
|
||||||
|
"os"
|
||||||
"os/exec"
|
"os/exec"
|
||||||
"regexp"
|
"regexp"
|
||||||
|
|
||||||
@@ -22,7 +23,13 @@ func callWeave(args ...string) ([]byte, []byte, error) {
|
|||||||
args = append([]string{"--local"}, args...)
|
args = append([]string{"--local"}, args...)
|
||||||
Log.Debug("Calling weave", args)
|
Log.Debug("Calling weave", args)
|
||||||
cmd := exec.Command("./weave", args...)
|
cmd := exec.Command("./weave", args...)
|
||||||
cmd.Env = []string{"PROCFS=/hostproc", "PATH=/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"}
|
cmd.Env = []string{
|
||||||
|
"PATH=/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin",
|
||||||
|
"PROCFS=/hostproc",
|
||||||
|
}
|
||||||
|
if bridge := os.Getenv("DOCKER_BRIDGE"); bridge != "" {
|
||||||
|
cmd.Env = append(cmd.Env, fmt.Sprintf("DOCKER_BRIDGE=%s", bridge))
|
||||||
|
}
|
||||||
var stdout, stderr bytes.Buffer
|
var stdout, stderr bytes.Buffer
|
||||||
cmd.Stdout = &stdout
|
cmd.Stdout = &stdout
|
||||||
cmd.Stderr = &stderr
|
cmd.Stderr = &stderr
|
||||||
|
|||||||
@@ -1063,6 +1063,7 @@ launch_proxy() {
|
|||||||
-v /proc:/hostproc \
|
-v /proc:/hostproc \
|
||||||
-e PROCFS=/hostproc \
|
-e PROCFS=/hostproc \
|
||||||
-e WEAVE_CIDR=none \
|
-e WEAVE_CIDR=none \
|
||||||
|
-e DOCKER_BRIDGE \
|
||||||
--entrypoint=/home/weave/weaveproxy \
|
--entrypoint=/home/weave/weaveproxy \
|
||||||
$WEAVEPROXY_DOCKER_ARGS $EXEC_IMAGE $PROXY_ARGS)
|
$WEAVEPROXY_DOCKER_ARGS $EXEC_IMAGE $PROXY_ARGS)
|
||||||
wait_for_log $PROXY_CONTAINER_NAME "proxy listening"
|
wait_for_log $PROXY_CONTAINER_NAME "proxy listening"
|
||||||
|
|||||||
Reference in new issue
Block a user