2018-11-23 08:14:13 +01:00
|
|
|
# This is a manifest image, will pull the image with the same arch as the builder machine
|
2019-03-20 04:34:47 +01:00
|
|
|
FROM mcr.microsoft.com/dotnet/core/sdk:2.1.505 AS builder
|
2019-03-31 07:08:53 +02:00
|
|
|
RUN apt-get update \
|
|
|
|
&& apt-get install -qq --no-install-recommends qemu qemu-user-static qemu-user binfmt-support
|
|
|
|
|
2017-09-29 08:05:18 +02:00
|
|
|
WORKDIR /source
|
2019-06-17 14:42:48 +02:00
|
|
|
COPY Build/Common.csproj Build/Common.csproj
|
2019-06-02 10:06:00 +02:00
|
|
|
COPY BTCPayServer/BTCPayServer.csproj BTCPayServer/BTCPayServer.csproj
|
|
|
|
COPY BTCPayServer.Common/BTCPayServer.Common.csproj BTCPayServer.Common/BTCPayServer.Common.csproj
|
|
|
|
COPY BTCPayServer.Rating/BTCPayServer.Rating.csproj BTCPayServer.Rating/BTCPayServer.Rating.csproj
|
2019-09-04 10:37:40 +02:00
|
|
|
COPY BTCPayServer.Data/BTCPayServer.Data.csproj BTCPayServer.Data/BTCPayServer.Data.csproj
|
2019-06-18 06:51:04 +02:00
|
|
|
RUN cd BTCPayServer && dotnet restore
|
2019-06-02 10:33:35 +02:00
|
|
|
COPY BTCPayServer.Common/. BTCPayServer.Common/.
|
2019-06-03 18:55:07 +02:00
|
|
|
COPY BTCPayServer.Rating/. BTCPayServer.Rating/.
|
2019-09-04 10:37:40 +02:00
|
|
|
COPY BTCPayServer.Data/. BTCPayServer.Data/.
|
2019-06-03 18:55:07 +02:00
|
|
|
COPY BTCPayServer/. BTCPayServer/.
|
2019-06-17 14:42:48 +02:00
|
|
|
COPY Build/Version.csproj Build/Version.csproj
|
2019-06-02 10:06:00 +02:00
|
|
|
RUN cd BTCPayServer && dotnet publish --output /app/ --configuration Release
|
2018-05-09 07:09:41 +02:00
|
|
|
|
2018-11-23 08:14:13 +01:00
|
|
|
# Force the builder machine to take make an arm runtime image. This is fine as long as the builder does not run any program
|
2019-03-20 04:34:47 +01:00
|
|
|
FROM mcr.microsoft.com/dotnet/core/aspnet:2.1.9-stretch-slim-arm32v7
|
2019-03-31 07:08:53 +02:00
|
|
|
COPY --from=builder /usr/bin/qemu-arm-static /usr/bin/qemu-arm-static
|
2019-09-20 10:23:32 +02:00
|
|
|
RUN apt-get update && apt-get install -y --no-install-recommends iproute2 openssh-client \
|
2019-03-31 07:08:53 +02:00
|
|
|
&& rm -rf /var/lib/apt/lists/*
|
2018-05-09 07:09:41 +02:00
|
|
|
|
|
|
|
ENV LC_ALL en_US.UTF-8
|
|
|
|
ENV LANG en_US.UTF-8
|
|
|
|
|
2018-11-23 03:21:01 +01:00
|
|
|
WORKDIR /datadir
|
2017-09-29 08:05:18 +02:00
|
|
|
WORKDIR /app
|
|
|
|
ENV BTCPAY_DATADIR=/datadir
|
|
|
|
VOLUME /datadir
|
|
|
|
|
|
|
|
COPY --from=builder "/app" .
|
2019-02-27 13:58:28 +01:00
|
|
|
COPY docker-entrypoint.sh docker-entrypoint.sh
|
2019-02-27 13:56:36 +01:00
|
|
|
ENTRYPOINT ["/app/docker-entrypoint.sh"]
|