Skip to content
Merged
10 changes: 9 additions & 1 deletion Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,20 @@ pipeline {
dockerfile {
filename 'Dockerfile'
dir 'tests/smoke'
args '-v /dev/vboxdrv:/dev/vboxdrv --privileged'
args '-v /dev/vboxdrv:/dev/vboxdrv -v /tmp:/tmp --network host --privileged'
}
}
steps {
sh 'tests/smoke/build-all-templates.sh'
}
}
stage('Clean') {
agent any
steps {
dir('/var/jenkins_home/.cache/malboxes/') {
deleteDir()
}
}
}
}
}
13 changes: 12 additions & 1 deletion tests/smoke/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,9 +1,20 @@
FROM ubuntu:16.04

RUN apt-get update && apt-get install -y --no-install-recommends virtualbox python3 python3-pip python3-setuptools wget unzip bash git && \
RUN apt-get update && apt-get install -y --no-install-recommends curl ca-certificates gnupg && \
curl -sSL https://www.virtualbox.org/download/oracle_vbox_2016.asc | apt-key add - && \
echo "deb http://download.virtualbox.org/virtualbox/debian xenial contrib" >> /etc/apt/sources.list.d/virtualbox.list && \
apt-get update && apt-get install -y --no-install-recommends virtualbox-5.2 module-init-tools python3 python3-pip python3-setuptools wget unzip bash git && \
wget https://releases.hashicorp.com/packer/1.3.1/packer_1.3.1_linux_amd64.zip && unzip packer_1.3.1_linux_amd64.zip -d packer && \
mv packer/packer /usr/local/bin/ && chmod a+x /usr/local/bin/packer && rm packer_1.3.1_linux_amd64.zip && rmdir packer


# Enable this RUN statement when you need to connect to the VRDP server of the VM to troubleshoot issues
#RUN VBOXVER=$(wget -qO - https://download.virtualbox.org/virtualbox/LATEST.TXT) && \
# wget "https://download.virtualbox.org/virtualbox/${VBOXVER}/Oracle_VM_VirtualBox_Extension_Pack-${VBOXVER}.vbox-extpack" && \
# VBoxManage extpack install --accept-license=56be48f923303c8cababb0bb4c478284b688ed23f16d775d729b89a2e8e5f9eb Oracle_VM_VirtualBox_Extension_Pack-${VBOXVER}.vbox-extpack && \
# rm Oracle_VM_VirtualBox_Extension_Pack-${VBOXVER}.vbox-extpack


# Config between delimiters taken from https://github.com/jenkinsci/docker/blob/master/Dockerfile
# --
ARG user=jenkins
Expand Down
6 changes: 3 additions & 3 deletions tests/smoke/config.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"password": "malboxes",
"computername": "smoketest",
// disk size is in megabytes
"disk_size": "20480",
"disk_size": "40960",

// Windows Defender: true means enabled, false means disabled. Default is false.
//"windows_defender": "false",
Expand All @@ -41,8 +41,8 @@
//"hypervisor": "kvm",

// Chocolatey packages to install on the VM
// TODO re-add dependencywalker and regshot once upstream choco package provides a checksum
"choco_packages": "sysinternals windbg wireshark 7zip putty apm",
// FIXME made install go faster to prevent jenkins / packer bug when building Windows 7 machines (see #108)
//"choco_packages": "sysinternals windbg wireshark 7zip putty apm",

// Setting the IDA Path will copy the IDA remote debugging tools into the guest
//"ida_path": "/path/to/your/ida",
Expand Down