Skip to content

Commit

Permalink
Merge pull request #44 from xsnippet/docker-tox-env
Browse files Browse the repository at this point in the history
Add a tox env for building a Docker image
  • Loading branch information
ikalnytskyi committed Oct 23, 2017
2 parents 35d574a + f1072ad commit 6b6f1ab
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -52,3 +52,6 @@ docs/_build/

# Various shit from the OS itself
.DS_Store

# building of Docker images
.docker
10 changes: 10 additions & 0 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -27,3 +27,13 @@ deps =
-rdocs/requirements.txt
commands =
sphinx-build -W -b html -d {envtmpdir}/doctrees docs docs/_build/

[testenv:docker-build]
usedevelop = false
basepython = python3
deps =
whitelist_externals = bash
commands =
bash -c "docker build \
-t xsnippet/xsnippet-api:{posargs:$(git status | grep 'working tree clean' >/dev/null && git rev-parse --short HEAD || echo -n wip)} \
-f contrib/docker/Dockerfile ."

0 comments on commit 6b6f1ab

Please sign in to comment.