forked from restyled-io/sdk
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
57 lines (52 loc) · 1.53 KB
/
Dockerfile
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
FROM fpco/stack-build-small:lts-16.12 AS builder
LABEL maintainer="Pat Brisbin <[email protected]>"
ENV DEBIAN_FRONTEND=noninteractive LANG=C.UTF-8 LC_ALL=C.UTF-8
RUN \
apt-get update && \
apt-get install -y --no-install-recommends \
ca-certificates \
curl \
gcc \
locales \
netbase && \
locale-gen en_US.UTF-8 && \
rm -rf /var/lib/apt/lists/*
RUN mkdir -p /src/bin
WORKDIR /src
COPY stack.yaml /src/stack.yaml
COPY promote/package.yaml /src/promote/package.yaml
COPY restylers/package.yaml /src/restylers/package.yaml
RUN stack install --dependencies-only --test --no-run-tests
COPY promote /src/promote/
COPY restylers /src/restylers/
RUN stack install --pedantic --test
RUN curl -sL https://get.docker.com/ | sh
FROM ubuntu:18.04
LABEL maintainer="Pat Brisbin <[email protected]>"
ENV DEBIAN_FRONTEND=noninteractive LANG=C.UTF-8 LC_ALL=C.UTF-8
RUN \
apt-get update && \
apt-get install -y --no-install-recommends \
awscli \
ca-certificates \
curl \
git \
gnupg \
jq \
locales \
netbase \
ruby-full && \
locale-gen en_US.UTF-8 && \
rm -rf /var/lib/apt/lists/*
RUN gem install jwt
COPY --from=builder /usr/bin/docker /bin/docker
COPY --from=builder /root/.local/bin/promote /bin/restyled-promote
COPY --from=builder /root/.local/bin/restylers /bin/restyled-restylers
COPY files/ /
ENV GIT_AUTHOR_NAME=Restyled.io
ENV GIT_COMMITTER_NAME=Restyled.io
RUN mkdir -p /code
WORKDIR /code
ENTRYPOINT ["restyled"]