Skip to content
This repository has been archived by the owner on Feb 27, 2023. It is now read-only.

implement docker / docker-compose #22

Merged
merged 1 commit into from
Mar 2, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
FROM keymetrics/pm2:latest-alpine

# Bundle APP files
COPY . .

# Install app dependencies
ENV NPM_CONFIG_LOGLEVEL warn
RUN npm install --production

CMD [ "pm2-runtime", "app.js" ]
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ Testing:
Maybe Later:
- support multiple domains
- support delete
- docker deployment
- ~~docker deployment~~
- reduce code base, if possible
http://ignorethecode.net/blog/2010/02/02/removing-features/

Expand Down
14 changes: 14 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
version: '2'

services:
void-mail:
build: .
ports:
- "3000:3000"
environment:
DOMAIN: example.com
IMAP_SERVER: mail.example.com
IMAP_USER: void@example.com
IMAP_PASSWORD: changemehard
DELETE_MAILS_OLDER_THAN_DAYS: 30

20 changes: 20 additions & 0 deletions docs/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,3 +53,23 @@ pm2 --name email start npm -- start --watch
4. Once you did this, you can try to reboot things.
- Reboot your system and check if void-mail gets started. (`reboot`)
- Kill node app instance and see if gets respawned (ie `kill -9 ``pgrep node`` `)

# Self-Hosted: docker / docker-compose

1. clone this repository

```
git clone https://github.com/synox/void-mail.git
```

2. change docker-compose.yml accordingly to your needs

```
vi docker-compose.yml
```

3. run it

```
docker-compose up -d
```