sui generis, linux, python, devops, robotics, polyamory, data custodian

Cross Platform ODROID ARM Docker quemu CI/CD Pipeline

2016-01-17 devops ubergarm

Want to develop, build, test, and deploy consistent code across multiple platforms and even architectures? Maybe work on your Raspberry Pi or ODROID code from your laptop, push a Docker image, then pull the exact same code onto your target hardware device? Maybe even automate all these steps using Continious Integration?! Yeah why not! :)


I first tried this on Circle CI but ran into some hiccups with with binfmt_misc not being quite full acessible on their build machines. While I like their user interface and ability to coordinate with others on github repos, binfmt_misc is a must have feature. When I asked about it, I received this curtious and efficient official response (Dec 2, 2015):

Hello, I dont think this is supported and it may not be for quite some time. Best, Lev

So I tried Travis CI and was pleasantly surprised to see everything worked straight away!

Travis CI

Setup your Travis CI account to point to your desired github repo. Place a .travis.yml in the top level directory of your repo, push, and watch the magic!

Here is a quick and dirty .travis.yml example from which you can setup your own requirements.

sudo: required
  - docker
# language: haskell
# setup build machine
  - travis_retry sudo apt-get update
  - travis_retry sudo apt-get install -y --no-install-recommends qemu-user-static binfmt-support
  - sudo update-binfmts --display qemu-arm
# build code
  - docker pull ubergarm/armhf-ubuntu:trusty
# test code
  - uname -a
  - docker run --rm -it ubergarm/armhf-ubuntu:trusty uname -a
# save/deploy build artifacts
  - /bin/true
#  - docker push ubergarm/rowboat1

# configure which branches are built
    - builds
#    - master




Continuous Integration comes to the embedded world!

comments powered by Disqus