From 4c1aabacbfa467c1cb7d5402e25595fc98101234 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gabriel=20Zu=C3=B1iga?= Date: Wed, 25 Sep 2024 16:00:14 -0300 Subject: [PATCH 1/2] Update README.md I added more info to containerized section - Git Clone, this is the most easy way to get Dockerfile, docker-compose.yaml and package.json(i forget this file and i can't build the image) - Build the image, to check is every step is going okey, if something failed, people can see where step is failing instead of running from start to end in one run - run container, the same step as the original readme --- README.md | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 8069151..57222ab 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,17 @@ A self hostable service for sending ebooks to a Kobo or Kindle ereader through t 6. Start this service by running: `$ npm start` and access it on HTTP port 3001 ### Containerized - -1. Have Docker installed -2. Run `$ docker compose up` -3. Access the service on HTTP port 3001 +1. You need [Docker](https://www.docker.com/) and [docker-compose](https://docs.docker.com/compose/) installed +2. Clone this repo (you need Dockerfile, docker-compose.yaml and package.json in the same directory) +``` +git clone https://github.com/daniel-j/send2ereader.git +``` +3. Build the image +``` +docker compose build +``` +4. run container (-d to keep running in the background) +``` +docker compose up -d +``` +5. Access the service on HTTP, default port 3001 (http://localhost:3001) From b2eaef3fa89267fabf9871dce3a2e9172e29421d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gabriel=20Zu=C3=B1iga?= Date: Wed, 25 Sep 2024 16:23:02 -0300 Subject: [PATCH 2/2] Update docker-compose.yaml I delete version because is deprecated/obsolete I added "restart" because help to not start the container every boot I added also comment to explain how ports work in docker, this help when port 3001 is already used, and need to change for other --- docker-compose.yaml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/docker-compose.yaml b/docker-compose.yaml index 6b1a111..f3a82bb 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -1,9 +1,12 @@ -version: "3" services: send2ereader: build: context: . dockerfile: ./Dockerfile container_name: send2ereader + # Restart means, Automatic re-start the container after a shutdown unless manual stop container + restart: unless-stopped + # ports means, Bind external and internal docker ports, only change the external port, not the internal port + # Arquitecture: : ports: - 3001:3001