Fix local website build (#1980)

* Fix Dockerfiles

* Use local build

* Copy front-end instead of cdn

* frontend

* Fix build
This commit is contained in:
Freddy Boulton 2022-08-09 10:25:03 -04:00 committed by GitHub
parent d7c1a9eec4
commit c49a4264df
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 2 deletions

View File

@ -11,7 +11,7 @@ COPY ./setup.py ./setup.py
COPY ./MANIFEST.in ./MANIFEST.in
COPY ./README.md ./README.md
COPY ./test ./test
RUN python setup.py install
RUN pip install .
WORKDIR /gradio
COPY ./website ./website
COPY ./demo ./demo

View File

@ -14,6 +14,7 @@ RUN npm i pnpm@6 -g
WORKDIR /gradio/ui
ENV NODE_OPTIONS="--max-old-space-size=4096"
RUN pnpm i
RUN pnpm build
RUN pnpm build:website
WORKDIR /gradio
COPY ./gradio ./gradio
@ -22,7 +23,7 @@ COPY ./setup.py ./setup.py
COPY ./MANIFEST.in ./MANIFEST.in
COPY ./README.md ./README.md
COPY ./test ./test
RUN python setup.py install
RUN pip install .
WORKDIR /gradio
COPY ./website ./website
WORKDIR /gradio/website/homepage