Skip to content

Commit af4456f

Browse files
committed
Merge remote-tracking branch 'origin/develop' into release-v3.0.0
2 parents 574b8ba + 87da2c8 commit af4456f

File tree

3 files changed

+16
-43
lines changed

3 files changed

+16
-43
lines changed

.circleci/config.yml

Lines changed: 9 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -10,18 +10,14 @@ version: 2
1010
# typing. See http://yaml.org/type/merge.html for details.
1111
defaults: &defaults
1212
environment:
13-
CI_SCRIPTS: 'npx --quiet --package @reactioncommerce/[email protected]'
14-
DOCKER_REPOSITORY: "reactioncommerce/example-storefront"
15-
DOCKER_NAMESPACE: "reactioncommerce"
16-
DOCKER_NAME: "example-storefront"
17-
GLOBAL_CACHE_VERSION: "v3"
18-
KUSTOMIZE_VERSION: "3.2.1"
19-
HUB_VERSION: "2.12.8"
20-
GH_USERNAME: "rc-circleci"
21-
GH_EMAIL: "[email protected]"
22-
REACTION_GITOPS_REVIEWERS: "griggheo"
13+
- CI_SCRIPTS: "npx --quiet --package @reactioncommerce/[email protected]"
14+
- DOCKER_REPOSITORY: "reactioncommerce/example-storefront"
15+
- DOCKER_NAME: "example-storefront"
16+
- GLOBAL_CACHE_VERSION: “v3”
17+
- SERVICE: "reaction-storefront"
18+
- REACTION_GITOPS_REVIEWERS: "wistonk,griggheo"
2319
docker:
24-
- image: circleci/node:12.11.1-stretch
20+
- image: circleci/node:12-stretch
2521

2622
jobs:
2723
install-dependencies:
@@ -94,35 +90,7 @@ jobs:
9490
- run:
9591
name: Clone reaction-gitops repo and create PR
9692
command: |
97-
# Download kustomize
98-
cd /tmp
99-
wget https://github.com/kubernetes-sigs/kustomize/releases/download/kustomize%2Fv${KUSTOMIZE_VERSION}/kustomize_kustomize.v${KUSTOMIZE_VERSION}_linux_amd64
100-
sudo mv kustomize_kustomize.v${KUSTOMIZE_VERSION}_linux_amd64 /usr/local/bin/kustomize
101-
sudo chmod +x /usr/local/bin/kustomize
102-
# Download hub
103-
wget https://github.com/github/hub/releases/download/v${HUB_VERSION}/hub-linux-amd64-${HUB_VERSION}.tgz
104-
tar xfz hub-linux-amd64-${HUB_VERSION}.tgz
105-
sudo mv hub-linux-amd64-${HUB_VERSION}/bin/hub /usr/local/bin/hub
106-
sudo chmod +x /usr/local/bin/hub
107-
# Clone reaction-gitops repo and configure username and email for signing off commits
108-
export GITHUB_TOKEN="${REACTION_GITOPS_GH_TOKEN}"
109-
/usr/local/bin/hub clone https://${GITHUB_TOKEN}@github.com/reactioncommerce/reaction-gitops.git
110-
cd reaction-gitops
111-
/usr/local/bin/hub config user.name "${GH_USERNAME}"
112-
/usr/local/bin/hub config user.email "${GH_EMAIL}"
113-
cd kustomize/reaction-storefront/overlays/staging
114-
# Create new branch
115-
/usr/local/bin/hub checkout -b update-image-reaction-storefront-${CIRCLE_SHA1}
116-
# Modify image tag in kustomization.yaml by calling 'kustomize edit set image'
117-
/usr/local/bin/kustomize edit set image docker.io/${DOCKER_REPOSITORY}:${CIRCLE_SHA1}
118-
/usr/local/bin/hub add kustomization.yaml
119-
# Commit with sign-off
120-
/usr/local/bin/hub commit -s -m "changed reaction-storefront image tag to ${CIRCLE_SHA1}"
121-
# Push branch to origin
122-
/usr/local/bin/hub push --set-upstream origin update-image-reaction-storefront-${CIRCLE_SHA1}
123-
# Create PR
124-
/usr/local/bin/hub pull-request --no-edit -r ${REACTION_GITOPS_REVIEWERS}
125-
93+
${CI_SCRIPTS} automate-gitops-pull-request
12694
workflows:
12795
version: 2
12896
build_and_test:
@@ -144,6 +112,7 @@ workflows:
144112
- eslint
145113
- test-unit
146114
- create-gitops-pull-request:
115+
context: reaction-gitops
147116
requires:
148117
- docker-build-push
149118
filters:

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
Example Storefront v2.9.0 is a minor update to keep this project in sync with [Reaction v2.9.0](https://github.com/reactioncommerce/reaction) and [reaction-hydra v2.9.0](https://github.com/reactioncommerce/reaction-hydra)
44

5+
# v2.8.1
6+
7+
Example Storefront v2.8.1 is a patch update to keep this project in sync with [Reaction v2.8.1](https://github.com/reactioncommerce/reaction) and [reaction-hydra v2.8.1](https://github.com/reactioncommerce/reaction-hydra)
8+
59
# v2.8.0
610

711
Example Storefront v2.8.0 is a minor update to keep this project in sync with [Reaction v2.8.0](https://github.com/reactioncommerce/reaction) and [reaction-hydra v2.8.0](https://github.com/reactioncommerce/reaction-hydra)

bin/setup

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
#!/usr/bin/env bash
22

3-
__dir="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
4-
env_file=${__dir}/../.env
5-
env_example_file=${__dir}/../.env.example
3+
cd "$(dirname "${BASH_SOURCE[0]}")/.."
4+
env_file=./.env
5+
env_example_file=./.env.example
66

77
function main {
88
set -e

0 commit comments

Comments
 (0)