AutoGPT/autogpt_platform/market/Dockerfile

69 lines
2.0 KiB
Docker
Raw Normal View History

FROM python:3.11-slim-buster AS builder
feat(rnd) Agent Marketplace MVP (#7657) * Added listing, sorting, filtering and ordering of agents * feat(market): general upkeep for vscode and small docs * feat(market): most of search * fix(market): hinting on the sort was weird + linting * feat(market): migrations and schema updates * lint(market): autolint * feat(market): better search * feat(market): file download * feat(market): analytics of downloads * Added tracking of views * changed all imports to be fully qualified * Upgrade sentry sdk * Added an admin endpoint to submit new agents * fixes * Added endpoint that just tracks download * Starting adding the marketplace page * Marketplace client * Create template of the marketplace page * Updated client * fix(market): debug port * feat(market): agents by downloads * fix(market, builder): hook up frontend and backend * feat(builder, market): build a "better" market page that loads data * feat(builder): updated search (working) and page (kinda working) * feat(builder): add a feature agents ui (not backed yet) * feat(builder): improve detail page content * Added run script * Added pre populate database command * Add AnalyticsTracker on create agent * Add download counts for top agents * Add hb page prometheus metrics * Added featured agents funcitonality * renamed endpoint to health * Adding download flow * normalised api routes * update readme * feat(market) : default featured * formatting * revert changes to autogpt and forge * Updated Readme * Eerror when creating an agent from a template installed from (#7697) fix creating graph from template * Add dockerfile * z level fix * Updated env vars * updated populate url * formatting * fixed linting error * Set defaults * Allow only next.js dev server * fixed url * removed graph reassignment as due to change in master --------- Co-authored-by: Nicholas Tindle <nicholas.tindle@agpt.co>
2024-08-05 14:51:17 +00:00
# Set environment variables
ENV PYTHONDONTWRITEBYTECODE 1
ENV PYTHONUNBUFFERED 1
WORKDIR /app
# Install build dependencies
feat(rnd) Agent Marketplace MVP (#7657) * Added listing, sorting, filtering and ordering of agents * feat(market): general upkeep for vscode and small docs * feat(market): most of search * fix(market): hinting on the sort was weird + linting * feat(market): migrations and schema updates * lint(market): autolint * feat(market): better search * feat(market): file download * feat(market): analytics of downloads * Added tracking of views * changed all imports to be fully qualified * Upgrade sentry sdk * Added an admin endpoint to submit new agents * fixes * Added endpoint that just tracks download * Starting adding the marketplace page * Marketplace client * Create template of the marketplace page * Updated client * fix(market): debug port * feat(market): agents by downloads * fix(market, builder): hook up frontend and backend * feat(builder, market): build a "better" market page that loads data * feat(builder): updated search (working) and page (kinda working) * feat(builder): add a feature agents ui (not backed yet) * feat(builder): improve detail page content * Added run script * Added pre populate database command * Add AnalyticsTracker on create agent * Add download counts for top agents * Add hb page prometheus metrics * Added featured agents funcitonality * renamed endpoint to health * Adding download flow * normalised api routes * update readme * feat(market) : default featured * formatting * revert changes to autogpt and forge * Updated Readme * Eerror when creating an agent from a template installed from (#7697) fix creating graph from template * Add dockerfile * z level fix * Updated env vars * updated populate url * formatting * fixed linting error * Set defaults * Allow only next.js dev server * fixed url * removed graph reassignment as due to change in master --------- Co-authored-by: Nicholas Tindle <nicholas.tindle@agpt.co>
2024-08-05 14:51:17 +00:00
RUN apt-get update \
&& apt-get install -y build-essential curl ffmpeg wget libcurl4-gnutls-dev libexpat1-dev gettext libz-dev libssl-dev postgresql-client git \
feat(rnd) Agent Marketplace MVP (#7657) * Added listing, sorting, filtering and ordering of agents * feat(market): general upkeep for vscode and small docs * feat(market): most of search * fix(market): hinting on the sort was weird + linting * feat(market): migrations and schema updates * lint(market): autolint * feat(market): better search * feat(market): file download * feat(market): analytics of downloads * Added tracking of views * changed all imports to be fully qualified * Upgrade sentry sdk * Added an admin endpoint to submit new agents * fixes * Added endpoint that just tracks download * Starting adding the marketplace page * Marketplace client * Create template of the marketplace page * Updated client * fix(market): debug port * feat(market): agents by downloads * fix(market, builder): hook up frontend and backend * feat(builder, market): build a "better" market page that loads data * feat(builder): updated search (working) and page (kinda working) * feat(builder): add a feature agents ui (not backed yet) * feat(builder): improve detail page content * Added run script * Added pre populate database command * Add AnalyticsTracker on create agent * Add download counts for top agents * Add hb page prometheus metrics * Added featured agents funcitonality * renamed endpoint to health * Adding download flow * normalised api routes * update readme * feat(market) : default featured * formatting * revert changes to autogpt and forge * Updated Readme * Eerror when creating an agent from a template installed from (#7697) fix creating graph from template * Add dockerfile * z level fix * Updated env vars * updated populate url * formatting * fixed linting error * Set defaults * Allow only next.js dev server * fixed url * removed graph reassignment as due to change in master --------- Co-authored-by: Nicholas Tindle <nicholas.tindle@agpt.co>
2024-08-05 14:51:17 +00:00
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
feat(rnd) Agent Marketplace MVP (#7657) * Added listing, sorting, filtering and ordering of agents * feat(market): general upkeep for vscode and small docs * feat(market): most of search * fix(market): hinting on the sort was weird + linting * feat(market): migrations and schema updates * lint(market): autolint * feat(market): better search * feat(market): file download * feat(market): analytics of downloads * Added tracking of views * changed all imports to be fully qualified * Upgrade sentry sdk * Added an admin endpoint to submit new agents * fixes * Added endpoint that just tracks download * Starting adding the marketplace page * Marketplace client * Create template of the marketplace page * Updated client * fix(market): debug port * feat(market): agents by downloads * fix(market, builder): hook up frontend and backend * feat(builder, market): build a "better" market page that loads data * feat(builder): updated search (working) and page (kinda working) * feat(builder): add a feature agents ui (not backed yet) * feat(builder): improve detail page content * Added run script * Added pre populate database command * Add AnalyticsTracker on create agent * Add download counts for top agents * Add hb page prometheus metrics * Added featured agents funcitonality * renamed endpoint to health * Adding download flow * normalised api routes * update readme * feat(market) : default featured * formatting * revert changes to autogpt and forge * Updated Readme * Eerror when creating an agent from a template installed from (#7697) fix creating graph from template * Add dockerfile * z level fix * Updated env vars * updated populate url * formatting * fixed linting error * Set defaults * Allow only next.js dev server * fixed url * removed graph reassignment as due to change in master --------- Co-authored-by: Nicholas Tindle <nicholas.tindle@agpt.co>
2024-08-05 14:51:17 +00:00
ENV POETRY_VERSION=1.8.3 \
POETRY_HOME="/opt/poetry" \
POETRY_NO_INTERACTION=1 \
POETRY_VIRTUALENVS_CREATE=false \
PATH="$POETRY_HOME/bin:$PATH"
# Upgrade pip and setuptools to fix security vulnerabilities
RUN pip3 install --upgrade pip setuptools
feat(rnd) Agent Marketplace MVP (#7657) * Added listing, sorting, filtering and ordering of agents * feat(market): general upkeep for vscode and small docs * feat(market): most of search * fix(market): hinting on the sort was weird + linting * feat(market): migrations and schema updates * lint(market): autolint * feat(market): better search * feat(market): file download * feat(market): analytics of downloads * Added tracking of views * changed all imports to be fully qualified * Upgrade sentry sdk * Added an admin endpoint to submit new agents * fixes * Added endpoint that just tracks download * Starting adding the marketplace page * Marketplace client * Create template of the marketplace page * Updated client * fix(market): debug port * feat(market): agents by downloads * fix(market, builder): hook up frontend and backend * feat(builder, market): build a "better" market page that loads data * feat(builder): updated search (working) and page (kinda working) * feat(builder): add a feature agents ui (not backed yet) * feat(builder): improve detail page content * Added run script * Added pre populate database command * Add AnalyticsTracker on create agent * Add download counts for top agents * Add hb page prometheus metrics * Added featured agents funcitonality * renamed endpoint to health * Adding download flow * normalised api routes * update readme * feat(market) : default featured * formatting * revert changes to autogpt and forge * Updated Readme * Eerror when creating an agent from a template installed from (#7697) fix creating graph from template * Add dockerfile * z level fix * Updated env vars * updated populate url * formatting * fixed linting error * Set defaults * Allow only next.js dev server * fixed url * removed graph reassignment as due to change in master --------- Co-authored-by: Nicholas Tindle <nicholas.tindle@agpt.co>
2024-08-05 14:51:17 +00:00
RUN pip3 install poetry
# Copy and install dependencies
COPY autogpt_platform/autogpt_libs /app/autogpt_platform/autogpt_libs
COPY autogpt_platform/market/poetry.lock autogpt_platform/market/pyproject.toml /app/autogpt_platform/market/
WORKDIR /app/autogpt_platform/market
RUN poetry config virtualenvs.create false \
&& poetry install --no-interaction --no-ansi
# Generate Prisma client
COPY autogpt_platform/market /app/autogpt_platform/market
RUN poetry config virtualenvs.create false \
&& poetry run prisma generate
feat(rnd) Agent Marketplace MVP (#7657) * Added listing, sorting, filtering and ordering of agents * feat(market): general upkeep for vscode and small docs * feat(market): most of search * fix(market): hinting on the sort was weird + linting * feat(market): migrations and schema updates * lint(market): autolint * feat(market): better search * feat(market): file download * feat(market): analytics of downloads * Added tracking of views * changed all imports to be fully qualified * Upgrade sentry sdk * Added an admin endpoint to submit new agents * fixes * Added endpoint that just tracks download * Starting adding the marketplace page * Marketplace client * Create template of the marketplace page * Updated client * fix(market): debug port * feat(market): agents by downloads * fix(market, builder): hook up frontend and backend * feat(builder, market): build a "better" market page that loads data * feat(builder): updated search (working) and page (kinda working) * feat(builder): add a feature agents ui (not backed yet) * feat(builder): improve detail page content * Added run script * Added pre populate database command * Add AnalyticsTracker on create agent * Add download counts for top agents * Add hb page prometheus metrics * Added featured agents funcitonality * renamed endpoint to health * Adding download flow * normalised api routes * update readme * feat(market) : default featured * formatting * revert changes to autogpt and forge * Updated Readme * Eerror when creating an agent from a template installed from (#7697) fix creating graph from template * Add dockerfile * z level fix * Updated env vars * updated populate url * formatting * fixed linting error * Set defaults * Allow only next.js dev server * fixed url * removed graph reassignment as due to change in master --------- Co-authored-by: Nicholas Tindle <nicholas.tindle@agpt.co>
2024-08-05 14:51:17 +00:00
FROM python:3.11-slim-buster AS server_dependencies
feat(rnd) Agent Marketplace MVP (#7657) * Added listing, sorting, filtering and ordering of agents * feat(market): general upkeep for vscode and small docs * feat(market): most of search * fix(market): hinting on the sort was weird + linting * feat(market): migrations and schema updates * lint(market): autolint * feat(market): better search * feat(market): file download * feat(market): analytics of downloads * Added tracking of views * changed all imports to be fully qualified * Upgrade sentry sdk * Added an admin endpoint to submit new agents * fixes * Added endpoint that just tracks download * Starting adding the marketplace page * Marketplace client * Create template of the marketplace page * Updated client * fix(market): debug port * feat(market): agents by downloads * fix(market, builder): hook up frontend and backend * feat(builder, market): build a "better" market page that loads data * feat(builder): updated search (working) and page (kinda working) * feat(builder): add a feature agents ui (not backed yet) * feat(builder): improve detail page content * Added run script * Added pre populate database command * Add AnalyticsTracker on create agent * Add download counts for top agents * Add hb page prometheus metrics * Added featured agents funcitonality * renamed endpoint to health * Adding download flow * normalised api routes * update readme * feat(market) : default featured * formatting * revert changes to autogpt and forge * Updated Readme * Eerror when creating an agent from a template installed from (#7697) fix creating graph from template * Add dockerfile * z level fix * Updated env vars * updated populate url * formatting * fixed linting error * Set defaults * Allow only next.js dev server * fixed url * removed graph reassignment as due to change in master --------- Co-authored-by: Nicholas Tindle <nicholas.tindle@agpt.co>
2024-08-05 14:51:17 +00:00
WORKDIR /app
# Upgrade pip and setuptools to fix security vulnerabilities
RUN pip3 install --upgrade pip setuptools
# Copy only necessary files from builder
COPY --from=builder /app /app
COPY --from=builder /usr/local/lib/python3.11 /usr/local/lib/python3.11
COPY --from=builder /usr/local/bin /usr/local/bin
# Copy Prisma binaries
COPY --from=builder /root/.cache/prisma-python/binaries /root/.cache/prisma-python/binaries
ENV PATH="/app/.venv/bin:$PATH"
RUN mkdir -p /app/autogpt_platform/autogpt_libs
RUN mkdir -p /app/autogpt_platform/market
COPY autogpt_platform/autogpt_libs /app/autogpt_platform/autogpt_libs
COPY autogpt_platform/market /app/autogpt_platform/market
WORKDIR /app/autogpt_platform/market
feat(rnd) Agent Marketplace MVP (#7657) * Added listing, sorting, filtering and ordering of agents * feat(market): general upkeep for vscode and small docs * feat(market): most of search * fix(market): hinting on the sort was weird + linting * feat(market): migrations and schema updates * lint(market): autolint * feat(market): better search * feat(market): file download * feat(market): analytics of downloads * Added tracking of views * changed all imports to be fully qualified * Upgrade sentry sdk * Added an admin endpoint to submit new agents * fixes * Added endpoint that just tracks download * Starting adding the marketplace page * Marketplace client * Create template of the marketplace page * Updated client * fix(market): debug port * feat(market): agents by downloads * fix(market, builder): hook up frontend and backend * feat(builder, market): build a "better" market page that loads data * feat(builder): updated search (working) and page (kinda working) * feat(builder): add a feature agents ui (not backed yet) * feat(builder): improve detail page content * Added run script * Added pre populate database command * Add AnalyticsTracker on create agent * Add download counts for top agents * Add hb page prometheus metrics * Added featured agents funcitonality * renamed endpoint to health * Adding download flow * normalised api routes * update readme * feat(market) : default featured * formatting * revert changes to autogpt and forge * Updated Readme * Eerror when creating an agent from a template installed from (#7697) fix creating graph from template * Add dockerfile * z level fix * Updated env vars * updated populate url * formatting * fixed linting error * Set defaults * Allow only next.js dev server * fixed url * removed graph reassignment as due to change in master --------- Co-authored-by: Nicholas Tindle <nicholas.tindle@agpt.co>
2024-08-05 14:51:17 +00:00
FROM server_dependencies AS server
feat(rnd) Agent Marketplace MVP (#7657) * Added listing, sorting, filtering and ordering of agents * feat(market): general upkeep for vscode and small docs * feat(market): most of search * fix(market): hinting on the sort was weird + linting * feat(market): migrations and schema updates * lint(market): autolint * feat(market): better search * feat(market): file download * feat(market): analytics of downloads * Added tracking of views * changed all imports to be fully qualified * Upgrade sentry sdk * Added an admin endpoint to submit new agents * fixes * Added endpoint that just tracks download * Starting adding the marketplace page * Marketplace client * Create template of the marketplace page * Updated client * fix(market): debug port * feat(market): agents by downloads * fix(market, builder): hook up frontend and backend * feat(builder, market): build a "better" market page that loads data * feat(builder): updated search (working) and page (kinda working) * feat(builder): add a feature agents ui (not backed yet) * feat(builder): improve detail page content * Added run script * Added pre populate database command * Add AnalyticsTracker on create agent * Add download counts for top agents * Add hb page prometheus metrics * Added featured agents funcitonality * renamed endpoint to health * Adding download flow * normalised api routes * update readme * feat(market) : default featured * formatting * revert changes to autogpt and forge * Updated Readme * Eerror when creating an agent from a template installed from (#7697) fix creating graph from template * Add dockerfile * z level fix * Updated env vars * updated populate url * formatting * fixed linting error * Set defaults * Allow only next.js dev server * fixed url * removed graph reassignment as due to change in master --------- Co-authored-by: Nicholas Tindle <nicholas.tindle@agpt.co>
2024-08-05 14:51:17 +00:00
ENV DATABASE_URL=""
ENV PORT=8015
feat(rnd) Agent Marketplace MVP (#7657) * Added listing, sorting, filtering and ordering of agents * feat(market): general upkeep for vscode and small docs * feat(market): most of search * fix(market): hinting on the sort was weird + linting * feat(market): migrations and schema updates * lint(market): autolint * feat(market): better search * feat(market): file download * feat(market): analytics of downloads * Added tracking of views * changed all imports to be fully qualified * Upgrade sentry sdk * Added an admin endpoint to submit new agents * fixes * Added endpoint that just tracks download * Starting adding the marketplace page * Marketplace client * Create template of the marketplace page * Updated client * fix(market): debug port * feat(market): agents by downloads * fix(market, builder): hook up frontend and backend * feat(builder, market): build a "better" market page that loads data * feat(builder): updated search (working) and page (kinda working) * feat(builder): add a feature agents ui (not backed yet) * feat(builder): improve detail page content * Added run script * Added pre populate database command * Add AnalyticsTracker on create agent * Add download counts for top agents * Add hb page prometheus metrics * Added featured agents funcitonality * renamed endpoint to health * Adding download flow * normalised api routes * update readme * feat(market) : default featured * formatting * revert changes to autogpt and forge * Updated Readme * Eerror when creating an agent from a template installed from (#7697) fix creating graph from template * Add dockerfile * z level fix * Updated env vars * updated populate url * formatting * fixed linting error * Set defaults * Allow only next.js dev server * fixed url * removed graph reassignment as due to change in master --------- Co-authored-by: Nicholas Tindle <nicholas.tindle@agpt.co>
2024-08-05 14:51:17 +00:00
CMD ["poetry", "run", "app"]