Skip to content

Commit a5d087f

Browse files
authored
Merge pull request #37 from safeinsights/bugfix/sk/shrimp/115
SHRIMP-115
2 parents 252d804 + 1f341d4 commit a5d087f

File tree

6 files changed

+229
-240
lines changed

6 files changed

+229
-240
lines changed

.github/workflows/checks.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,12 @@ jobs:
1717
run: npm i
1818
- name: Lint
1919
run: npm run lint
20+
- name: Run Trivy vulnerability scanner in fs mode
21+
uses: aquasecurity/[email protected]
22+
with:
23+
scan-type: 'fs'
24+
scan-ref: '.'
25+
trivy-config: trivy.yaml
2026
- name: Typecheck
2127
run: npm run typecheck
2228
- name: Unit Test

Dockerfile

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,24 @@
11
FROM node:22-alpine AS base
22

3+
4+
ARG USER=node
5+
ENV HOME /home/$USER
6+
37
# Alpine doesn't have curl, so add it
48
RUN apk --no-cache add curl
59

610
# Set the working directory inside the container
7-
WORKDIR /app
11+
USER $USER
12+
WORKDIR $HOME/app
813

914
# Copy the package.json and lock file to install dependencies
10-
COPY package.json package-lock.json panda.config.ts ./
15+
COPY --chown=$USER:$USER package.json package-lock.json panda.config.ts ./
1116

1217
# Install dependencies
1318
RUN npm install
1419

1520
# Copy the rest of the application files
16-
COPY . .
21+
COPY --chown=$USER:$USER . .
1722

1823
# Build the Next.js app
1924
RUN npm run build

next-env.d.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
/// <reference types="next" />
22
/// <reference types="next/image-types/global" />
3+
/// <reference types="next/navigation-types/compat/navigation" />
34

45
// NOTE: This file should not be edited
56
// see https://nextjs.org/docs/app/api-reference/config/typescript for more information.

0 commit comments

Comments
 (0)