Skip to content

Commit

Permalink
Add node-version parameters
Browse files Browse the repository at this point in the history
  • Loading branch information
sashuk committed Nov 17, 2023
1 parent dbb531f commit dbe884b
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 15 deletions.
11 changes: 6 additions & 5 deletions build-publish-alpha-package/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,12 @@ Uses `yarn build:package` command to build the package.

The list of arguments, that are used in GH Action:

| name | type | required | default | description |
| ------------- | ------ | -------- | ------- | ----------------------------------------------------- |
| `npm-token` | string || | NPM token used for publishing. Has to be type Publish |
| `branch` | string || | Name of the branch that will be published |
| `root-folder` | string | | | Root folder of a package to be published |
| name | type | required | default | description |
| -------------- | ------ | -------- | ------- | ------------------------------------------------------------------------------------------- |
| `npm-token` | string || | NPM token used for publishing. Has to be type Publish |
| `branch` | string || | Name of the branch that will be published |
| `root-folder` | string | | | Root folder of a package to be published |
| `node-version` | string | | 18 | Node.js version used. The action is guaranteed to work only with Node.js@18 (default value) |

### Outputs

Expand Down
6 changes: 5 additions & 1 deletion build-publish-alpha-package/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@ inputs:
root-folder:
required: false
description: 'Root folder of a package to be published || string'
node-version:
required: false
default: 18
description: 'Node.js version used. The action is guaranteed to work only with Node.js@18 (default value)'

runs:
using: composite
Expand All @@ -29,7 +33,7 @@ runs:
- name: Setup node
uses: actions/[email protected]
with:
node-version: 18
node-version: ${{ inputs.node-version }}

- uses: toptal/davinci-github-actions/[email protected]

Expand Down
17 changes: 9 additions & 8 deletions build-push-image/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,15 @@ This GH Action builds a Docker image and pushes to google cloud.

The list of arguments, that are used in GH Action:

| name | type | required | default | description |
| ---------------- | ----------------------------------------------------------- | -------- | -------------------------------------------------------------- | ------------------------------------------------------------------------------------------ |
| `sha` | string || | Commit hash that will be used as a tag for the Docker image |
| `image-name` | string || | Name of the Docker image. Might be used in the next steps (for ex.: deploy a Docker image) |
| `environment` | enum<<br/>`temploy`,<br/>`staging`,<br/>`production`,<br/>> | | staging | Determines additional procedures while creating a Docker image. |
| `build-args` | string || | Multiline string to describe build arguments that will be used during dockerization |
| `docker-file` | string | | ./davinci/packages/ci/src/configs/docker/Dockerfile.gha-deploy | pathname to Docker file |
| `davinci-branch` | string | | master | Custom davinci branch |
| name | type | required | default | description |
| ---------------- | ----------------------------------------------------------- | -------- | -------------------------------------------------------------- | ------------------------------------------------------------------------------------------- |
| `sha` | string || | Commit hash that will be used as a tag for the Docker image |
| `image-name` | string || | Name of the Docker image. Might be used in the next steps (for ex.: deploy a Docker image) |
| `environment` | enum<<br/>`temploy`,<br/>`staging`,<br/>`production`,<br/>> | | staging | Determines additional procedures while creating a Docker image. |
| `build-args` | string || | Multiline string to describe build arguments that will be used during dockerization |
| `docker-file` | string | | ./davinci/packages/ci/src/configs/docker/Dockerfile.gha-deploy | pathname to Docker file |
| `davinci-branch` | string | | master | Custom davinci branch |
| `node-version` | string | | 18 | Node.js version used. The action is guaranteed to work only with Node.js@18 (default value) |

### Outputs

Expand Down
6 changes: 5 additions & 1 deletion build-push-image/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@ inputs:
description: 'Custom davinci branch'
required: false
default: 'master'
node-version:
required: false
default: 18
description: 'Node.js version used. The action is guaranteed to work only with Node.js@18 (default value)'

runs:
using: composite
Expand All @@ -43,7 +47,7 @@ runs:
- name: Setup node
uses: actions/[email protected]
with:
node-version: 18
node-version: ${{ inputs.node-version }}

- id: meta-latest
shell: bash
Expand Down

0 comments on commit dbe884b

Please sign in to comment.