Question

Installing libvips on App Platform

I am trying to install libvips to analyse the uploads in a rails application. At first I tried adding a build command, but after following up the community discussions I created a docker file named “Dockerfile” in the root of the project with following content

RUN apt-get update && apt-get install libvips-dev && apt-get clean

However it is still not getting installed. Kindly guide me how to proceed ahead and install libvips package.


Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

those RUN commands should be done using non-interactive mode by adding -y:

RUN apt-get update && apt-get install -y libvips-dev && apt-get clean

Hello! I believe the issue you’re running into is the yes/no prompt from apt-get.

To solve this, you need to add the -y (or --assume-yes) flag to apt-get install.

Here is the line above that installed libvips-dev when I tested it locally:

RUN apt-get update && apt-get install -y libvips-dev && apt-get clean

You might also run into a timezone prompt from debian. If this happens use the following:

ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install --no-install-recommends -y libvips-dev && apt-get clean

Also be sure to add dockerfile_path: Dockerfile to your app spec to ensure that the dockerfile you provided will be used.

Best,

Greg