Skip to content

Commit

Permalink
update gitignore trap docker kill
Browse files Browse the repository at this point in the history
  • Loading branch information
ezra-varady committed Oct 22, 2023
1 parent 0d1abf5 commit 6a4e357
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ test/tmp_output/
.DS_Store
build
data
sanitizer
.vscode/
.devcontainer/
.cache
9 changes: 7 additions & 2 deletions scripts/sanitizers/run_sanitizers.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,12 @@ mkdir -p sanitizer

docker build -t lantern-san -f scripts/sanitizers/Dockerfile .

function kill-docker {
docker kill lantern-sanitizers
}

trap kill-docker EXIT

docker run --rm -d -v $(pwd)/sanitizer:/lantern/sanitizer --name lantern-sanitizers lantern-san

docker exec -i -u root lantern-sanitizers /bin/bash <<EOF
Expand All @@ -16,6 +22,5 @@ EOF

docker exec -i -u postgres -w /lantern/build lantern-sanitizers /bin/bash <<EOF
make test
cp /tmp/lantern/tmp_output/results/*.out /lantern/sanitizer
EOF

docker kill lantern-sanitizers

0 comments on commit 6a4e357

Please sign in to comment.