Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
83 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
FROM ubuntu:14.04 | ||
MAINTAINER james@gauntlt.org | ||
|
||
# Install Ruby | ||
RUN echo "deb http://ppa.launchpad.net/brightbox/ruby-ng/ubuntu trusty main" > /etc/apt/sources.list.d/ruby.list | ||
RUN apt-key adv --keyserver keyserver.ubuntu.com --recv-keys C3173AA6 | ||
RUN \ | ||
apt-get update && \ | ||
apt-get install -y build-essential \ | ||
ca-certificates \ | ||
curl \ | ||
wget \ | ||
zlib1g-dev \ | ||
libxml2-dev \ | ||
libxslt1-dev \ | ||
ruby2.0 \ | ||
ruby2.0-dev && \ | ||
rm -rf /var/lib/apt/lists/* | ||
|
||
# Install Gauntlt | ||
RUN gem install gauntlt --no-rdoc --no-ri | ||
|
||
# Install Attack tools | ||
RUN gem install arachni --no-rdoc --no-ri | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
all: help | ||
|
||
build: | ||
@./build-gauntlt.sh | ||
|
||
clean: | ||
@./docker-clean.sh | ||
|
||
help: | ||
@echo "the help menu" | ||
@echo "make clean" | ||
@echo "make build" | ||
@echo "make help" | ||
|
||
.PHONY: build clean |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
#!/bin/bash | ||
|
||
set -e | ||
|
||
function build() { | ||
local TARGET=$1 | ||
if [ ! -d $TARGET ]; then | ||
echo "** ERROR: $TARGET isn't a valid directory" | ||
fi | ||
docker build -t $TARGET . | ||
} | ||
|
||
build "gauntlt" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
#!/usr/bin/env bash | ||
|
||
function docker-cleanup { | ||
EXITED=$(docker ps -aq -f status=exited) | ||
DANGLING=$(docker images -q -f "dangling=true") | ||
|
||
if [ "$1" == "--dry-run" ]; then | ||
echo "==> Would stop containers:" | ||
echo $EXITED | ||
echo "==> And images:" | ||
echo $DANGLING | ||
else | ||
if [ -n "$EXITED" ]; then | ||
echo "Removing these containers:" | ||
docker rm $EXITED | ||
else | ||
echo "No containers to remove." | ||
fi | ||
if [ -n "$DANGLING" ]; then | ||
echo "Removing these images:" | ||
docker rmi $DANGLING | ||
else | ||
echo "No images to remove." | ||
fi | ||
fi | ||
} | ||
|
||
# use --dry-run to see what would happen | ||
|
||
docker-cleanup |