File tree Expand file tree Collapse file tree 3 files changed +48
-6
lines changed
Expand file tree Collapse file tree 3 files changed +48
-6
lines changed Original file line number Diff line number Diff line change 1- ARG NODE_VERSION=16
1+ ARG NODE_VERSION=18
22
33FROM node:${NODE_VERSION}-bullseye
44
Original file line number Diff line number Diff line change 11# Node runner
22
33Simple image for executing node tasks inside a container.
4+
5+ The image will run ` npm i --prefer-offline --no-audit ` befor it run your script.
6+
7+ ## Images:
8+
9+ | ** Node version** | ** image** |
10+ | -| -|
11+ | 14 | ghcr.io/scarbous/node-runner/14 |
12+ | 16 | ghcr.io/scarbous/node-runner/16 |
13+ | 18 | ghcr.io/scarbous/node-runner/18 |
14+ | 19 | ghcr.io/scarbous/node-runner/19 |
15+
16+ ## Usage
17+
18+ Mount the your app to ` /src ` .
19+ By default the Image will run the script ` dev ` which is defined in the ` package.json ` in your project-root.
20+
21+ ### Environment variables
22+
23+ | ** Name** | ** Info** |
24+ | -| -|
25+ | ** DIR** | The dir which contains your ` package.json ` |
26+ | ** TASK** | Name of the script to run |
27+
28+
29+ # GitHub docker action
30+
31+ The action runs the configured script from your ` package.json ` .
32+
33+ ## Inputs
34+
35+ | ** Name** | ** Default** | ** Info** |
36+ | -| -| -|
37+ | ** DIR** | ` "/" ` | The dir which contains your ` package.json ` |
38+ | ** TASK** | ` "buil" ` | Name of the script to run |
39+
40+ ## Example usage
41+
42+ In this example the runner will execute the ` build ` script inside the Build dir.
43+
44+ ``` yaml
45+ steps :
46+ - uses : Scarbous/node-runner@1.0.6
47+ with :
48+ dir : Build
49+ task : build
50+ ` ` `
Original file line number Diff line number Diff line change @@ -4,9 +4,6 @@ branding:
44 color : orange
55description : It will install and run your npm script
66inputs :
7- nodeVersion :
8- description : the node Version to use
9- default : " 16"
107 dir :
118 description : base dir of
129 default : " /"
@@ -15,8 +12,6 @@ inputs:
1512 default : " build"
1613runs :
1714 using : ' docker'
18- args :
19- - NODE_VERSION=${{ inputs.nodeVersion }}
2015 env :
2116 DIR : " /github/workspace/${{ inputs.dir }}"
2217 TASK : ${{ inputs.task }}
You can’t perform that action at this time.
0 commit comments