Skip to content

Commit cee2348

Browse files
authored
Merge pull request #96 from Dryja/better-docker
Improved Dockerfile + added docker-compose
2 parents 84ee146 + 6a9acf4 commit cee2348

File tree

4 files changed

+18
-5
lines changed

4 files changed

+18
-5
lines changed

Diff for: README.md

+6
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,12 @@ Alternatively you can build a Docker image by changing to the docker directory a
4343
```
4444
docker build -t nosqlmap .
4545
```
46+
47+
or you can use Docker-compose to run Nosqlmap:
48+
```
49+
docker-compose build
50+
docker-compose run nosqlmap
51+
```
4652
## Usage Instructions
4753
Start with
4854
```

Diff for: docker/Dockerfile

+4-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
1-
FROM ubuntu:latest
1+
FROM python:2.7-alpine
22

3-
RUN apt-get update && apt-get install -y python python-pip git mongodb
3+
RUN echo 'http://dl-cdn.alpinelinux.org/alpine/v3.9/main' >> /etc/apk/repositories
4+
RUN echo 'http://dl-cdn.alpinelinux.org/alpine/v3.9/community' >> /etc/apk/repositories
5+
RUN apk update && apk add mongodb git
46

57
RUN git clone https://github.com/codingo/NoSQLMap.git /root/NoSqlMap
68

@@ -9,7 +11,6 @@ WORKDIR /root/NoSqlMap
911
RUN python setup.py install
1012

1113
COPY entrypoint.sh /tmp/entrypoint.sh
12-
1314
RUN chmod +x /tmp/entrypoint.sh
1415

1516
ENTRYPOINT ["/tmp/entrypoint.sh"]

Diff for: docker/docker-compose.yml

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
version: "3"
2+
services:
3+
nosqlmap:
4+
image: nosqlmap:latest
5+
build:
6+
context: .

Diff for: docker/entrypoint.sh

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
#!/bin/bash
2-
exec python nosqlmap.py
1+
#!/bin/ash
2+
python nosqlmap.py

0 commit comments

Comments
 (0)