Blob Blame History Raw
# SPDX-License-Identifier: BSD-2-Clause
# Copyright (C) 2019 - 2020 Intel Corporation.

# Pull base image
FROM fedora:31

LABEL maintainer="katarzyna.wasiuta@intel.com"

# Update the dnf cache and install basic tools
RUN dnf update -y && dnf install -y \
    asciidoctor \
    automake \
    bash-completion \
    ca-certificates \
    daxctl-devel \
    devscripts \
    expect \
    g++ \
    git \
    json-c-devel \
    keyutils-libs-devel \
    kmod-devel \
    libtool \
    libudev-devel \
    libuuid-devel \
    numactl \
    numactl-devel \
    pkgconfig \
    python-pip \
    rpmdevtools \
    sudo \
    systemd \
    which \
    whois \
 && dnf clean all

# Install packages required by python tests
RUN pip install wheel
RUN pip install setuptools==3.4.1
RUN pip install pytest==3.9.2

# Add user
ENV USER memkinduser
ENV USERPASS memkindpass
RUN useradd -m $USER -p `mkpasswd $USERPASS`
RUN gpasswd wheel -a $USER
RUN echo '%wheel ALL=(ALL) NOPASSWD:ALL' >> /etc/sudoers

# Create directory for memkind repository
WORKDIR /home/$USER/memkind

# Allow user to create files in the home directory
RUN chown -R $USER:wheel /home/$USER

# Change user to $USER
USER $USER