Skip to content

Commit

Permalink
Fix issues causing us to use envoy-centos binaries (#31039)
Browse files Browse the repository at this point in the history
Fixes #31038
howardjohn authored Feb 23, 2021
1 parent 535fc07 commit b547c4b
Showing 2 changed files with 13 additions and 5 deletions.
11 changes: 6 additions & 5 deletions bin/init.sh
Original file line number Diff line number Diff line change
@@ -59,6 +59,7 @@ function set_download_command () {
# Params:
# $1: The URL of the Envoy tar.gz to be downloaded.
# $2: The full path of the output binary.
# $3: Non-versioned name to use
function download_envoy_if_necessary () {
if [[ ! -f "$2" ]] ; then
# Enter the output directory.
@@ -76,8 +77,8 @@ function download_envoy_if_necessary () {
rm -rf usr

# Make a copy named just "envoy" in the same directory (overwrite if necessary).
echo "Copying $2 to $(dirname "$2")/${SIDECAR}"
cp -f "$2" "$(dirname "$2")/${SIDECAR}"
echo "Copying $2 to $(dirname "$2")/${3}"
cp -f "$2" "$(dirname "$2")/${3}"
popd
fi
}
@@ -116,14 +117,14 @@ set_download_command

if [[ -n "${DEBUG_IMAGE:-}" ]]; then
# Download and extract the Envoy linux debug binary.
download_envoy_if_necessary "${ISTIO_ENVOY_LINUX_DEBUG_URL}" "$ISTIO_ENVOY_LINUX_DEBUG_PATH"
download_envoy_if_necessary "${ISTIO_ENVOY_LINUX_DEBUG_URL}" "$ISTIO_ENVOY_LINUX_DEBUG_PATH" "${SIDECAR}"
else
echo "Skipping envoy debug. Set DEBUG_IMAGE to download."
fi

# Download and extract the Envoy linux release binary.
download_envoy_if_necessary "${ISTIO_ENVOY_LINUX_RELEASE_URL}" "$ISTIO_ENVOY_LINUX_RELEASE_PATH"
download_envoy_if_necessary "${ISTIO_ENVOY_CENTOS_RELEASE_URL}" "$ISTIO_ENVOY_CENTOS_LINUX_RELEASE_PATH"
download_envoy_if_necessary "${ISTIO_ENVOY_LINUX_RELEASE_URL}" "$ISTIO_ENVOY_LINUX_RELEASE_PATH" "${SIDECAR}"
download_envoy_if_necessary "${ISTIO_ENVOY_CENTOS_RELEASE_URL}" "$ISTIO_ENVOY_CENTOS_LINUX_RELEASE_PATH" "${SIDECAR}-centos"

if [[ "$GOOS_LOCAL" == "darwin" ]]; then
# Download and extract the Envoy macOS release binary
7 changes: 7 additions & 0 deletions releasenotes/notes/bad-envoy-build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
apiVersion: release-notes/v2
kind: feature
area: networking
issue: [31038]
releaseNotes:
- |
**Fixed** an issue causing an alternative Envoy binary to be included in the docker image. The binaries are functionally equivalent.

0 comments on commit b547c4b

Please sign in to comment.