- #Dockerfile alpine linux imagemagick rails install#
- #Dockerfile alpine linux imagemagick rails trial#
I tried to run the script again, but the binary was looking for the libraries in the wrong path.
#Dockerfile alpine linux imagemagick rails install#
ext/node/bin/node: _register_atfork: symbol not foundĪs an alternative to libc6-compat, I found the glibc package for Alpine on GitHub ( link to repository) and ran the following commands to retrieve and install the package: wget -q -O /etc/apk/keys/ Īpk add & rm
I ended up with this error message: Error relocating. The libc6-compat package contains that file and other compatibility libraries for glibc, so I added it and tried to install Node.js again. ext/node/bin/node and learned that the requested program interpreter is /lib64/ld-linux-x86-64.so.2. external/node/install-node.sh), but the installation failed again. I retrieved Node.js with the command (cd. I decided to build an image up to that point and run a container to interactively look for a solution from the shell. bin/npm -python="$PYTHON" install) couldn’t find the Node.js binary. installed only pandoc, so the command (cd. The first problem during the installation occurred because the command cmake -DCMAKE_INSTALL_PREFIX=/usr/local. bin/node /usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js -python="/usr/bin/python" rebuild) & \ bin/npm -python="/usr/bin/python" install) & \ R -e "install.packages(c('shiny'), repos='')" & \Ĭd shiny-server & mkdir tmp & cd tmp & \Ĭmake -DCMAKE_INSTALL_PREFIX=/usr/local. Apart from the installation of system dependencies and the shiny package, the installation instructions in the first version of the Dockerfile were pretty much an exact copy of the instructions provided by RStudio on GitHub: RUN echo '' > /etc/apk/repositories & \ I forked the Shiny Server git repository to make sure I have control over the changes made to it while working on this image. # Forgot to remove libc6-compat, no longer needed # TODO: Separate to build and persistent! Here is the final list of dependencies I included in the Dockerfile: FROM velaco/alpine-r:base-3.5.0-r1 The package wget retrieves Node.js and linux-headers are needed to compile it from source. The package asked for automake version 1.15 specifically, so I had to include the command echo '' > /etc/apk/repositories before adding the system requirements because that branch contains automake v1.15.1. In order to install the httpuv package, I had to install automake, autoconf, m4, and file as well. Based on my review of other Dockerfiles for Shiny, including the one maintained by Rocker, I also added curl-dev, libffi, psmisc, rrdtool, cairo-dev, libxt-dev, and libxml2-dev to the list of dependencies.Ī system-wide installation of the shiny package and its dependencies is also necessary, and the first problem I encountered was the installation of the httpuv package. The packages python2, gcc, g++, git, cmake, and R (base and devel) are the main system requirements for installing Shiny Server from source. I wasn’t sure which dependencies to put under BUILD and which to put under PERSISTENT, so I added them all to a single variable for now. I used Building Shiny Server from Source as a reference to determine which dependencies I’ll install and to write the first version of the installation and post-installation instructions. Shiny Server doesn’t have precompiled installers for Alpine Linux, so I had to build it from source. The latest image with Shiny Server is not available on Docker Hub because it exceeded the time limit for automated builds, so I’ll have to upload it manually. Notes: The Dockerfile I used is available in the velaco/alpine-r repository on GitHub.
#Dockerfile alpine linux imagemagick rails trial#
After two weeks of trial and error, I finally have a container that can start the server and run Shiny apps. The logical choice would have been to pass all tests with R’s base packages before proceeding, but I was a bit impatient and wanted to go through the process of building a Shiny Server as soon as possible. The next step was either to address the fatal errors I found while testing the installation of R or to proceed building an image with Shiny Server.
The images are hosted on Docker Hub, velaco/alpine-r repository. In the first article of this series, I built an Alpine-based Docker image with R base packages from Alpine’s native repositories, as well as one image with R compiled from source code.