forked from imarc/ops
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile.alpine
55 lines (42 loc) · 1.07 KB
/
Dockerfile.alpine
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
FROM alpine:3.9.3
MAINTAINER Imarc <info@imarc.com>
RUN apk add --update --no-cache \
bash \
curl \
composer \
docker \
git \
jq \
openssh \
openssl \
socat \
rsync \
nodejs \
nss \
nss-tools \
npm \
netcat-openbsd \
php7 \
py-pip \
socat \
unzip \
wget \
sudo \
apache2 \
&& rm -rf /var/cache/apk/*
RUN pip install yq
# install docker-compose
RUN curl -L https://github.com/docker/compose/releases/download/1.24.0/docker-compose-`uname -s`-`uname -m` -o /usr/local/bin/docker-compose
RUN chmod +x /usr/local/bin/docker-compose
RUN mkdir /home/ops
RUN mkdir /home/ops/Sites
RUN addgroup -g 1000 ops && \
adduser -h /home/ops -D -u 1000 -G ops ops
COPY . /usr/local/var/ops
RUN echo '%ops ALL=(ALL) NOPASSWD: ALL' > /etc/sudoers.d/ops
WORKDIR /home/ops
RUN chown -R ops:ops /home/ops
RUN chown ops:ops /usr/lib/node_modules
RUN chown ops:ops /usr/bin
USER ops
RUN npm install -g /usr/local/var/ops