Travis CI - full automation
This commit is contained in:
parent
fa9544bf24
commit
da06f9d73f
@ -16,8 +16,5 @@ services:
|
||||
- docker
|
||||
|
||||
script:
|
||||
#- sudo apt-get update
|
||||
- docker run --privileged -v $PWD:/minimal -it ubuntu:18.04 /bin/bash -c 'cd /minimal/travis && ./travis-ci.sh'
|
||||
#- sudo chown -R $USER:$USER *
|
||||
#- cd travis && ./test_qemu.sh
|
||||
|
||||
- sudo apt-get -qq -y update
|
||||
- cd travis && ./travis-ci.sh
|
||||
|
@ -1,8 +1,8 @@
|
||||
#!/bin sh
|
||||
#!/bin/sh
|
||||
|
||||
# This script shuts down the OS after one minute.
|
||||
sleep 60 && poweroff &
|
||||
sleep 30 && poweroff &
|
||||
|
||||
cat << CEOF
|
||||
[1m Minimal Linux Live will shut down in 60 seconds.[0m
|
||||
[1m Minimal Linux Live will shut down in 30 seconds.[0m
|
||||
CEOF
|
||||
|
@ -6,7 +6,7 @@ set -e
|
||||
|
||||
cd ../src
|
||||
|
||||
apt-get -qq -y install wget make gawk gcc bc xz-utils bison flex xorriso libelf-dev libssl-dev
|
||||
sudo apt-get -qq -y install wget make gawk gcc bc xz-utils bison flex xorriso libelf-dev libssl-dev
|
||||
|
||||
PREFIXES="00 01 02 03 04 05 06 07 08 09 10 11 12 13 14 15 16"
|
||||
|
||||
|
@ -6,14 +6,6 @@ set -e
|
||||
|
||||
cd ../src
|
||||
|
||||
apt-get -qq -y install docker.io
|
||||
#service docker start
|
||||
dockerd &
|
||||
|
||||
sleep 30
|
||||
|
||||
docker run hello-world
|
||||
|
||||
echo "`date` | *** MLL Docker test - BEGIN ***"
|
||||
|
||||
docker import mll_image.tgz minimal-linux-live:latest
|
||||
|
@ -6,17 +6,16 @@ set -e
|
||||
|
||||
cd ../src
|
||||
|
||||
apt-get -qq -y install qemu
|
||||
sudo apt-get -qq -y install qemu
|
||||
|
||||
echo "`date` | *** MLL QEMU test - BEGIN ***"
|
||||
|
||||
#qemu-system-x86_64 -m 256M -cdrom minimal_linux_live.iso -boot d -localtime -nographic &
|
||||
qemu-system-x86_64 -m 256M -kernel work/kernel/kernel_installed/kernel -initrd work/rootfs.cpio.xz -append "console=ttyS0 console=tty0" -localtime -console
|
||||
qemu-system-x86_64 -m 256M -cdrom minimal_linux_live.iso -boot d -localtime -nographic &
|
||||
#qemu-system-x86_64 -m 256M -kernel work/kernel/kernel_installed/kernel -initrd work/rootfs.cpio.xz -append "console=ttyS0 console=tty0" -localtime -nographic &
|
||||
|
||||
sleep 5
|
||||
|
||||
MLL=`ps -ef | grep -i [q]emu`
|
||||
if [ "$MLL" = "" ] ; then
|
||||
if [ "`ps -ef | grep -i [q]emu-system-x86_64`" = "" ] ; then
|
||||
echo "`date` | !!! FAILURE !!! Minimal Linux Live is not running in QEMU."
|
||||
exit 1
|
||||
else
|
||||
@ -25,11 +24,11 @@ fi
|
||||
|
||||
sleep 120
|
||||
|
||||
MLL=`ps -ef | grep -i [q]emu`
|
||||
if [ "$MLL" = "" ] ; then
|
||||
if [ "`ps -ef | grep -i [q]emu-system-x86_64`" = "" ] ; then
|
||||
echo "`date` | Minimal Linux Live is not running in QEMU."
|
||||
else
|
||||
echo "`date` | !!! FAILURE !!! Minimal Linux Live is still running in QEMU."
|
||||
ps -ef | grep -i [q]emu-system-x86_64
|
||||
exit 1
|
||||
fi
|
||||
|
||||
|
@ -5,18 +5,17 @@
|
||||
set -e
|
||||
|
||||
# Apply Travis specific patches
|
||||
#mkdir -p ../src/minimal_overlay/rootfs/etc/autorun
|
||||
#cp 99_autoshutdown.sh ../src/minimal_overlay/rootfs/etc/autorun
|
||||
#cp -f syslinux.cfg ../src/minimal_boot/bios/boot/syslinux/syslinux.cfg
|
||||
#sed -i "s|OVERLAY_LOCATION.*|OVERLAY_LOCATION=rootfs|" ../src/.config
|
||||
mkdir -p ../src/minimal_overlay/rootfs/etc/autorun
|
||||
cp 99_autoshutdown.sh ../src/minimal_overlay/rootfs/etc/autorun
|
||||
cp -f syslinux.cfg ../src/minimal_boot/bios/boot/syslinux/syslinux.cfg
|
||||
sed -i "s|OVERLAY_LOCATION.*|OVERLAY_LOCATION=rootfs|" ../src/.config
|
||||
|
||||
while true; do sleep 300; echo "`date` | >>> Heartbeat <<<"; done &
|
||||
|
||||
apt-get -qq update
|
||||
sudo apt-get -qq update
|
||||
|
||||
./build_mll.sh
|
||||
#./test_qemu.sh
|
||||
#./test_docker.sh
|
||||
./test_docker.sh
|
||||
./test_qemu.sh
|
||||
|
||||
set +e
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user