move Dockerfile into the root, make it build git-http-server as well

---
type: change
message: move Dockerfile into the root, make it build git-http-server as well
change_hash: AMsTQSEBo/XDnbkuiSStDsWUdian3UXM5YXlMhvTlegk
credentials:
- type: pgp_signature
  pub_key_id: 95C46FA6A41148AC
  body: iQIzBAABAgAdFiEEJ6tQKp6olvZKJ0lwlcRvpqQRSKwFAl59b6MACgkQlcRvpqQRSKzD0g//Qja8EIF/cdOz5OrqdXOJeUqUm2QfZuUrDANZey3rTtpULAy3OTezrSTEK//bd+DLa+hf9r0hTocCzhTx5RO6wKYup0LMdiO6QGeXhdKzVjuN0FA7jQztjgZD5Y/P+PT9Ye8NiCPrQ8gdtG3BRB5RDgHILQNclvt5GyKMske4rYbi99DtnrSbbqP0n7dZLaurAkP7fQL2Q+8/o8Vt+uAl8s2whMJ1z7+Z8YqN+uUcHfuTxEcBkW97qjsjhpk9ZVSzpw6GXjuFy/n9uBk2mVyaoMcKtk03SCB7byCK7uM3mNMakr+m2W+RQMlzpUlYToFL9uWHoDouANK3kDLyM7WpEPIajU6Cuq5C97KsqQWNTrFypLlYx/IiUbKg0LJVyckw0jl98iY7jIDOKkQmNIYwaQ8IvXtJ459Jo0DSvmE8IEoCxskfvlh7YZU9keu1spW/k8M22RPvrrjU34IhIokkA1KbVBaNyMRoypjH0PptRleU4+Vmdf4MGg9heft2+JqYcs7pHVDYVSs1TFPRfmlhcf2CtixuWcqIpNiQEW/S1ZdcJ7Ifsv+6hNTYQqqNz6fS70cm58mA7lPZ+LFoNaaXcCYAHwq+y3RYXlm1I1fEDrv6RLuxNvOWAxGelCvDv5M5M3zdm5DHvrmPMk8fOfRKck7eWRMD6o/FV4f/K04R3TY=
  account: mediocregopher
main
mediocregopher 4 years ago
parent 2390197ae3
commit a3b98cc4ef
  1. 19
      Dockerfile
  2. 1
      cmd/http-server/.gitignore

@ -1,3 +1,11 @@
FROM golang:1.14
WORKDIR /go/src/dehub
COPY . .
RUN CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -o /usr/bin/dehub ./cmd/dehub
WORKDIR /go/src/dehub/cmd/git-http-server
RUN CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -o /usr/bin/git-http-server .
FROM debian:jessie
# Setup Container
@ -21,15 +29,18 @@ RUN sed -i 's/FCGI_USER="www-data"/FCGI_USER="git"/g' /etc/init.d/fcgiwrap && \
sed -i 's/FCGI_SOCKET_OWNER="www-data"/FCGI_SOCKET_OWNER="git"/g' /etc/init.d/fcgiwrap && \
sed -i 's/FCGI_SOCKET_GROUP="www-data"/FCGI_SOCKET_GROUP="git"/g' /etc/init.d/fcgiwrap
# Copy binaries
COPY --from=0 /usr/bin/dehub /usr/bin/dehub
COPY --from=0 /usr/bin/git-http-server /usr/bin/git-http-server
# Create config files for container startup and nginx
COPY nginx.conf /etc/nginx/nginx.conf
COPY cmd/http-server/nginx.conf /etc/nginx/nginx.conf
# Create pre-receive
COPY dehub /usr/bin/dehub
COPY "pre-receive" /pre-receive
COPY cmd/http-server/pre-receive /pre-receive
# Create start.sh
COPY start.sh /start.sh
COPY cmd/http-server/start.sh /start.sh
RUN chmod +x /start.sh
ENTRYPOINT ["/start.sh"]

@ -1 +0,0 @@
dehub
Loading…
Cancel
Save