From e32a254194828c85ad2aa5945d324913131b954c Mon Sep 17 00:00:00 2001 From: rodrigobustamante Date: Fri, 9 Oct 2020 18:09:23 -0300 Subject: [PATCH 1/3] Add .env example file and move configuration.yaml.default file to root folder --- .env.example | 3 +++ ...configuration.yaml.default => configuration.yaml.default | 0 docker-compose.yml | 6 +++--- 3 files changed, 6 insertions(+), 3 deletions(-) create mode 100644 .env.example rename src/configuration.yaml.default => configuration.yaml.default (100%) diff --git a/.env.example b/.env.example new file mode 100644 index 0000000..4edc0f3 --- /dev/null +++ b/.env.example @@ -0,0 +1,3 @@ +REPOSITORY-LOCATION= +CONFIG-LOCATION= +TIMEZONE= diff --git a/src/configuration.yaml.default b/configuration.yaml.default similarity index 100% rename from src/configuration.yaml.default rename to configuration.yaml.default diff --git a/docker-compose.yml b/docker-compose.yml index c573bb4..177d9b6 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -7,8 +7,8 @@ services: command: > node index.js volumes: - - :/usr/src/bot - - :/.store + - ${REPOSITORY_LOCATION}:/usr/src/bot + - ${CONFIG_LOCATION}:/.store environment: - - TZ= + - TZ=${TIMEZONE} restart: unless-stopped \ No newline at end of file From 61a80de8f98c2219e9a20cd6d07c28fa1cb3f3e7 Mon Sep 17 00:00:00 2001 From: rodrigobustamante Date: Fri, 9 Oct 2020 18:13:51 -0300 Subject: [PATCH 2/3] Update README.md --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index bc15d67..5060937 100644 --- a/README.md +++ b/README.md @@ -10,13 +10,13 @@ Clone this repository Enter the repository and run `npm install`. This will install all the required dependencies. ## Step 3 -Edit the `docker-compose.yml` file. +Make a copy from `.env.example` file and rename it `.env`. -Replace `` with the full path to your repository. +Add the full path of your repository on the `REPOSITORY_LOCATION` variable. -Replace `` with the directory in which you would like to store your configuration. +Add the directory in which you would like to store your configuration on the `CONFIG_LOCATION` variable. -Replace `` with your timezone. +Add your timezone on the `TIMEZONE` variable ## Step 4 Run the command `docker build -t librarian .` and then `docker-compose up -d` From 593049a3e24d073b86509c7f967668dd0c50ae8a Mon Sep 17 00:00:00 2001 From: rodrigobustamante Date: Fri, 9 Oct 2020 18:19:06 -0300 Subject: [PATCH 3/3] Rename .env variables on .env.example file --- .env.example | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.env.example b/.env.example index 4edc0f3..8f10b0e 100644 --- a/.env.example +++ b/.env.example @@ -1,3 +1,3 @@ -REPOSITORY-LOCATION= -CONFIG-LOCATION= +REPOSITORY_LOCATION= +CONFIG_LOCATION= TIMEZONE=