forked from oist/optinist
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
279d77c
commit cb4e068
Showing
10 changed files
with
142 additions
and
81 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,24 @@ | ||
FROM --platform=linux/amd64 python:3.8.16-slim | ||
|
||
WORKDIR /app | ||
|
||
RUN mkdir -p /root/miniconda3 && \ | ||
apt-get --allow-releaseinfo-change update && \ | ||
apt-get install --no-install-recommends -y wget && \ | ||
wget -q https://repo.anaconda.com/miniconda/Miniconda3-py39_4.12.0-Linux-x86_64.sh -O ~/miniconda3/miniconda.sh && \ | ||
apt-get purge wget -y && apt-get autoremove -y && apt-get clean && \ | ||
bash /root/miniconda3/miniconda.sh -b -u -p /root/miniconda3 && \ | ||
rm /root/miniconda3/miniconda.sh && \ | ||
export PATH="$PATH:/root/miniconda3/bin" && \ | ||
conda upgrade -y --all && \ | ||
conda config --set channel_priority strict && \ | ||
conda clean -y --tarballs | ||
|
||
ENV PATH $PATH:/root/miniconda3/bin | ||
|
||
COPY pyproject.toml . | ||
|
||
RUN pip3 install --no-cache-dir --upgrade pip && \ | ||
pip3 install --no-cache-dir -e '.[dev]' | ||
|
||
EXPOSE 8000 |
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 |
---|---|---|
@@ -1,12 +1,13 @@ | ||
FROM --platform=linux/amd64 python:3.8.16-slim | ||
|
||
COPY pyproject.toml /app/pyproject.toml | ||
WORKDIR /app | ||
|
||
RUN apt-get --allow-releaseinfo-change update && \ | ||
apt-get install --no-install-recommends -y git gcc g++ libgl1 && \ | ||
pip3 install --no-cache-dir --upgrade pip && \ | ||
pip3 install --no-cache-dir -e 'app/.[test]' && \ | ||
apt-get purge git -y && apt-get autoremove -y && apt-get clean && rm -rf /root/.cache/pip/* | ||
apt-get purge git -y && apt-get autoremove -y && apt-get clean | ||
|
||
WORKDIR /app | ||
ENTRYPOINT ["python3", "-m", "pytest", "-s", "."] | ||
COPY pyproject.toml . | ||
RUN pip3 install --no-cache-dir --upgrade pip && \ | ||
pip3 install --no-cache-dir -e '.[test]' | ||
|
||
ENTRYPOINT ["python3", "-m", "pytest", "-s", "."] |
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,25 @@ | ||
version: "3" | ||
|
||
services: | ||
studio-dev-be: | ||
build: | ||
context: . | ||
dockerfile: Dockerfile.dev | ||
working_dir: /app | ||
volumes: | ||
- .:/app | ||
ports: | ||
- "8000:8000" | ||
command: python main.py --reload --host 0.0.0.0 --port 8000 | ||
environment: | ||
PYTHONPATH: /app/ | ||
TZ: Asia/Tokyo | ||
|
||
studio-dev-fe: | ||
image: node:16.20.1-alpine | ||
working_dir: /app/frontend | ||
volumes: | ||
- ./frontend/:/app/frontend/ | ||
ports: | ||
- "3000:3000" | ||
command: ash -c 'yarn install && yarn 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
version: "3.8" | ||
|
||
services: | ||
test_studio: | ||
image: test_studio | ||
container_name: test_studio | ||
build: | ||
context: . | ||
dockerfile: Dockerfile.test | ||
environment: | ||
PYTHONPATH: . | ||
TZ: Asia/Tokyo | ||
volumes: | ||
- ./studio:/app/studio | ||
- ./conda/yaml:/app/conda/yaml | ||
- ./studio/test_data:/tmp/studio | ||
|
||
test_studio_frontend: | ||
image: test_studio_frontend | ||
container_name: test_studio_frontend | ||
build: | ||
context: ./frontend | ||
dockerfile: Dockerfile.test | ||
environment: | ||
TZ: Asia/Tokyo | ||
command: yarn test:ci | ||
|
||
build_studio_frontend: | ||
image: build_studio_frontend | ||
container_name: build_studio_frontend | ||
build: | ||
context: ./frontend | ||
dockerfile: Dockerfile.build | ||
environment: | ||
TZ: Asia/Tokyo | ||
volumes: | ||
- ./frontend/build:/app/build:cached |
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 |
---|---|---|
@@ -1,36 +1,14 @@ | ||
version: "3.8" | ||
version: "3" | ||
|
||
services: | ||
test_studio: | ||
image: test_studio | ||
container_name: test_studio | ||
studio: | ||
build: | ||
context: . | ||
dockerfile: Dockerfile-test | ||
environment: | ||
PYTHONPATH: . | ||
TZ: Asia/Tokyo | ||
volumes: | ||
- ./studio:/app/studio | ||
- ./conda/yaml:/app/conda/yaml | ||
- ./studio/test_data:/tmp/studio | ||
|
||
test_studio_frontend: | ||
image: test_studio_frontend | ||
container_name: test_studio_frontend | ||
build: | ||
context: ./frontend | ||
dockerfile: Dockerfile-test | ||
environment: | ||
TZ: Asia/Tokyo | ||
command: yarn test:ci | ||
|
||
build_studio_frontend: | ||
image: build_studio_frontend | ||
container_name: build_studio_frontend | ||
build: | ||
context: ./frontend | ||
dockerfile: Dockerfile-build | ||
dockerfile: Dockerfile | ||
working_dir: /app | ||
ports: | ||
- "8000:8000" | ||
command: python main.py --host 0.0.0.0 --port 8000 | ||
environment: | ||
PYTHONPATH: /app/ | ||
TZ: Asia/Tokyo | ||
volumes: | ||
- ./frontend/build:/app/build:cached |
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 |
---|---|---|
|
@@ -8,4 +8,4 @@ ENV GENERATE_SOURCEMAP false | |
|
||
RUN yarn install | ||
|
||
CMD yarn build | ||
CMD yarn 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