summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorFrancesco Borzì <borzifrancesco@gmail.com>2019-02-23 17:34:56 +0100
committerGitHub <noreply@github.com>2019-02-23 17:34:56 +0100
commite659ca5fe944d43e8382afe0fa59425b0361b65a (patch)
tree144f6698fda521395b49fecb7b15d817497a724c /bin
parent53098cd1e0dbb033d414d6ddddbc549ba4f78381 (diff)
feat(docker): add cache for faster rebuild (#1507)
- Closes #1502
Diffstat (limited to 'bin')
-rwxr-xr-xbin/acore-docker-build8
-rw-r--r--bin/acore-docker-remove-build-cache10
2 files changed, 17 insertions, 1 deletions
diff --git a/bin/acore-docker-build b/bin/acore-docker-build
index a13c92ebfc..6a32b02839 100755
--- a/bin/acore-docker-build
+++ b/bin/acore-docker-build
@@ -1,3 +1,9 @@
#!/usr/bin/env bash
-docker build -t azerothcore/build -f docker/build/Dockerfile .
+docker build -t acbuild -f docker/build/Dockerfile .
+
+docker run \
+ -v /$(pwd)/docker/build/cache:/azerothcore/build \
+ -v /$(pwd)/docker/worldserver/bin:/binworldserver \
+ -v /$(pwd)/docker/authserver/bin:/binauthserver \
+ acbuild
diff --git a/bin/acore-docker-remove-build-cache b/bin/acore-docker-remove-build-cache
new file mode 100644
index 0000000000..817a18da39
--- /dev/null
+++ b/bin/acore-docker-remove-build-cache
@@ -0,0 +1,10 @@
+#!/usr/bin/env bash
+
+sudo rm -rf ./docker/build/cache/CMakeFiles
+sudo rm -rf ./docker/build/cache/deps
+sudo rm -rf ./docker/build/cache/src
+sudo rm ./docker/build/cache/*.cmake
+sudo rm ./docker/build/cache/*.txt
+sudo rm ./docker/build/cache/*.h
+sudo rm ./docker/build/cache/*.cpp
+sudo rm ./docker/build/cache/Makefile