Skip to content

Commit 20d92de

Browse files
committed
Adds VM building.
1 parent f64d004 commit 20d92de

File tree

2 files changed

+28
-6
lines changed

2 files changed

+28
-6
lines changed

.travis.yml

Lines changed: 27 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ before_install:
2828

2929
install:
3030
- yes | gcloud compute instances delete travis-instance --zone us-central1-b || true
31-
- gcloud compute instances create travis-instance --zone us-central1-b --image ubuntu-14-04 --machine-type n1-highcpu-32 --boot-disk-size 64 --scopes compute-rw
31+
- gcloud compute instances create travis-instance --zone us-central1-b --image ubuntu-14-04 --machine-type n1-highcpu-32 --boot-disk-size 200 --scopes compute-rw
3232
- |
3333
while [ 1 ]; do
3434
gcloud compute ssh travis-instance --zone us-central1-b --command 'exit 0' -- -o ConnectTimeout=10 > /dev/null 2>&1 && break
@@ -39,6 +39,7 @@ install:
3939
script:
4040
- |
4141
rsync -avz -e "$(gcloud compute ssh --zone us-central1-b travis-instance --dry-run | sed s/'[^ ]*$'//)" . "$(gcloud compute ssh --zone us-central1-b travis-instance --dry-run | awk 'END {print $NF}'):~/openwrt-tessel"
42+
- gcloud compute ssh travis-instance --zone us-central1-b --command "echo 'export AWS_ACCESS_KEY_ID=$AWS_ACCESS_KEY_ID' >> ~/.bashrc; echo 'export AWS_SECRET_ACCESS_KEY=$AWS_SECRET_ACCESS_KEY' >> ~/.bashrc; "
4243
- |
4344
gcloud compute ssh travis-instance --zone us-central1-b --command '
4445
set -e
@@ -52,12 +53,32 @@ script:
5253
sudo apt-get install -y software-properties-common
5354
sudo apt-add-repository -y ppa:terry.guo/gcc-arm-embedded
5455
sudo apt-get update -qq
55-
sudo apt-get install -y build-essential git-core g++ subversion libncurses-dev libssl-dev unzip gettext gcc-arm-none-eabi
56-
cp -rf ~/openwrt-tessel /tmp/ramdisk/openwrt-tessel
57-
cd /tmp/ramdisk/openwrt-tessel
56+
sudo apt-get install -y build-essential python-pip git-core g++ subversion libncurses-dev libssl-dev unzip gettext gcc-arm-none-eabi
57+
58+
mkdir ~/upload
59+
cd ~/openwrt-tessel
5860
git submodule update --init --recursive
61+
62+
cp -rf ~/openwrt-tessel /tmp/ramdisk/v2
63+
pushd /tmp/ramdisk/v2
5964
make -j64 || make -j64 || make -j64 || make -j64 || make -j64 V=s
65+
cp /tmp/ramdisk/v2/openwrt/bin/ramips/*sysupgrade.bin ~/upload
66+
tar -czf ~/upload/toolchain-mipsel.tar.gz -C /tmp/ramdisk/v2/openwrt/staging_dir $(find /tmp/ramdisk/v2/openwrt/staging_dir -iname '*-mipsel_*' -exec basename {} \;)
67+
popd
68+
69+
rm -rf /tmp/ramdisk/v2
70+
71+
cp -rf ~/openwrt-tessel /tmp/ramdisk/vm
72+
pushd /tmp/ramdisk/vm
73+
make -j64 TARGET=vm || make -j64 TARGET=vm || make -j64 TARGET=vm || make -j64 TARGET=vm || make -j64 TARGET=vm V=s
74+
cp /tmp/ramdisk/vm/openwrt/bin/x86/*.vdi ~/upload
75+
tar -czf ~/upload/toolchain-x86.tar.gz -C /tmp/ramdisk/vm/openwrt/staging_dir $(find /tmp/ramdisk/vm/openwrt/staging_dir -iname '*-i386_*' -exec basename {} \;)
76+
popd
77+
78+
source ~/.bashrc
79+
sudo -H python -m pip install awscli
80+
aws s3 sync ~/upload/. s3://tessel-builds/firmware/
6081
'
6182
62-
#after_script:
63-
#- yes | gcloud compute instances delete travis-instance --zone us-central1-b || true
83+
after_script:
84+
- yes | gcloud compute instances delete travis-instance --zone us-central1-b || true

target/vm/config.mk

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,6 @@ CONFIG_TARGET_x86_generic=y
33
CONFIG_TARGET_x86_generic_Generic=y
44
CONFIG_TARGET_ROOTFS_EXT4FS=y
55
CONFIG_VDI_IMAGES=y
6+
CONFIG_TARGET_ROOTFS_PARTSIZE=96
67

78
PACKAGES += kmod-usb-ohci-pci

0 commit comments

Comments
 (0)