Skip to content

Commit

Permalink
feat: parameterize tags for CircleCI images (#171)
Browse files Browse the repository at this point in the history
Co-authored-by: Isaac Riceweber <[email protected]>
Co-authored-by: Eric Ribeiro <[email protected]>
  • Loading branch information
3 people authored Nov 7, 2022
1 parent 02a882d commit b21ac73
Show file tree
Hide file tree
Showing 5 changed files with 29 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/executors/default.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ parameters:
What version of the CircleCI CLI Docker image? For full list, see
https://hub.docker.com/r/circleci/circleci-cli/tags
resource_class:
description: Configure the xecutor resource class
description: Configure the executor resource class
type: enum
enum: ["small", "medium", "medium+", "large", "xlarge", "2xlarge", "2xlarge+"]
default: "medium"
Expand Down
8 changes: 7 additions & 1 deletion src/jobs/continue.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ description: |
After the "publish-dev" job has completed along with any other preliminary checks, this job will trigger the next workflow (test-deploy) in the Orb Development Kit.
docker:
- image: cimg/base:current
- image: cimg/base:<< parameters.tag >>
resource_class: << parameters.resource_class >>

parameters:
Expand Down Expand Up @@ -34,6 +34,12 @@ parameters:
type: enum
enum: ["small", "medium", "medium+", "large", "xlarge", "2xlarge", "2xlarge+"]
default: "medium"
tag:
type: string
default: "current"
description: |
By default the most current stable release of `cimg/base` image will be used, but you may statically set the image tag with this parameter.
https://circleci.com/developer/images/image/cimg/base
steps:
- checkout
Expand Down
7 changes: 7 additions & 0 deletions src/jobs/pack.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,17 @@ parameters:
description: Host URL of CircleCI API. If you are using self-hosted CircleCI, this value should be set.
type: string
default: https://circleci.com
tag:
type: string
default: "latest"
description: >
What version of the CircleCI CLI Docker image? For full list, see
https://hub.docker.com/r/circleci/circleci-cli/tags
executor:
name: default
resource_class: << parameters.resource_class >>
tag: << parameters.tag >>

steps:
- checkout
Expand Down
7 changes: 7 additions & 0 deletions src/jobs/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ description: |
executor:
name: default
resource_class: << parameters.resource_class >>
tag: << parameters.tag >>

parameters:
resource_class:
Expand Down Expand Up @@ -66,6 +67,12 @@ parameters:
- dev
- production
default: "dev"
tag:
type: string
default: "latest"
description: >
What version of the CircleCI CLI Docker image? For full list, see
https://hub.docker.com/r/circleci/circleci-cli/tags
steps:
- attach_workspace:
Expand Down
8 changes: 7 additions & 1 deletion src/jobs/review.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,15 @@ parameters:
Commands longer than this will fail the review.
type: integer
default: 64
tag:
type: string
default: "current"
description: |
By default the most current stable release of `cimg/base` image will be used, but you may statically set the image tag with this parameter.
https://circleci.com/developer/images/image/cimg/base
docker:
- image: cimg/base:current
- image: cimg/base:<< parameters.tag >>
resource_class: << parameters.resource_class >>

steps:
Expand Down

0 comments on commit b21ac73

Please sign in to comment.