Skip to content

Commit

Permalink
update to 0.10.61
Browse files Browse the repository at this point in the history
  • Loading branch information
craigrbarnes committed Dec 10, 2024
1 parent fc879b9 commit a2169a1
Show file tree
Hide file tree
Showing 102 changed files with 2,372 additions and 890 deletions.
4 changes: 0 additions & 4 deletions .env.production

This file was deleted.

1 change: 1 addition & 0 deletions .nvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
v20.17.0
75 changes: 22 additions & 53 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,61 +1,30 @@
# docker build -t gen3ff .
# docker run -p 3000:3000 -it gen3ff
# for Macbook silicon M1/m2 uncomment the following lines and comment quay.io/cdis/ubuntu:20.04:
#FROM arm64v8/ubuntu:20.04 as build
# Build stage
FROM node:20-slim AS builder

FROM quay.io/cdis/ubuntu:20.04 as build

ARG NODE_VERSION=20
WORKDIR /gen3

ENV DEBIAN_FRONTEND=noninteractive
COPY ./package.json ./package-lock.json ./next.config.js ./tsconfig.json ./.env.development ./tailwind.config.js ./postcss.config.js ./
RUN npm ci
COPY ./src ./src
COPY ./public ./public
COPY ./config ./config
RUN npm install @swc/core @napi-rs/magic-string && \
npm run build

ARG BASE_PATH
ARG NEXT_PUBLIC_PORTAL_BASENAME
ENV NPM_CONFIG_PREFIX=/home/node/.npm-global
ENV PATH=$PATH:/home/node/.npm-global/bin
# Production stage
FROM node:20-slim AS runner

WORKDIR /gen3
ENV PORT=3000

RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential \
libssl1.1 \
libgnutls30 \
ca-certificates \
curl \
git \
gnupg \
nginx \
python3 \
time \
vim \
&& mkdir -p /etc/apt/keyrings \
&& curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg \
&& echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_$NODE_VERSION.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list \
&& apt-get update \
&& apt-get install -y nodejs \
&& apt-get clean \
&& rm -rf /var/src/apt/lists/* \
&& ln -sf /dev/stdout /var/log/nginx/access.log \
&& ln -sf /dev/stderr /var/log/nginx/error.log \
&& npm install -g [email protected]
RUN addgroup --system --gid 1001 nextjs && \
adduser --system --uid 1001 nextjs

RUN addgroup --system --gid 1001 nextjs && adduser --system --uid 1001 nextjs
COPY ./package.json ./package-lock.json ./
COPY ./package-lock.json ./
COPY ./src ./src
COPY ./public ./public
COPY ./config ./config
COPY ./next.config.js ./
COPY ./tsconfig.json ./
COPY ./.env.development ./
COPY ./.env.production ./
COPY ./tailwind.config.js ./
COPY ./postcss.config.js ./
COPY ./start.sh ./
RUN npm ci
RUN npm install \
"@swc/core" \
"@napi-rs/magic-string"
RUN npm run build
COPY --from=builder /gen3/config ./config
COPY --from=builder /gen3/public ./public
COPY --from=builder /gen3/.next/standalone ./
COPY --from=builder /gen3/.next/static ./.next/static

USER nextjs
ENV PORT=3000
CMD bash ./start.sh
CMD ["node", "server.js"]
32 changes: 32 additions & 0 deletions config/brh/dataLibrary.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
{
"useAPI": true,
"actions": [
{
"id": "exportTerra",
"label": "Export to Terra",
"rules": [
{
"field": "type",
"operator": "equals",
"value": "terraform"
},
{
"field": "type",
"operator": "count",
"value": 1
}
]
},
{
"id": "exportZip",
"label": "Export to ZIP",
"rules": [
{
"field": "type",
"operator": "equals",
"value": "csv"
}
]
}
]
}
Loading

0 comments on commit a2169a1

Please sign in to comment.