Skip to content

Commit c51ffb4

Browse files
DWN-42625 : introduce Gresham Orb and update build executor image
1 parent d9d1df3 commit c51ffb4

File tree

2 files changed

+33
-24
lines changed

2 files changed

+33
-24
lines changed

.circleci/README.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# How to make changes?
2+
##### Install the CircleCI CLI:
3+
https://circleci.com/docs/2.0/local-cli/#installation
4+
5+
##### Making a change
6+
Change the areas of the .circleci/config.yml file that need to be edited
7+
8+
##### To verify your changes
9+
Any config can be verified, to ensure your changes are valid against the yaml and orb schemas,
10+
from the root of the project, run: `circleci config validate .circleci/config.yml --org-slug gh/gresham-computing --token $CIRCLE_TOKEN`
11+
12+
##### Possible errors:
13+
- Your file must be encoded in UTF-8 (powershell defaulted to UTF-16)
14+
- Must use Unix style line endings (LF, not CRLF)

.circleci/config.yml

Lines changed: 19 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,15 @@ parameters:
66
default: false
77

88
orbs:
9-
aws-white-list-circleci-ip: configure/aws-white-list-circleci-ip@1.0.1
9+
gresham: gresham-computing/gresham-orb@5.1.0
1010

1111
executors:
1212
docker-executor:
1313
docker:
14-
- image: 455456581940.dkr.ecr.eu-west-1.amazonaws.com/circleci-build-images:corretto-8u342
14+
- image: 399104266609.dkr.ecr.eu-west-1.amazonaws.com/circleci-build-images:corretto-8u342
1515
aws_auth:
16-
aws_access_key_id: $AWS_ACCESS_KEY_ID
17-
aws_secret_access_key: $AWS_SECRET_ACCESS_KEY
16+
aws_access_key_id: $GIS_PRD_ECR_INT_BUILD_ACCESS_KEY
17+
aws_secret_access_key: $GIS_PRD_ECR_INT_BUILD_SECRET_ACCESS_KEY
1818

1919
jobs:
2020
build-and-deploy:
@@ -23,7 +23,9 @@ jobs:
2323
- checkout
2424
- get-maven-settings-file
2525
- restore-cache
26-
- whitelist-add
26+
- gresham/get-whitelister
27+
- gresham/whitelist-add:
28+
pattern: OpenId
2729
- run:
2830
name: "Setting Maven version"
2931
command: |
@@ -43,7 +45,8 @@ jobs:
4345
- generate-download-urls:
4446
extension: jar
4547
- save-cache
46-
- whitelist-remove
48+
- gresham/whitelist-remove:
49+
pattern: OpenId
4750
- persist-workspace
4851

4952
test:
@@ -52,27 +55,33 @@ jobs:
5255
- attach_workspace:
5356
at: .
5457
- restore-cache
55-
- whitelist-add
58+
- gresham/get-whitelister
59+
- gresham/whitelist-add:
60+
pattern: OpenId
5661
- run:
5762
name: "Running tests"
5863
command: mvn -fae -s gresham-nexus-settings/ctc.plugins.settings.xml test -B -V -U
5964
- save-test-results
6065
- save-cache
6166
- persist-workspace
62-
- whitelist-remove
67+
- gresham/whitelist-remove:
68+
pattern: OpenId
6369

6470
release:
6571
executor: docker-executor
6672
steps:
6773
- checkout
6874
- get-maven-settings-file
69-
- whitelist-add
75+
- gresham/get-whitelister
76+
- gresham/whitelist-add:
77+
pattern: OpenId
7078
- restore-cache
7179
- run:
7280
name: Creating openid-connect-server release and next snapshot
7381
command: chmod +x .circleci/cci_create_release_and_snapshot.sh && .circleci/cci_create_release_and_snapshot.sh
7482
- save-cache
75-
- whitelist-remove
83+
- gresham/whitelist-remove:
84+
pattern: OpenId
7685

7786
workflows:
7887
build-and-test:
@@ -121,20 +130,6 @@ commands:
121130
git config --global url."https://api:${GITHUB_GRESHAM_PW}@github.com/".insteadOf "https://github.com/"
122131
git clone https://github.com/gresham-computing/gresham-nexus-settings
123132
124-
whitelist-add:
125-
steps:
126-
- aws-white-list-circleci-ip/add:
127-
description: "${CIRCLE_PROJECT_REPONAME}-${CIRCLE_BRANCH}-${CIRCLE_BUILD_NUM}"
128-
tag-key: "Name"
129-
tag-value: "SG-CircleCi-CTC"
130-
131-
whitelist-remove:
132-
steps:
133-
- aws-white-list-circleci-ip/remove:
134-
description: "${CIRCLE_PROJECT_REPONAME}-${CIRCLE_BRANCH}-${CIRCLE_BUILD_NUM}"
135-
tag-key: "Name"
136-
tag-value: "SG-CircleCi-CTC"
137-
138133
save-cache:
139134
steps:
140135
- save_cache:

0 commit comments

Comments
 (0)