mirror of
https://github.com/xerial/snappy-java.git
synced 2025-08-17 07:58:18 +02:00
37 lines
767 B
Docker
37 lines
767 B
Docker
FROM alpine:3.18
|
|
|
|
# Set workspace directory
|
|
WORKDIR /work
|
|
|
|
# Copy the project to the container
|
|
COPY . .
|
|
|
|
# Install build dependencies
|
|
RUN apk add --no-cache \
|
|
openjdk8 \
|
|
cmake \
|
|
make \
|
|
gcc \
|
|
g++ \
|
|
musl-dev \
|
|
linux-headers \
|
|
git \
|
|
util-linux \
|
|
bash \
|
|
curl
|
|
|
|
# Install SBT
|
|
RUN curl -L "https://github.com/sbt/sbt/releases/download/v1.9.7/sbt-1.9.7.tgz" | tar xz -C /usr/local
|
|
ENV PATH="/usr/local/sbt/bin:${PATH}"
|
|
|
|
# Install python/pip
|
|
ENV PYTHONUNBUFFERED=1
|
|
RUN apk add --update --no-cache python3 && ln -sf python3 /usr/bin/python
|
|
RUN python3 -m ensurepip
|
|
RUN pip3 install --no-cache --upgrade pip setuptools
|
|
|
|
# Set Env Vars
|
|
ENV CC=gcc CXX=g++
|
|
ENV JAVA_HOME=/usr/lib/jvm/java-1.8-openjdk
|
|
ENV PATH="${JAVA_HOME}/bin:${PATH}"
|