Skip to content

Commit

Permalink
ci: bump envoy-filter-example SHA on master merge. (envoyproxy#3106)
Browse files Browse the repository at this point in the history
Signed-off-by: Harvey Tuch <[email protected]>
  • Loading branch information
htuch authored Apr 17, 2018
1 parent 762ebd1 commit 982ff2d
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 0 deletions.
12 changes: 12 additions & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,17 @@ jobs:
fingerprints:
- "fb:f3:fe:be:1c:b2:ec:b6:25:f9:7b:a6:87:54:02:8c"
- run: ci/api_mirror.sh
filter_example_mirror:
docker:
- image: *envoy-build-image
resource_class: xlarge
working_directory: /source
steps:
- checkout
- add_ssh_keys:
fingerprints:
- "f6:f9:df:90:9c:4b:5f:9c:f4:69:fd:42:94:ff:88:24"
- run: ci/filter_example_mirror.sh
ipv6_tests:
machine: true
steps:
Expand Down Expand Up @@ -136,6 +147,7 @@ workflows:
- asan
- tsan
- api
- filter_example_mirror
- ipv6_tests
- coverage
- format
Expand Down
26 changes: 26 additions & 0 deletions ci/filter_example_mirror.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
#!/bin/bash

set -e

CHECKOUT_DIR=../envoy-filter-example

if [ -z "$CIRCLE_PULL_REQUEST" ] && [ "$CIRCLE_BRANCH" == "master" ]
then
echo "Cloning..."
git clone [email protected]:envoyproxy/envoy-filter-example "$CHECKOUT_DIR"

git -C "$CHECKOUT_DIR" config user.name "envoy-filter-example(CircleCI)"
git -C "$CHECKOUT_DIR" config user.email [email protected]
git -C "$CHECKOUT_DIR" fetch
git -C "$CHECKOUT_DIR" checkout -B master origin/master

# Update submodule to latest Envoy SHA
ENVOY_SHA=$(git rev-parse HEAD)
git -C "$CHECKOUT_DIR" submodule update --init
git -C "$CHECKOUT_DIR/envoy" checkout "$ENVOY_SHA"
git -C "$CHECKOUT_DIR" commit -a -m "Update Envoy submodule to $ENVOY_SHA"

echo "Pushing..."
git -C "$CHECKOUT_DIR" push origin master
echo "Done"
fi

0 comments on commit 982ff2d

Please sign in to comment.