From 9debfe7a842abb1bc0808f45e8a6ae8e9783403f Mon Sep 17 00:00:00 2001 From: ".notepunk." Date: Wed, 2 Oct 2024 23:38:24 +0200 Subject: [PATCH] introducing Docker - Dockerfile - docker compose --- Dockerfile | 16 ++++++++++++++++ docker-compose.yml | 17 +++++++++++++++++ 2 files changed, 33 insertions(+) create mode 100644 Dockerfile create mode 100644 docker-compose.yml diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..20da388 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,16 @@ +# Use the official Python 3.12 image from the Docker Hub +FROM python:3.12-slim + +# Set the working directory in the container +WORKDIR /app + +RUN pip install setuptools + +# Copy the rest of the application code into the container +COPY . . + +#RUN pip install nostr-dvm +RUN python setup.py install + +# Specify the command to run your application +CMD ["python3", "main.py"] diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..20cfdde --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,17 @@ +version: '3.8' + +services: + nostrdvm: # Name of the service + build: + context: . + dockerfile: Dockerfile + ports: + - "80:80" + environment: + - LNBITS_ADMIN_KEY = ${LNBITS_ADMIN_KEY} + - LNBITS_ADMIN_ID = ${LNBITS_WALLET_ID} + - LNBITS_HOST = ${LNBITS_HOST} + - NOSTDRESS_DOMAIN = ${NOSTDRESS_DOMAIN} + - NOSTR_BUILD_ACCOUNT_PK = ${NOSTR_BUILD_ACCOUNT_PK} + volumes: + - .:/app