From c7de45f69ad87976f211ff448a5f8689b46cbed1 Mon Sep 17 00:00:00 2001 From: tienday <> Date: Tue, 5 Sep 2023 19:45:04 +0900 Subject: [PATCH] update docker settings. --- docker-compose.dev.yml | 6 ++++++ docker-compose.yml | 9 +++++++++ studio/config/docker/Dockerfile | 3 +++ studio/config/docker/Dockerfile.dev | 3 +++ 4 files changed, 21 insertions(+) diff --git a/docker-compose.dev.yml b/docker-compose.dev.yml index 45b9afed9..987575f1c 100644 --- a/docker-compose.dev.yml +++ b/docker-compose.dev.yml @@ -9,6 +9,8 @@ services: - studio/config/.env volumes: - db_data:/var/lib/mysql + environment: + TZ: Asia/Tokyo phpmyadmin: image: phpmyadmin @@ -18,6 +20,8 @@ services: - studio/config/.env ports: - 20080:80 + environment: + TZ: Asia/Tokyo studio-dev-be: build: @@ -43,6 +47,8 @@ services: ports: - "3000:3000" command: ash -c 'yarn install && yarn start' + environment: + TZ: Asia/Tokyo volumes: db_data: diff --git a/docker-compose.yml b/docker-compose.yml index c49854798..2caf1c951 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -9,20 +9,29 @@ services: - studio/config/.env volumes: - db_data:/var/lib/mysql + environment: + TZ: Asia/Tokyo + restart: always studio: build: context: . dockerfile: studio/config/docker/Dockerfile working_dir: /app + volumes: + - ../optinist-docker-volumes/.snakemake/:/app/.snakemake + - ../optinist-docker-volumes/logs/:/app/logs + - ../optinist-docker-volumes/studio_data/:/app/studio_data ports: - "8000:8000" command: bash -c "alembic upgrade head && python main.py --host 0.0.0.0 --port 8000" environment: PYTHONPATH: /app/ TZ: Asia/Tokyo + OPTINIST_DIR: /app/studio_data depends_on: - db + restart: always volumes: db_data: diff --git a/studio/config/docker/Dockerfile b/studio/config/docker/Dockerfile index f34d472df..fbe17121d 100644 --- a/studio/config/docker/Dockerfile +++ b/studio/config/docker/Dockerfile @@ -2,9 +2,12 @@ FROM --platform=linux/amd64 python:3.8.16-slim WORKDIR /app +RUN echo 'alias ll="ls -la"' >> ~/.bashrc + RUN mkdir -p /root/miniconda3 && \ apt-get --allow-releaseinfo-change update && \ apt-get install --no-install-recommends -y gcc g++ libgl1 libgl1-mesa-dev && \ + apt-get install --no-install-recommends -y procps iproute2 less vim && \ 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 && \ diff --git a/studio/config/docker/Dockerfile.dev b/studio/config/docker/Dockerfile.dev index 045851a48..c444aecbd 100644 --- a/studio/config/docker/Dockerfile.dev +++ b/studio/config/docker/Dockerfile.dev @@ -2,8 +2,11 @@ FROM --platform=linux/amd64 python:3.8.16-slim WORKDIR /app +RUN echo 'alias ll="ls -la"' >> ~/.bashrc + RUN mkdir -p /root/miniconda3 && \ apt-get --allow-releaseinfo-change update && \ + apt-get install --no-install-recommends -y procps iproute2 less vim && \ 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 && \