-
Notifications
You must be signed in to change notification settings - Fork 5
/
Containerfile
executable file
·58 lines (50 loc) · 1.27 KB
/
Containerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
# **Description:**
#
# My mutt configuration in a docker container
#
# **Running:**
#
# ```sh
# podman run -it --rm \
# -e TERM=xterm-256color \
# -e MUTT_NAME \
# -e MUTT_EMAIL \
# -e MUTT_PASS \
# -e MUTT_PGP_KEY \
# -v $HOME/.gnupg:/home/user/.gnupg \
# -v $HOME/dropbox/etc/signature:/home/user/.mutt/signature \
# -v $HOME/dropbox/etc/aliases:/home/user/.mutt/aliases \
# -v /etc/localtime:/etc/localtime:ro \
# cdrage/mutt-gmail
# ```
FROM debian:stable
LABEL maintainer="Charlie Drage <charlie@charliedrage.com>"
RUN apt-get update && apt-get install -y \
ca-certificates \
git \
lynx \
elinks \
mutt-patched \
vim \
msmtp \
urlview \
--no-install-recommends \
&& rm -rf /var/lib/apt/lists/*
ENV BROWSER lynx
RUN groupadd -g 1000 user \
&& useradd --create-home -d /home/user -g user -u 1000 user
USER user
ENV HOME /home/user
ENV TERM screen-256color
RUN mkdir -p $HOME/.mutt/cache/headers $HOME/.mutt/cache/bodies && touch $HOME/.mutt/certificates
ENV LANG C.UTF-8
#! copy over files
COPY entrypoint.sh /entrypoint.sh
COPY .mutt $HOME/.mutt
COPY .msmtprc $HOME/.msmtprc
USER root
RUN chown user:user /home/user/.msmtprc
USER user
RUN chmod 600 $HOME/.msmtprc
ENTRYPOINT ["/entrypoint.sh"]
CMD mutt-patched -F ~/.mutt/muttrc