Skip to content

Commit

Permalink
Merge branch 'main' into docs-CE556
Browse files Browse the repository at this point in the history
  • Loading branch information
aimeeu authored Jul 15, 2024
2 parents 26c2224 + a9d92d0 commit 5f5baaf
Show file tree
Hide file tree
Showing 49 changed files with 5,202 additions and 4,117 deletions.
3 changes: 3 additions & 0 deletions .changelog/21378.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:security
ui: Pin and namespace sub-module dependencies related to the Consul UI
```
4 changes: 4 additions & 0 deletions .changelog/21381.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
```release-note:bug
dns: Fixes a spam log message "Failed to parse TTL for prepared query..."
that was always being logged on each prepared query evaluation.
```
3 changes: 3 additions & 0 deletions .changelog/21382.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:bug
terminating-gateway: **(Enterprise Only)** Fixed issue where enterprise metadata applied to linked services was the terminating-gateways enterprise metadata and not the linked services enterprise metadata.
```
3 changes: 3 additions & 0 deletions .changelog/21384.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:security
Upgrade go-retryablehttp to address [CVE-2024-6104](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2024-6104)
```
3 changes: 3 additions & 0 deletions .changelog/21507.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:security
Upgrade go version to 1.22.5 to address [CVE-2024-24791](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2024-24791)
```
3 changes: 3 additions & 0 deletions .changelog/21519.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:bug
txn: Fix a bug where mismatched Consul server versions could result in undetected data loss for when using newer Transaction verbs.
```
3 changes: 3 additions & 0 deletions .changelog/21524.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:security
Upgrade envoy module dependencies to version 1.27.7, 1.28.5 and 1.29.7 or higher to resolve [CVE-2024-39305](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2024-39305)
```
3 changes: 2 additions & 1 deletion .github/scripts/verify_artifact.sh
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,8 @@ function verify_rpm {
${docker_image} \
/scripts/verify_rpm.sh \
"/workdir/${artifact_path}" \
"${expect_version}"
"${expect_version}" \
"${docker_image}"
}

# Arguments:
Expand Down
17 changes: 17 additions & 0 deletions .github/scripts/verify_rpm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ set -euo pipefail
# report why it failed. This is meant to be run as part of the build workflow to verify the built
# .rpm meets some basic criteria for validity.

# Notably, CentOS 7 is EOL, so we need to point to the vault for updates. It's not clear what alternative
# we may use in the future that supports linux/386 as the platform was dropped in CentOS 8+9. The docker_image
# is passed in as the third argument so that the script can determine if it needs to point to the vault for updates.

# set this so we can locate and execute the verify_bin.sh script for verifying version output
SCRIPT_DIR="$( cd -- "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )"

Expand All @@ -20,6 +24,7 @@ function usage {
function main {
local rpm_path="${1:-}"
local expect_version="${2:-}"
local docker_image="${3:-}"
local got_version

if [[ -z "${rpm_path}" ]]; then
Expand All @@ -34,6 +39,12 @@ function main {
exit 1
fi

if [[ -z "${docker_image}" ]]; then
echo "ERROR: docker image argument is required"
usage
exit 1
fi

# expand globs for path names, if this fails, the script will exit
rpm_path=$(echo ${rpm_path})

Expand All @@ -43,6 +54,12 @@ function main {
exit 1
fi

# CentOS 7 is EOL, so we need to point to the vault for updates
if [[ "$docker_image" == *centos:7 ]]; then
sed -i 's/mirrorlist/#mirrorlist/g' /etc/yum.repos.d/CentOS-*
sed -i 's|#baseurl=http://mirror.centos.org|baseurl=http://vault.centos.org|g' /etc/yum.repos.d/CentOS-*
fi

yum -y clean all
yum -y update
yum -y install which openssl
Expand Down
10 changes: 9 additions & 1 deletion .github/workflows/nightly-test-integ-peering_commontopo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,12 +39,20 @@ jobs:

get-go-version:
uses: ./.github/workflows/reusable-get-go-version.yml
with:
ref: ${{ inputs.branch }}

get-envoy-versions:
uses: ./.github/workflows/reusable-get-envoy-versions.yml
with:
ref: ${{ inputs.branch }}

tests:
runs-on: ${{ fromJSON(needs.setup.outputs.compute-xl ) }}
needs:
- setup
- get-go-version
- get-envoy-versions
permissions:
id-token: write # NOTE: this permission is explicitly required for Vault auth.
contents: read
Expand All @@ -62,7 +70,7 @@ jobs:
name: '${{matrix.test-case}}'

env:
ENVOY_VERSION: "1.29.5"
ENVOY_VERSION: ${{ needs.get-envoy-versions.outputs.max-envoy-version }}
steps:
- uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4
# NOTE: This step is specifically needed for ENT. It allows us to access the required private HashiCorp repos.
Expand Down
50 changes: 33 additions & 17 deletions .github/workflows/nightly-test-integrations-1.15.x.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,14 @@ jobs:
get-go-version:
needs: [check-ent]
uses: ./.github/workflows/reusable-get-go-version.yml
with:
ref: release/1.15.x

get-envoy-versions:
needs: [check-ent]
uses: ./.github/workflows/reusable-get-envoy-versions.yml
with:
ref: release/1.15.x

dev-build:
needs:
Expand Down Expand Up @@ -79,36 +87,34 @@ jobs:
- name: Generate Envoy Job Matrix
id: set-matrix
env:
# this is further going to multiplied in envoy-integration tests by the
# other dimensions in the matrix. Currently TOTAL_RUNNERS would be
# 14 based on these values:
# envoy-version: ["1.22.11", "1.23.12", "1.24.12", "1.25.11", "1.26.8", "1.27.5", "1.28.3"]
# xds-target: ["server", "client"]
TOTAL_RUNNERS: 7
# TEST_SPLITS sets the number of test case splits to use in the matrix. This will be
# further multiplied in envoy-integration tests by the other dimensions in the matrix
# to determine the total number of runners used.
TEST_SPLITS: 4
JQ_SLICER: '[ inputs ] | [_nwise(length / $runnercount | floor)]'
run: |
NUM_RUNNERS=$TOTAL_RUNNERS
NUM_DIRS=$(find ./test/integration/connect/envoy -mindepth 1 -maxdepth 1 -type d | wc -l)
if [ "$NUM_DIRS" -lt "$NUM_RUNNERS" ]; then
echo "TOTAL_RUNNERS is larger than the number of tests/packages to split."
NUM_RUNNERS=$((NUM_DIRS-1))
if [ "$NUM_DIRS" -lt "$TEST_SPLITS" ]; then
echo "TEST_SPLITS is larger than the number of tests/packages to split."
TEST_SPLITS=$((NUM_DIRS-1))
fi
# fix issue where test splitting calculation generates 1 more split than TOTAL_RUNNERS.
NUM_RUNNERS=$((NUM_RUNNERS-1))
# fix issue where test splitting calculation generates 1 more split than TEST_SPLITS.
TEST_SPLITS=$((TEST_SPLITS-1))
{
echo -n "envoy-matrix="
find ./test/integration/connect/envoy -maxdepth 1 -type d -print0 \
| xargs -0 -n 1 basename \
| jq --raw-input --argjson runnercount "$NUM_RUNNERS" "$JQ_SLICER" \
| jq --raw-input --argjson runnercount "$TEST_SPLITS" "$JQ_SLICER" \
| jq --compact-output 'map(join("|"))'
} >> "$GITHUB_OUTPUT"
envoy-integration-test:
runs-on: ${{ fromJSON(needs.setup.outputs.compute-large) }}
needs:
- setup
- get-go-version
- get-envoy-versions
- generate-envoy-job-matrices
- dev-build
permissions:
Expand All @@ -117,7 +123,7 @@ jobs:
strategy:
fail-fast: false
matrix:
envoy-version: ["1.22.11", "1.23.12", "1.24.12", "1.25.11", "1.26.8", "1.27.6", "1.28.4"]
envoy-version: ${{ fromJSON(needs.get-envoy-versions.outputs.envoy-versions-json) }}
xds-target: ["server", "client"]
test-cases: ${{ fromJSON(needs.generate-envoy-job-matrices.outputs.envoy-matrix) }}
env:
Expand Down Expand Up @@ -196,7 +202,7 @@ jobs:
DATADOG_API_KEY: "${{ endsWith(github.repository, '-enterprise') && env.DATADOG_API_KEY || secrets.DATADOG_API_KEY }}"
DD_ENV: ci
run: datadog-ci junit upload --service "$GITHUB_REPOSITORY" $TEST_RESULTS_DIR/results.xml

upgrade-integration-test:
runs-on: ${{ fromJSON(needs.setup.outputs.compute-large) }}
needs:
Expand All @@ -212,7 +218,17 @@ jobs:
consul-version: ["1.14", "1.15"]
env:
CONSUL_LATEST_VERSION: ${{ matrix.consul-version }}
ENVOY_VERSION: "1.24.6"
# ENVOY_VERSION should be the latest version supported by _all_ Consul versions in the
# matrix.consul-version, since we are testing upgrade from an older Consul version.
# In practice, this should be the highest Envoy version supported by the lowest non-LTS
# Consul version in the matrix (LTS versions receive additional Envoy version support).
#
# This value should be kept current in new nightly test workflows, and updated any time
# a new major Envoy release is added to the set supported by Consul versions in
# matrix.consul-version (i.e. whenever the highest common Envoy version across active
# Consul versions changes). The minor Envoy version does not necessarily need to be
# kept current for the purpose of these tests, but the major (1.N) version should be.
ENVOY_VERSION: "1.24.12"
steps:
- name: Checkout code
uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4
Expand Down
50 changes: 33 additions & 17 deletions .github/workflows/nightly-test-integrations-1.17.x.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,14 @@ jobs:
get-go-version:
needs: [check-ent]
uses: ./.github/workflows/reusable-get-go-version.yml
with:
ref: release/1.17.x

get-envoy-versions:
needs: [check-ent]
uses: ./.github/workflows/reusable-get-envoy-versions.yml
with:
ref: release/1.17.x

dev-build:
needs:
Expand Down Expand Up @@ -79,36 +87,34 @@ jobs:
- name: Generate Envoy Job Matrix
id: set-matrix
env:
# this is further going to multiplied in envoy-integration tests by the
# other dimensions in the matrix. Currently TOTAL_RUNNERS would be
# multiplied by 8 based on these values:
# envoy-version: ["1.24.12", "1.25.11", "1.26.8", "1.27.5"]
# xds-target: ["server", "client"]
TOTAL_RUNNERS: 4
# TEST_SPLITS sets the number of test case splits to use in the matrix. This will be
# further multiplied in envoy-integration tests by the other dimensions in the matrix
# to determine the total number of runners used.
TEST_SPLITS: 4
JQ_SLICER: '[ inputs ] | [_nwise(length / $runnercount | floor)]'
run: |
NUM_RUNNERS=$TOTAL_RUNNERS
NUM_DIRS=$(find ./test/integration/connect/envoy -mindepth 1 -maxdepth 1 -type d | wc -l)
if [ "$NUM_DIRS" -lt "$NUM_RUNNERS" ]; then
echo "TOTAL_RUNNERS is larger than the number of tests/packages to split."
NUM_RUNNERS=$((NUM_DIRS-1))
if [ "$NUM_DIRS" -lt "$TEST_SPLITS" ]; then
echo "TEST_SPLITS is larger than the number of tests/packages to split."
TEST_SPLITS=$((NUM_DIRS-1))
fi
# fix issue where test splitting calculation generates 1 more split than TOTAL_RUNNERS.
NUM_RUNNERS=$((NUM_RUNNERS-1))
# fix issue where test splitting calculation generates 1 more split than TEST_SPLITS.
TEST_SPLITS=$((TEST_SPLITS-1))
{
echo -n "envoy-matrix="
find ./test/integration/connect/envoy -maxdepth 1 -type d -print0 \
| xargs -0 -n 1 basename \
| jq --raw-input --argjson runnercount "$NUM_RUNNERS" "$JQ_SLICER" \
| jq --raw-input --argjson runnercount "$TEST_SPLITS" "$JQ_SLICER" \
| jq --compact-output 'map(join("|"))'
} >> "$GITHUB_OUTPUT"
envoy-integration-test:
runs-on: ${{ fromJSON(needs.setup.outputs.compute-large) }}
needs:
- setup
- get-go-version
- get-envoy-versions
- generate-envoy-job-matrices
- dev-build
permissions:
Expand All @@ -117,7 +123,7 @@ jobs:
strategy:
fail-fast: false
matrix:
envoy-version: ["1.24.12", "1.25.11", "1.26.8", "1.27.6"]
envoy-version: ${{ fromJSON(needs.get-envoy-versions.outputs.envoy-versions-json) }}
xds-target: ["server", "client"]
test-cases: ${{ fromJSON(needs.generate-envoy-job-matrices.outputs.envoy-matrix) }}
env:
Expand Down Expand Up @@ -199,7 +205,7 @@ jobs:
DATADOG_API_KEY: "${{ endsWith(github.repository, '-enterprise') && env.DATADOG_API_KEY || secrets.DATADOG_API_KEY }}"
DD_ENV: ci
run: datadog-ci junit upload --service "$GITHUB_REPOSITORY" $TEST_RESULTS_DIR/results.xml

upgrade-integration-test:
runs-on: ${{ fromJSON(needs.setup.outputs.compute-large) }}
needs:
Expand All @@ -215,7 +221,17 @@ jobs:
consul-version: ["1.15", "1.16", "1.17"]
env:
CONSUL_LATEST_VERSION: ${{ matrix.consul-version }}
ENVOY_VERSION: "1.24.6"
# ENVOY_VERSION should be the latest version supported by _all_ Consul versions in the
# matrix.consul-version, since we are testing upgrade from an older Consul version.
# In practice, this should be the highest Envoy version supported by the lowest non-LTS
# Consul version in the matrix (LTS versions receive additional Envoy version support).
#
# This value should be kept current in new nightly test workflows, and updated any time
# a new major Envoy release is added to the set supported by Consul versions in
# matrix.consul-version (i.e. whenever the highest common Envoy version across active
# Consul versions changes). The minor Envoy version does not necessarily need to be
# kept current for the purpose of these tests, but the major (1.N) version should be.
ENVOY_VERSION: 1.27.6
steps:
- name: Checkout code
uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4
Expand Down
Loading

0 comments on commit 5f5baaf

Please sign in to comment.