-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile.dev
39 lines (29 loc) · 937 Bytes
/
Dockerfile.dev
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
FROM docker.io/alpine:3.4
MAINTAINER Paul Delafosse "[email protected]"
RUN apk add --no-cache \
openssh \
bash \
git \
curl
# Setup sshd
RUN ssh-keygen -A
RUN adduser -D -s /bin/bash git \
&& echo git:12345 | chpasswd \
&& mkdir /home/git/.ssh \
&& touch /home/git/.ssh/authorized_keys \
&& chown -R git:git /home/git/.ssh \
&& chmod 700 /home/git/.ssh \
&& chmod -R 600 /home/git/.ssh/*
COPY docker/sshd_config /etc/ssh/sshd_config
EXPOSE 22
EXPOSE 3000
# Prepare workdir
WORKDIR /home/git
RUN mkdir bin
COPY target/x86_64-unknown-linux-musl/release/gill-app ./bin/gill-app
COPY target/x86_64-unknown-linux-musl/release/gill-git-server ./bin/gill-git-server
COPY target/x86_64-unknown-linux-musl/release/post-receive /usr/share/git-core/templates/hooks/post-receive
COPY crates/gill-app/assets/ /opt/gill/assets
COPY docker/dev/home/* ./
RUN chown -R git:git ./
ENTRYPOINT ["./entrypoint.sh"]