-
Notifications
You must be signed in to change notification settings - Fork 57
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #61 from tolak/game-tee
Add TEE support for GAME agents
- Loading branch information
Showing
6 changed files
with
129 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
# .dockerignore | ||
|
||
# Ignore node_modules from the build context | ||
node_modules | ||
|
||
# Ignore logs and temporary files | ||
*.log | ||
*.tmp | ||
.DS_Store | ||
|
||
# Ignore Git files and metadata | ||
.git | ||
.gitignore | ||
|
||
# Ignore IDE and editor config files | ||
.vscode | ||
.idea | ||
*.swp | ||
|
||
# Ignore build artifacts from the host | ||
dist | ||
build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
# Use a specific Node.js version for better reproducibility | ||
FROM node:23.3.0-slim AS builder | ||
|
||
# Install necessary build tools | ||
RUN apt-get update && \ | ||
apt-get upgrade -y && \ | ||
apt-get install -y \ | ||
git \ | ||
python3 \ | ||
python3-pip \ | ||
curl \ | ||
node-gyp \ | ||
ffmpeg \ | ||
libtool-bin \ | ||
autoconf \ | ||
automake \ | ||
libopus-dev \ | ||
make \ | ||
g++ \ | ||
build-essential \ | ||
libcairo2-dev \ | ||
libjpeg-dev \ | ||
libpango1.0-dev \ | ||
libgif-dev \ | ||
openssl \ | ||
libssl-dev libsecret-1-dev && \ | ||
apt-get clean && \ | ||
rm -rf /var/lib/apt/lists/* | ||
|
||
# Set Python 3 as the default python | ||
RUN ln -sf /usr/bin/python3 /usr/bin/python | ||
|
||
# Set the working directory | ||
WORKDIR /app | ||
|
||
# Copy application code | ||
COPY . . | ||
|
||
# Install dependencies | ||
RUN npm install --no-frozen-lockfile | ||
|
||
# Install TypeScript globally | ||
RUN npm install -g typescript | ||
|
||
# Build the project | ||
RUN npm run build && npm prune --production | ||
|
||
# Final runtime image | ||
FROM node:23.3.0-slim | ||
|
||
# Install runtime dependencies | ||
RUN apt-get update && \ | ||
apt-get install -y \ | ||
git \ | ||
python3 \ | ||
ffmpeg && \ | ||
apt-get clean && \ | ||
rm -rf /var/lib/apt/lists/* | ||
|
||
# Set the working directory | ||
WORKDIR /app | ||
|
||
# Copy built artifacts and production dependencies from the builder stage | ||
COPY --from=builder /app/package.json ./ | ||
COPY --from=builder /app/package-lock.json ./ | ||
COPY --from=builder /app/node_modules ./node_modules | ||
COPY --from=builder /app/dist ./dist | ||
|
||
# Expose necessary ports | ||
# EXPOSE 3000 | ||
|
||
# Command to start the application | ||
CMD ["npm", "start"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
services: | ||
game-starter: | ||
image: virtuals-game-starter | ||
build: | ||
context: . | ||
dockerfile: Dockerfile | ||
platform: linux/amd64 | ||
environment: | ||
- API_KEY= | ||
- WEATHER_API_KEY= | ||
- OPENAI_API_KEY= | ||
- OPENAI_BASE_URL= | ||
- botToken= | ||
volumes: | ||
- /var/run/tappd.sock:/var/run/tappd.sock | ||
- virtuals:/app | ||
restart: always | ||
|
||
volumes: | ||
virtuals: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters