Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 0 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,6 @@ timeline_cache.json

*.sqlite

characters/

packages/core/src/providers/cache
packages/core/src/providers/cache/*
cache/*
Expand Down
1,521 changes: 0 additions & 1,521 deletions CHANGELOG.md

This file was deleted.

128 changes: 0 additions & 128 deletions CODE_OF_CONDUCT.md

This file was deleted.

129 changes: 0 additions & 129 deletions CONTRIBUTING.md

This file was deleted.

50 changes: 28 additions & 22 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
FROM node:23.3.0-slim AS builder

# Install pnpm globally and install necessary build tools
RUN npm install -g pnpm@9.4.0 && \
RUN npm install -g pnpm@9.15.1 && \
apt-get update && \
apt-get install -y git python3 make g++ && \
apt-get clean && \
Expand All @@ -15,41 +15,47 @@ RUN ln -s /usr/bin/python3 /usr/bin/python
WORKDIR /app

# Copy package.json and other configuration files
COPY package.json pnpm-lock.yaml pnpm-workspace.yaml .npmrc turbo.json ./
COPY package.json ./
COPY pnpm-lock.yaml ./
COPY tsconfig.json ./

# Copy the rest of the application code
COPY agent ./agent
COPY packages ./packages
COPY scripts ./scripts
COPY characters ./characters
COPY ./src ./src
COPY ./characters ./characters

# Install dependencies and build the project
RUN pnpm install \
&& pnpm build-docker \
&& pnpm prune --prod
RUN pnpm install
RUN pnpm build

# Create dist directory and set permissions
RUN mkdir -p /app/dist && \
chown -R node:node /app && \
chmod -R 755 /app

# Switch to node user
USER node

# Create a new stage for the final image
FROM node:23.3.0-slim

# Install runtime dependencies if needed
RUN npm install -g pnpm@9.4.0 && \
apt-get update && \
RUN npm install -g pnpm@9.15.1
RUN apt-get update && \
apt-get install -y git python3 && \
apt-get clean && \
rm -rf /var/lib/apt/lists/*

WORKDIR /app

# Copy built artifacts and production dependencies from the builder stage
COPY --from=builder /app/package.json ./
COPY --from=builder /app/pnpm-workspace.yaml ./
COPY --from=builder /app/.npmrc ./
COPY --from=builder /app/turbo.json ./
COPY --from=builder /app/node_modules ./node_modules
COPY --from=builder /app/agent ./agent
COPY --from=builder /app/packages ./packages
COPY --from=builder /app/scripts ./scripts
COPY --from=builder /app/characters ./characters

COPY --from=builder /app/package.json /app/
COPY --from=builder /app/node_modules /app/node_modules
COPY --from=builder /app/src /app/src
COPY --from=builder /app/characters /app/characters
COPY --from=builder /app/dist /app/dist
COPY --from=builder /app/tsconfig.json /app/
COPY --from=builder /app/pnpm-lock.yaml /app/

EXPOSE 3000
# Set the command to run the application
CMD ["pnpm", "start"]
CMD ["pnpm", "start", "--non-interactive"]
Loading
Loading