Skip to content

Commit 4374793

Browse files
authored
fix: #2030 add ignore script prevent supply chain attack (#859)
1 parent e9022d9 commit 4374793

File tree

5 files changed

+9
-9
lines changed

5 files changed

+9
-9
lines changed

.github/workflows/analysis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ jobs:
2424
- uses: bcgov/[email protected]
2525
with:
2626
commands: |
27-
npm ci
27+
npm ci --ignore-scripts
2828
npm run test-unit
2929
dir: api
3030
node_version: 18.18.2

api/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,9 @@ Once set up, the stack can be access using the following paths on localhost:
2626

2727
### Local / Bare Metal
2828

29-
Run 'cd ../libs && npm ci' first.
29+
Run 'cd ../libs && npm ci --ignore-scripts' first.
3030

31-
Run 'npm install' for this component.
31+
Run 'npm install --ignore-scripts' for this component.
3232

3333
Start commands are available in package.json.
3434

@@ -44,7 +44,7 @@ source ./localdev.env # Linux, MacOS
4444
export OBJECT_STORAGE_SECRET=<hidden>
4545
4646
# Make sure 'libs' dependencies is installed
47-
cd ../libs && npm ci
47+
cd ../libs && npm ci --ignore-scripts
4848
4949
# Install node modules
5050
npm i

docker-compose.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ services:
3838
- sh
3939
- -c
4040
- cd libs && npm ci --ignore-scripts &&
41-
cd ../api && npm i --ignore-scripts &&
41+
cd ../api && npm ci --ignore-scripts &&
4242
npm run start:api
4343
environment:
4444
- DB_HOST=db

libs/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ Under 'libs' folder, current categories for the libs project contains:
3333

3434
FOM has been migrated from mono-repo to none mono-repo for ease of resolving dependencies individually for each project (but not 'libs' with versioning). As 'libs' is a sibling project beside other projects, for the individual project to use it and to build, you do require to do following steps first before building individual project:
3535
- cd libs
36-
- npm ci
36+
- npm ci --ignore-scripts
3737

3838
## Client Library Generation
3939
- See [Client Library Generation](../api/README.md)

libs/client/typescript-ng/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
To install the required dependencies and to build the typescript sources run:
66
```
7-
npm install
7+
npm install --ignore-scripts
88
npm run build
99
```
1010

@@ -19,13 +19,13 @@ Navigate to the folder of your consuming project and run one of next commands.
1919
_published:_
2020

2121
```
22-
npm install @ --save
22+
npm install @ --save --ignore-scripts
2323
```
2424

2525
_without publishing (not recommended):_
2626

2727
```
28-
npm install PATH_TO_GENERATED_PACKAGE/dist.tgz --save
28+
npm install PATH_TO_GENERATED_PACKAGE/dist.tgz --save --ignore-scripts
2929
```
3030

3131
_It's important to take the tgz file, otherwise you'll get trouble with links on windows_

0 commit comments

Comments
 (0)