mirror of
https://github.com/vimagick/dockerfiles.git
synced 2025-12-21 21:33:02 +01:00
add rehook
This commit is contained in:
@@ -129,6 +129,7 @@ A collection of delicious docker recipes.
|
|||||||
- [x] portia
|
- [x] portia
|
||||||
- [x] pure-ftpd
|
- [x] pure-ftpd
|
||||||
- [x] redis-arm
|
- [x] redis-arm
|
||||||
|
- [x] rehook
|
||||||
- [x] rinetd
|
- [x] rinetd
|
||||||
- [x] rslsync
|
- [x] rslsync
|
||||||
- [x] rsyncd
|
- [x] rsyncd
|
||||||
|
|||||||
24
rehook/Dockerfile
Normal file
24
rehook/Dockerfile
Normal file
@@ -0,0 +1,24 @@
|
|||||||
|
#
|
||||||
|
# Dockerfile for rehook
|
||||||
|
#
|
||||||
|
|
||||||
|
FROM golang:alpine AS build
|
||||||
|
ENV CGO_ENABLED=0
|
||||||
|
ENV GOOS=linux
|
||||||
|
ENV GOARCH=amd64
|
||||||
|
WORKDIR /go/bin
|
||||||
|
RUN apk add --no-cache git
|
||||||
|
RUN go get -d -v github.com/jstemmer/rehook
|
||||||
|
RUN go build --ldflags '-s -extldflags "-static"' -i -o rehook github.com/jstemmer/rehook
|
||||||
|
|
||||||
|
FROM alpine:3
|
||||||
|
MAINTAINER EasyPi Software Foundation
|
||||||
|
WORKDIR /opt/rehook
|
||||||
|
RUN mkdir -p bin etc log
|
||||||
|
RUN apk add --no-cache bash coreutils curl jq
|
||||||
|
COPY --from=build /go/src/github.com/jstemmer/rehook/public public
|
||||||
|
COPY --from=build /go/src/github.com/jstemmer/rehook/views views
|
||||||
|
COPY --from=build /go/bin/rehook bin
|
||||||
|
EXPOSE 9000 9001
|
||||||
|
ENTRYPOINT ["bin/rehook"]
|
||||||
|
CMD ["-db", "etc/rehook.db", "-http", ":9000", "-admin", ":9001"]
|
||||||
10
rehook/README.md
Normal file
10
rehook/README.md
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
rehook
|
||||||
|
======
|
||||||
|
|
||||||
|
[Rehook][1] - a webhook dispatcher, filtering incoming requests from external
|
||||||
|
services and acting on them.
|
||||||
|
|
||||||
|
To view `etc/rehook.db`, please install [boltbrowser][2]
|
||||||
|
|
||||||
|
[1]: https://github.com/jstemmer/rehook
|
||||||
|
[2]: https://github.com/br0xen/boltbrowser
|
||||||
9
rehook/docker-compose.yml
Normal file
9
rehook/docker-compose.yml
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
rehook:
|
||||||
|
image: vimagick/rehook
|
||||||
|
ports:
|
||||||
|
- "9000:9000"
|
||||||
|
- "9001:9001"
|
||||||
|
volumes:
|
||||||
|
- "./data/etc:/opt/rehook/etc"
|
||||||
|
- "./data/log:/opt/rehook/log"
|
||||||
|
restart: unless-stopped
|
||||||
23
rehook/nginx.conf
Normal file
23
rehook/nginx.conf
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
server {
|
||||||
|
listen 80;
|
||||||
|
server_name rehook.example.com;
|
||||||
|
return 301 https://$host$request_uri;
|
||||||
|
}
|
||||||
|
|
||||||
|
server {
|
||||||
|
listen 443 ssl;
|
||||||
|
server_name rehook.example.com;
|
||||||
|
ssl_certificate ssl/example.com.crt;
|
||||||
|
ssl_certificate_key ssl/example.com.key;
|
||||||
|
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
|
||||||
|
ssl_ciphers HIGH:!aNULL:!MD5;
|
||||||
|
auth_basic "Restricted";
|
||||||
|
auth_basic_user_file /etc/nginx/htpasswd;
|
||||||
|
location / {
|
||||||
|
proxy_pass http://127.0.0.1:9001;
|
||||||
|
}
|
||||||
|
location /h/ {
|
||||||
|
auth_basic "off";
|
||||||
|
proxy_pass http://127.0.0.1:9000;
|
||||||
|
}
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user