aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Dave Hello <[email protected]>2020-12-17 00:57:22 +0800
committerPeter Dave Hello <[email protected]>2020-12-17 00:59:59 +0800
commit70573dea14aff24047180425f6d2a7c397103ec5 (patch)
treeaed9b5cb9089c903833e93aa9452c609842470db
parentRemove unnecessary `WORKDIR` instruction in Dockerfile (diff)
downloaddocker-osx-70573dea14aff24047180425f6d2a7c397103ec5.tar.xz
docker-osx-70573dea14aff24047180425f6d2a7c397103ec5.zip
Merge a few `WORKDIR` & `RUN git clone` in Dockerfile
This will reduce the instructions and Docker image layers.
-rw-r--r--Dockerfile7
1 files changed, 2 insertions, 5 deletions
diff --git a/Dockerfile b/Dockerfile
index b7bc6d0..bac4081 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -95,8 +95,7 @@ RUN tee -a sshd_config <<< 'AllowTcpForwarding yes' \
USER arch
# download OSX-KVM
-WORKDIR /home/arch
-RUN git clone --depth 1 https://github.com/kholia/OSX-KVM.git
+RUN git clone --depth 1 https://github.com/kholia/OSX-KVM.git /home/arch/OSX-KVM
# enable ssh
# docker exec .... ./enable-ssh.sh
@@ -123,9 +122,7 @@ RUN sudo pacman -Syu qemu libvirt dnsmasq virt-manager bridge-utils flex bison e
# RUN sudo systemctl enable libvirtd.service
# RUN sudo systemctl enable virtlogd.service
-WORKDIR /home/arch/OSX-KVM
-
-RUN git clone --depth 1 https://github.com/corpnewt/gibMacOS.git
+RUN git clone --depth 1 https://github.com/corpnewt/gibMacOS.git /home/arch/OSX-KVM/gibMacOS
WORKDIR /home/arch/OSX-KVM/gibMacOS