title: Docker build failing (rpc error: code = 2 desc = "oci runtime error: exec format error")
body: <p>I have very little experience with docker, but I'm trying to create automated build for my library using gitlab-ci and a docker image.</p>
  
  <p>I want it to be build for raspberrypi so I found an docker image (<a href="https://hub.docker.com/r/resin/rpi-raspbian/" rel="nofollow">here</a>) and I have created a github repository with <code>Dockerfile</code>.</p>
  
  <p>In next step I have created an automated build in dockerhub, but build fails with following error:</p>
  
  <pre><code>Build failed: rpc error: code = 2 desc = "oci runtime error: exec format error"
  </code></pre>
  
  <p>I couldn't find any help in the documentation and also nothing on google so I'm asking:<br>
  Do you know what causes this error?</p>
  
  <p>My Dockerfile:</p>
  
  <pre><code>FROM resin/rpi-raspbian:wheezy-20160518
  MAINTAINER lewicki.pk@gmail.com
  
  RUN apt-get update &amp;&amp; apt-get install -y \
          automake \
          cmake \
          g++ \
          git \
          libboost-all-dev \
          libi2c-dev \
          libjsoncpp-dev \
          libpcre3-dev \
          libssl-dev \
          libtool \
          make \
          openssl \
          pkg-config \
          wget \
          &amp;&amp; apt-get clean
  </code></pre>
  
  <p>And the log from docker:</p>
  
  <pre><code>Starting build of index.docker.io/piotrlewicki/gitlab-ci_rpi-image:latest...
  Step 1 : FROM resin/rpi-raspbian:wheezy-20160518 ---&gt; aefd4527968f
  Step 2 : MAINTAINER lewicki.pk@gmail.com
  ---&gt; Running in a463aace5c5a
  ---&gt; c5eedf34e43c Removing intermediate container a463aace5c5a
  Step 3 : RUN apt-get update &amp;&amp; apt-get install -y automake cmake g++ git libboost-all-dev libi2c-dev libjsoncpp-dev libpcre3-dev libssl-dev libtool make openssl pkg-config wget &amp;&amp; apt-get clean
  ---&gt; Running in 318905fb5329 Removing intermediate container 318905fb5329
  rpc error: code = 2 desc = "oci runtime error: exec format error"
  </code></pre>