Skip to content

Commit

Permalink
Merge pull request #503 from credebl/qa-prod-9-2-2024
Browse files Browse the repository at this point in the history
merge: QA to Main branch
  • Loading branch information
vivekayanworks authored Feb 10, 2024
2 parents 62e3e40 + 51cd6e2 commit d62db42
Show file tree
Hide file tree
Showing 187 changed files with 6,741 additions and 2,487 deletions.
24 changes: 13 additions & 11 deletions Dockerfiles/Dockerfile.agent-provisioning
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
# Stage 1: Build the application
FROM node:18-alpine as build
# RUN npm install -g pnpm
# Install AWS CLI
# RUN apk update
# RUN apk add openssh-client
# RUN apk update
RUN addgroup -S nonroot \
&& adduser -S nonroot -G nonroot

USER nonroot


# RUN apk add aws-cli
RUN npm install -g pnpm --ignore-scripts \
RUN npm install --ignore-scripts -g pnpm \
&& apk update \
&& apk add openssh-client \
&& apk add aws-cli
Expand All @@ -18,7 +20,7 @@ WORKDIR /app
COPY package.json ./

# Install dependencies
RUN pnpm i
RUN pnpm i --ignore-scripts

# Copy the rest of the application code
COPY . .
Expand All @@ -32,12 +34,12 @@ RUN pnpm run build agent-provisioning

# Stage 2: Create the final image
FROM node:18-alpine as prod
# Install AWS CLI
# RUN apk update
# RUN apk add openssh-client
# RUN apk update
RUN addgroup -S nonroot \
&& adduser -S nonroot -G nonroot

USER nonroot
# RUN apk add aws-cli
RUN npm install -g pnpm --ignore-scripts \
RUN npm install --ignore-scripts -g pnpm \
&& apk update \
&& apk add openssh-client \
&& apk add aws-cli
Expand Down
17 changes: 13 additions & 4 deletions Dockerfiles/Dockerfile.agent-service
Original file line number Diff line number Diff line change
@@ -1,14 +1,19 @@
# Stage 1: Build the application
FROM node:18-alpine as build
RUN npm install -g pnpm

RUN addgroup -S nonroot \
&& adduser -S nonroot -G nonroot

USER nonroot
RUN npm install --ignore-scripts -g pnpm
# Set the working directory
WORKDIR /app

# Copy package.json and package-lock.json
COPY package.json ./

# Install dependencies
RUN pnpm i
RUN pnpm i --ignore-scripts

# Copy the rest of the application code
COPY . .
Expand All @@ -19,8 +24,12 @@ RUN pnpm run build agent-service

# Stage 2: Create the final image
FROM node:18-alpine
RUN npm install -g pnpm
# Set the working directory

RUN addgroup -S nonroot \
&& adduser -S nonroot -G nonroot

USER nonroot
RUN npm install --ignore-scripts -g pnpm
WORKDIR /app

# Copy the compiled code from the build stage
Expand Down
14 changes: 11 additions & 3 deletions Dockerfiles/Dockerfile.api-gateway
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
# Stage 1: Build the application
FROM node:18-alpine as build
RUN npm install -g pnpm
RUN addgroup -S nonroot \
&& adduser -S nonroot -G nonroot

USER nonroot
RUN npm install --ignore-scripts -g pnpm
# Set the working directory
WORKDIR /app

Expand All @@ -9,7 +13,7 @@ COPY package.json ./
# COPY package-lock.json ./

# Install dependencies
RUN pnpm i
RUN pnpm i --ignore-scripts

# Copy the rest of the application code
COPY . .
Expand All @@ -20,7 +24,11 @@ RUN pnpm run build api-gateway

# Stage 2: Create the final image
FROM node:18-alpine
RUN npm install -g pnpm
RUN addgroup -S nonroot \
&& adduser -S nonroot -G nonroot

USER nonroot
RUN npm install --ignore-scripts -g pnpm
# Set the working directory
WORKDIR /app

Expand Down
14 changes: 11 additions & 3 deletions Dockerfiles/Dockerfile.connection
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
# Stage 1: Build the application
FROM node:18-alpine as build
RUN npm install -g pnpm
RUN addgroup -S nonroot \
&& adduser -S nonroot -G nonroot

USER nonroot
RUN npm install --ignore-scripts -g pnpm
# Set the working directory
WORKDIR /app

Expand All @@ -9,7 +13,7 @@ COPY package.json ./
#COPY package-lock.json ./

# Install dependencies
RUN pnpm i
RUN pnpm i --ignore-scripts

# Copy the rest of the application code
COPY . .
Expand All @@ -20,7 +24,11 @@ RUN pnpm run build connection

# Stage 2: Create the final image
FROM node:18-alpine
RUN npm install -g pnpm
RUN addgroup -S nonroot \
&& adduser -S nonroot -G nonroot

USER nonroot
RUN npm install --ignore-scripts -g pnpm
# Set the working directory
WORKDIR /app

Expand Down
14 changes: 11 additions & 3 deletions Dockerfiles/Dockerfile.ecosystem
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
# Stage 1: Build the application
FROM node:18-alpine as build
RUN npm install -g pnpm
RUN addgroup -S nonroot \
&& adduser -S nonroot -G nonroot

USER nonroot
RUN npm install --ignore-scripts -g pnpm
# Set the working directory
WORKDIR /app

Expand All @@ -9,7 +13,7 @@ COPY package.json ./
#COPY package-lock.json ./

# Install dependencies
RUN pnpm i
RUN pnpm i --ignore-scripts

# Copy the rest of the application code
COPY . .
Expand All @@ -20,7 +24,11 @@ RUN pnpm run build ecosystem

# Stage 2: Create the final image
FROM node:18-alpine
RUN npm install -g pnpm
RUN addgroup -S nonroot \
&& adduser -S nonroot -G nonroot

USER nonroot
RUN npm install --ignore-scripts -g pnpm
# Set the working directory
WORKDIR /app

Expand Down
14 changes: 11 additions & 3 deletions Dockerfiles/Dockerfile.issuance
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
# Stage 1: Build the application
FROM node:18-alpine as build
RUN npm install -g pnpm
RUN addgroup -S nonroot \
&& adduser -S nonroot -G nonroot

USER nonroot
RUN npm install --ignore-scripts -g pnpm
# Set the working directory
WORKDIR /app

Expand All @@ -9,7 +13,7 @@ COPY package.json ./
#COPY package-lock.json ./

# Install dependencies
RUN pnpm i
RUN pnpm i --ignore-scripts

# Copy the rest of the application code
COPY . .
Expand All @@ -20,7 +24,11 @@ RUN pnpm run build issuance

# Stage 2: Create the final image
FROM node:18-alpine
RUN npm install -g pnpm
RUN addgroup -S nonroot \
&& adduser -S nonroot -G nonroot

USER nonroot
RUN npm install --ignore-scripts -g pnpm
# Set the working directory
WORKDIR /app

Expand Down
14 changes: 11 additions & 3 deletions Dockerfiles/Dockerfile.ledger
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
# Stage 1: Build the application
FROM node:18-alpine as build
RUN npm install -g pnpm
RUN addgroup -S nonroot \
&& adduser -S nonroot -G nonroot

USER nonroot
RUN npm install --ignore-scripts -g pnpm
# Set the working directory
WORKDIR /app

Expand All @@ -9,7 +13,7 @@ COPY package.json ./
#COPY package-lock.json ./

# Install dependencies
RUN pnpm i
RUN pnpm i --ignore-scripts

# Copy the rest of the application code
COPY . .
Expand All @@ -21,7 +25,11 @@ RUN npm run build ledger

# Stage 2: Create the final image
FROM node:18-alpine
RUN npm install -g pnpm
RUN addgroup -S nonroot \
&& adduser -S nonroot -G nonroot

USER nonroot
RUN npm install --ignore-scripts -g pnpm
# Set the working directory
WORKDIR /app

Expand Down
14 changes: 11 additions & 3 deletions Dockerfiles/Dockerfile.organization
Original file line number Diff line number Diff line change
@@ -1,14 +1,18 @@
# Stage 1: Build the application
FROM node:18-alpine as build
RUN npm install -g pnpm
RUN addgroup -S nonroot \
&& adduser -S nonroot -G nonroot

USER nonroot
RUN npm install --ignore-scripts -g pnpm
# Set the working directory
WORKDIR /app

# Copy package.json and package-lock.json
COPY package.json ./

# Install dependencies
RUN pnpm i
RUN pnpm i --ignore-scripts

# Copy the rest of the application code
COPY . .
Expand All @@ -20,7 +24,11 @@ RUN pnpm run build organization

# Stage 2: Create the final image
FROM node:18-alpine
RUN npm install -g pnpm
RUN addgroup -S nonroot \
&& adduser -S nonroot -G nonroot

USER nonroot
RUN npm install --ignore-scripts -g pnpm
# Set the working directory
WORKDIR /app

Expand Down
20 changes: 15 additions & 5 deletions Dockerfiles/Dockerfile.user
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
# Stage 1: Build the application
FROM node:18-slim as build
RUN npm install -g pnpm
RUN addgroup -S nonroot \
&& adduser -S nonroot -G nonroot

USER nonroot
RUN npm install --ignore-scripts -g pnpm

# We don't need the standalone Chromium
ENV PUPPETEER_SKIP_CHROMIUM_DOWNLOAD true
Expand All @@ -9,7 +13,7 @@ ENV PUPPETEER_SKIP_CHROMIUM_DOWNLOAD true
# Note: this installs the necessary libs to make the browser work with Puppeteer.
RUN apt-get update && apt-get install gnupg wget -y && \
wget --quiet --output-document=- https://dl-ssl.google.com/linux/linux_signing_key.pub | gpg --dearmor > /etc/apt/trusted.gpg.d/google-archive.gpg && \
sh -c 'echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google.list' && \
sh -c 'echo "deb [arch=amd64] https://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google.list' && \
apt-get update && \
apt-get install google-chrome-stable -y --no-install-recommends && \
rm -rf /var/lib/apt/lists/*
Expand All @@ -22,7 +26,7 @@ WORKDIR /app
COPY package.json ./

# Install dependencies
RUN pnpm install
RUN pnpm i --ignore-scripts

# Copy the rest of the application code
COPY . .
Expand All @@ -34,21 +38,27 @@ RUN pnpm run build user
# Stage 2: Create the final image
FROM node:18-slim

RUN addgroup -S nonroot \
&& adduser -S nonroot -G nonroot

USER nonroot

RUN npm install --ignore-scripts -g pnpm
# We don't need the standalone Chromium
ENV PUPPETEER_SKIP_CHROMIUM_DOWNLOAD true

# Install Google Chrome Stable and fonts
# Note: this installs the necessary libs to make the browser work with Puppeteer.
RUN apt-get update && apt-get install gnupg wget -y && \
wget --quiet --output-document=- https://dl-ssl.google.com/linux/linux_signing_key.pub | gpg --dearmor > /etc/apt/trusted.gpg.d/google-archive.gpg && \
sh -c 'echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google.list' && \
sh -c 'echo "deb [arch=amd64] https://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google.list' && \
apt-get update && \
apt-get install google-chrome-stable -y --no-install-recommends && \
rm -rf /var/lib/apt/lists/*

# Set the working directory
WORKDIR /app
RUN npm install -g pnpm


# Copy the compiled code from the build stage
COPY --from=build /app/dist/apps/user/ ./dist/apps/user/
Expand Down
Loading

0 comments on commit d62db42

Please sign in to comment.