RethinkDB For Apple Silicon and ARM Processors via Docker

R

One of the projects I work on is ProboCI. This continuous collaboration and testing tool is built with several dependencies – one of them being RethinkDB. Because I have been working on a Docker installation for the open source and proprietary versions of Probo, I have been using a full Docker container suite for development with an eye toward production.

Enter in Apple Silicon.

During this process, I purchased an upgraded Apple laptop with an M1 processor. Unfortunately the RethinkDB container does not contain an ARM64 compatibile build. As such I had to build my own. Using the instrucrtions here, as a baseline, I was able to come up with a mechanism by which I could build RethinkDB in an ARM container. Because Docker also runs on RaspberryPi (which is ARM based), this container should work. The only drawback right now is it is a very large container. Over 700mb compressed.

The project can be viewed on DockerHub. The URL is:

https://hub.docker.com/r/mbagnall/rethinkdb

I started from an Ubuntu 20.04 base image. I might be able to lighten the weight of this moving forward, but right now I needed to get it working quickly.

In addition to the dependencies listed in the article on RethinkDB, I also used the following packages installed via apt-install

  1. clang
  2. python
  3. make
  4. patch

So my base dependency install looked like:

One of the projects I work on is ProboCI. This continuous collaboration and testing tool is built with several dependencies – one of them being RethinkDB. Because I have been working on a Docker installation for the open source and proprietary versions of Probo, I have been using a full Docker container suite for development with an eye toward production.

Enter in Apple Silicone.

During this process, I purchased an upgraded Apple laptop with an M1 processor. Unfortunately the RethinkDB container does not contain an ARM64 compatibile build. As such I had to build my own. Using the instrucrtions here, as a baseline, I was able to come up with a mechanism by which I could build RethinkDB in an ARM container. Because Docker also runs on RaspberryPi (which is ARM based), this container should work. The only drawback right now is it is a very large container. Over 700mb compressed.

The project can be viewed on DockerHub. The URL is:

https://hub.docker.com/r/mbagnall/rethinkdb

I started from an Ubuntu 20.04 base image. I might be able to lighten the weight of this moving forward, but right now I needed to get it working quickly.

In addition to the dependencies listed in the article on RethinkDB, I also used the following packages installed via apt-install

  1. clang
  2. python
  3. make
  4. patch

So my base dependency install looked like:

apt-get -y install g++ protobuf-compiler libprotobuf-dev libboost-dev
apt-get -y install curl m4 wget libssl-dev clang python make patch

I also have to include the RethinkDB source code inside my repository as attempting to wget this from the source produced segmentation faults which I still do not completely understand other than it may still be a bug being ironed out in Docker for Apple Silicone.

https://www.github.com/ElusiveMind/rethinkdb

This image is highly experimental and I am only using it for development. YMMV.

About the author

Michael Bagnall

I am a web solutions architect working to develop PHP, JavaScript and Docker-based solutions in the public and private sector. Currently working out of the Middle Tennessee area, I am also an avid Ice Hockey fan and also play in an adult league. In addition to CodeRefactored.com, I also blog on hockey related items at BagOfPucks.com.

By Michael Bagnall

Recent Posts

PROJECTS

Tag Cloud