Sign inSign up

daverona/openbabel

By daverona

Updated over 6 years ago

Image
0

585

daverona/openbabel repository overview

daverona/openbabel

ubuntu pipeline status

alpine pipeline status

This is a repository for Docker images of Open Babel library.

Available versions are:

Installation

Pull the image from Docker Hub repository:

docker image pull daverona/openbabel

Quick Start

Run the container:

docker container run --rm \
  daverona/openbabel \
  python3 -c "import openbabel;print(openbabel.__version__)"

It will show the version of openbabel built in the container.

If you want a Python 3 shell with openbabel available, run the container:

docker container run --rm \
  --interactive --tty \
  daverona/openbabel

Advanced Usages

Copy to Another Docker Image

To copy Open Babel from this image to yours not as base image, add the following:

# Replace 3.1.1 with the version you want on the next two lines
ARG OPENBABEL_HOME=/usr/local/openbabel/3.1.1
COPY --from=daverona/openbabel:3.1.1 $OPENBABEL_HOME $OPENBABEL_HOME
RUN apt-get update \
  && apt-get install --yes --quiet --no-install-recommends \
    libboost-filesystem1.65.1 \
    libboost-iostreams1.65.1 \
    libboost-program-options1.65.1 \
    libboost-regex1.65.1 \
    libboost-system1.65.1 \
    libboost-test1.65.1 \
    libpython3.6 \
    libxml2 \
    python3 \
    python3-cairo \
    swig \
  && apt-get clean && rm -rf /var/lib/apt/lists/* \
  && ln -s $OPENBABEL_HOME/lib/python3.6/site-packages/openbabel /usr/local/lib/python3.6/dist-packages/openbabel
ENV LD_LIBRARY_PATH=$OPENBABEL_HOME/lib:$LD_LIBRARY_PATH
ENV PATH=$OPENBABEL_HOME/bin:$PATH

References

Tag summary

Content type

Image

Digest

Size

66.2 MB

Last updated

over 6 years ago

docker pull daverona/openbabel