Add abuse scanner module
This commit is contained in:
parent
6e642a8c2b
commit
52e1ffbc0a
5
dc
5
dc
|
@ -13,6 +13,11 @@ for i in $(seq 1 ${#PORTAL_MODULES}); do
|
||||||
COMPOSE_FILES+=" -f docker-compose.mongodb.yml -f docker-compose.accounts.yml"
|
COMPOSE_FILES+=" -f docker-compose.mongodb.yml -f docker-compose.accounts.yml"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# abuse module - alias "c"
|
||||||
|
if [[ ${PORTAL_MODULES:i-1:1} == "c" ]]; then
|
||||||
|
COMPOSE_FILES+=" -f docker-compose.abuse.yml"
|
||||||
|
fi
|
||||||
|
|
||||||
# blocker module - alias "b"
|
# blocker module - alias "b"
|
||||||
if [[ ${PORTAL_MODULES:i-1:1} == "b" ]]; then
|
if [[ ${PORTAL_MODULES:i-1:1} == "b" ]]; then
|
||||||
COMPOSE_FILES+=" -f docker-compose.blocker.yml"
|
COMPOSE_FILES+=" -f docker-compose.blocker.yml"
|
||||||
|
|
|
@ -0,0 +1,26 @@
|
||||||
|
version: "3.7"
|
||||||
|
|
||||||
|
x-logging: &default-logging
|
||||||
|
driver: json-file
|
||||||
|
options:
|
||||||
|
max-size: "10m"
|
||||||
|
max-file: "3"
|
||||||
|
|
||||||
|
services:
|
||||||
|
blocker:
|
||||||
|
build:
|
||||||
|
context: ./docker/abuse
|
||||||
|
dockerfile: Dockerfile
|
||||||
|
container_name: abuse
|
||||||
|
restart: unless-stopped
|
||||||
|
logging: *default-logging
|
||||||
|
env_file:
|
||||||
|
- .env
|
||||||
|
environment:
|
||||||
|
- BLOCKER_API_URL=http://blocker
|
||||||
|
networks:
|
||||||
|
shared:
|
||||||
|
ipv4_address: 10.10.10.110
|
||||||
|
depends_on:
|
||||||
|
- mongo
|
||||||
|
- blocker
|
|
@ -0,0 +1,16 @@
|
||||||
|
FROM golang:1.16.7
|
||||||
|
LABEL maintainer="NebulousLabs <devs@nebulous.tech>"
|
||||||
|
|
||||||
|
ENV GOOS linux
|
||||||
|
ENV GOARCH amd64
|
||||||
|
|
||||||
|
ARG branch=main
|
||||||
|
|
||||||
|
WORKDIR /root
|
||||||
|
|
||||||
|
RUN git clone --single-branch --branch ${branch} https://github.com/SkynetLabs/abuse-scanner.git && \
|
||||||
|
cd abuse-scanner && \
|
||||||
|
go mod download && \
|
||||||
|
make release
|
||||||
|
|
||||||
|
ENTRYPOINT ["abuse-scanner"]
|
Reference in New Issue