DataHungry Documents
  • Welcom to DataHungry Documents
  • Library
    • Apache Airflow
    • Apache Iceberge
    • Bardapi
    • Binance
    • Databricks
    • Datetime
    • dotenv
    • FastAPI
    • Logging
    • Langchain
    • Minio (S3)
    • MLflow
    • OpenCV
    • Optuna
    • os
    • Pyiceberg
    • Pyspark
    • Pytest
    • Schedule
    • Sklearn & SHAP
    • SQLAlchemy
    • transformers (huggingface)
    • Firebase Firestore
  • Course
    • Web Scraping
    • Streamlit
    • NLP
  • Utility
    • Docker
    • Google Sheet
  • SQL
    • Basic SQL Statements
    • PL/SQL
    • Stored Procedure & Function
  • Scala
    • Setup
    • Spark
  • Cloud
    • AWS
    • Google Cloud
Powered by GitBook
On this page
  • Dockerfile
  • docker-compose.yml
  1. Utility

Docker

Dockerfile

FROM python:3.10

WORKDIR /code/app

COPY ./requirements.txt /code/requirements.txt

RUN apt update
RUN apt install nano
RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt

COPY ./app /code/app

CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "8001"]

docker-compose.yml

version: "3.9"
services:
  app_name:
    image: image_name:version
    container_name: container_name
    volumes:
      - ./logs:/usr/src/app/logs 
    environment:
      DB_URL: ${DB_URL}
    restart: always
    ports:
      - 8001:8001
PreviousNLPNextGoogle Sheet

Last updated 1 year ago