mirror of
https://git.rwth-aachen.de/acs/public/villas/node/
synced 2025-03-09 00:00:00 +01:00
docker: add alpine image
This commit is contained in:
parent
92ee66d31c
commit
0ceddb755d
1 changed files with 123 additions and 0 deletions
123
packaging/docker/Dockerfile.dev-alpine
Normal file
123
packaging/docker/Dockerfile.dev-alpine
Normal file
|
@ -0,0 +1,123 @@
|
|||
# Dockerfile for VILLASnode development.
|
||||
#
|
||||
# This Dockerfile builds an image which contains all library dependencies
|
||||
# and tools to build VILLASnode.
|
||||
# However, VILLASnode itself it not part of the image.
|
||||
#
|
||||
# This image can be used for developing VILLASnode
|
||||
# by running:
|
||||
# make docker-dev
|
||||
#
|
||||
# @author Steffen Vogel <stvogel@eonerc.rwth-aachen.de>
|
||||
# @copyright 2014-2020, Institute for Automation of Complex Power Systems, EONERC
|
||||
# @license GNU General Public License (version 3)
|
||||
#
|
||||
# VILLASnode
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation, either version 3 of the License, or
|
||||
# any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
###################################################################################
|
||||
|
||||
ARG GIT_REV=unknown
|
||||
ARG GIT_BRANCH=unknown
|
||||
ARG VERSION=unknown
|
||||
ARG VARIANT=unknown
|
||||
ARG ALPINE_VERSION=edge
|
||||
|
||||
FROM alpine:${ALPINE_VERSION} AS builder
|
||||
|
||||
# Toolchain
|
||||
RUN apk update && \
|
||||
apk add gcc g++ \
|
||||
pkgconf cmake make \
|
||||
autoconf automake libtool \
|
||||
git \
|
||||
flex bison \
|
||||
protobuf
|
||||
|
||||
RUN echo "@testing http://dl-cdn.alpinelinux.org/alpine/edge/testing" >> /etc/apk/repositories
|
||||
|
||||
# Dependencies
|
||||
RUN apk update && \
|
||||
apk add \
|
||||
openssl-dev \
|
||||
ossp-uuid-dev@testing \
|
||||
libconfig-dev \
|
||||
libwebsockets-dev \
|
||||
curl-dev \
|
||||
jansson-dev \
|
||||
spdlog-dev \
|
||||
fmt-dev \
|
||||
libnl3-dev \
|
||||
graphviz-dev \
|
||||
protobuf-dev \
|
||||
protobuf-c-dev \
|
||||
zeromq-dev \
|
||||
nanomsg-dev@testing \
|
||||
rabbitmq-c-dev \
|
||||
mosquitto-dev \
|
||||
libusb-dev
|
||||
|
||||
ENV VARIANT=alpine
|
||||
ENV ARCH=x86_64
|
||||
ENV TRIPLET=x86_64-linux-gnu
|
||||
|
||||
# Install unpackaged dependencies from source
|
||||
# ADD packaging/deps.sh /
|
||||
# RUN bash deps.sh && ldconfig
|
||||
|
||||
COPY . /villas/
|
||||
|
||||
RUN mkdir -p /villas/build
|
||||
WORKDIR /villas/build
|
||||
RUN cmake .. && \
|
||||
make -j$(nproc) doc && \
|
||||
make -j$(nproc) install && \
|
||||
ldconfig
|
||||
|
||||
FROM alpine:${ALPINE_VERSION}
|
||||
|
||||
RUN apk add \
|
||||
openssl \
|
||||
ossp-uuid@testing \
|
||||
libconfig \
|
||||
libwebsockets \
|
||||
curl \
|
||||
jansson \
|
||||
spdlog \
|
||||
fmt \
|
||||
libnl3 \
|
||||
graphviz \
|
||||
protobuf \
|
||||
protobuf-c \
|
||||
zeromq \
|
||||
nanomsg@testing \
|
||||
rabbitmq-c \
|
||||
mosquitto \
|
||||
libusb
|
||||
|
||||
LABEL \
|
||||
org.label-schema.schema-version="1.0" \
|
||||
org.label-schema.name="VILLASnode" \
|
||||
org.label-schema.license="GPL-3.0" \
|
||||
org.label-schema.vcs-ref="$GIT_REV" \
|
||||
org.label-schema.vcs-branch="$GIT_BRANCH" \
|
||||
org.label-schema.version="$VERSION" \
|
||||
org.label-schema.variant="$VARIANT" \
|
||||
org.label-schema.vendor="Institute for Automation of Complex Power Systems, RWTH Aachen University" \
|
||||
org.label-schema.author.name="Steffen Vogel" \
|
||||
org.label-schema.author.email="stvogel@eonerc.rwth-aachen.de" \
|
||||
org.label-schema.description="A image containing all build-time dependencies for VILLASnode based on Fedora" \
|
||||
org.label-schema.url="http://fein-aachen.org/projects/villas-framework/" \
|
||||
org.label-schema.vcs-url="https://git.rwth-aachen.de/acs/public/villas/node" \
|
||||
org.label-schema.usage="https://villas.fein-aachen.org/doc/node-installation.html#node-installation-docker"
|
Loading…
Add table
Reference in a new issue