Skip to content
This repository was archived by the owner on Oct 14, 2020. It is now read-only.

Commit 0f0240b

Browse files
committed
Merge branch 'hooks' of github.com:secureCodeBox/secureCodeBox-v2-alpha into hooks
2 parents 851e2b2 + 5067d9c commit 0f0240b

File tree

18 files changed

+4729
-15
lines changed

18 files changed

+4729
-15
lines changed

.github/workflows/ci.yaml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -239,6 +239,14 @@ jobs:
239239
repository: scbexperimental/test-read-write-hook
240240
path: ./hooks/test-read-write-hook/
241241
tag_with_ref: true
242+
- uses: docker/build-push-action@v1
243+
name: "Build & Push UpdateField Hook Image"
244+
with:
245+
username: ${{ secrets.DOCKER_USERNAME }}
246+
password: ${{ secrets.DOCKER_PASSWORD }}
247+
repository: scbexperimental/update-field
248+
path: ./hooks/update-field/
249+
tag_with_ref: true
242250
scannerImages:
243251
# Note we only build images for scanner that don't provider official public container images
244252
name: "Build / Scanner"

docs/developer-guide/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@ To build the operator you will need to install [Go](https://golang.org/).
1111

1212
#### Minikube or Kind
1313

14-
For local development we recommend to use [Minikube](https://kubernetes.io/docs/tasks/tools/install-minikube/) or [kind](https://github.com/kubernetes-sigs/kind).
15-
Both projects will enable you to run a local kubernetes cluster on your development machine.
14+
For local development we recommend to use [Minikube](https://kubernetes.io/docs/tasks/tools/install-minikube/) or [kind](https://github.com/kubernetes-sigs/kind). If you are using MacOS or Windows you can also use the kubernetes cluster included within Docker for Mac/Windows.
15+
All of these tools will enable you to run a local kubernetes cluster on your development machine.
1616

1717
#### Operating your local kubernetes cluster
1818

@@ -101,4 +101,4 @@ We're using snake_case (lower case) for json attributes. If an enum type is used
101101
},
102102
"location": "tcp://127.0.0.1:3306"
103103
}
104-
```
104+
```

hooks/add-attributes/Dockerfile

Lines changed: 0 additions & 3 deletions
This file was deleted.

hooks/add-attributes/templates/NOTES.txt

Lines changed: 0 additions & 2 deletions
This file was deleted.
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
apiVersion: v2
2-
name: add-attributes-hook
3-
description: Lets you add new attributes to every finding
2+
name: update-field-hook
3+
description: Lets you add or override a field to every finding
44

55
type: application
66

hooks/update-field/Dockerfile

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
FROM node:12-alpine as build
2+
RUN mkdir -p /home/app
3+
WORKDIR /home/app
4+
COPY package.json package-lock.json ./
5+
RUN npm ci --production
6+
7+
FROM scbexperimental/hook-sdk-nodejs:latest
8+
WORKDIR /home/app/hook-wrapper/hook/
9+
COPY --from=build --chown=app:app /home/app/node_modules/ ./node_modules/
10+
COPY --chown=app:app ./hook.js ./hook.js

0 commit comments

Comments
 (0)