Skip to content

Commit

Permalink
Restructured project down to a single artifact. Fixed init.d script.
Browse files Browse the repository at this point in the history
  • Loading branch information
tomakehurst committed Mar 2, 2014
1 parent 0b4dafb commit 4141fb8
Show file tree
Hide file tree
Showing 12 changed files with 20 additions and 31 deletions.
19 changes: 19 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
BUILDDIR = build
VERSION = 0.5

.PHONY: clean rpm deb test

clean:
-rm -rf $(BUILDDIR)

rpm:
-mkdir -p build
fpm -s dir -t rpm -d "python >= 2.6" -p build -n saboteur --license "Apache 2.0" --vendor "Tom Akehurst" -m "Tom Akehurst" --url "https://github.com/tomakehurst/saboteur" --description "A fault injection tool for resilience testing" -a noarch -v $(VERSION) --before-install before-install.sh --after-remove after-remove.sh saboteur.py=/usr/bin/saboteur-agent saboteur.sudo=/etc/sudoers.d/saboteur saboteur.init=/etc/init.d/saboteur-agent sab=/usr/bin/sab

deb:
-mkdir -p build
fpm -s dir -t deb -d "python >= 2.6" -n saboteur --license "Apache 2.0" --vendor "Tom Akehurst" -m "Tom Akehurst" --url "https://github.com/tomakehurst/saboteur" --description "A fault injection tool for resilience testing" -a all -v $(VERSION) --before-install before-install.sh --after-remove after-remove.sh saboteur.py=/usr/bin/saboteur-agent saboteur.sudo=/etc/sudoers.d/saboteur saboteur.init=/etc/init.d/saboteur-agent sab=/usr/bin/sab
mv saboteur*.deb build

test:
python saboteur-tests.py
File renamed without changes.
19 changes: 0 additions & 19 deletions agent/Makefile

This file was deleted.

File renamed without changes.
Binary file added build/saboteur-0.5-1.noarch.rpm
Binary file not shown.
Binary file added build/saboteur_0.5_all.deb
Binary file not shown.
11 changes: 0 additions & 11 deletions cli/Makefile

This file was deleted.

File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion agent/saboteur.init → saboteur.init
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ PIDFILE=/var/run/saboteur/agent.pid
LOG=/var/log/saboteur/agent-error.log

start_saboteur() {
nohup runuser - saboteur -s '/bin/sh' -c $DAEMON < /dev/null >> $LOG 2>&1 &
nohup su - saboteur -s '/bin/sh' -c $DAEMON < /dev/null >> $LOG 2>&1 &
sleep 1
PID=`ps -u saboteur | grep "python" | head -1 | awk '{print $1}'`
if [ -z $PID ]; then
Expand Down
File renamed without changes.
File renamed without changes.

0 comments on commit 4141fb8

Please sign in to comment.