This repository has been archived by the owner on Jan 31, 2023. It is now read-only.
generated from actions/hello-world-docker-action
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
48 lines (36 loc) · 1.75 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
# Most of this is copied from SwiftLint's Dockerfile because I don't
# really know how to use Docker or Swift on Linux
ARG BUILDER_IMAGE=swift:latest
ARG RUNTIME_IMAGE=swift:slim
# Builder image
FROM ${BUILDER_IMAGE} AS builder
WORKDIR /workdir/
COPY Source Source/
COPY Package.* ./
ARG SWIFT_FLAGS="-c release -Xswiftc -static-stdlib -Xswiftc -I. -Xlinker -fuse-ld=lld -Xlinker -L/usr/lib/swift/linux"
RUN swift build $SWIFT_FLAGS
RUN mkdir -p /executables
RUN for executable in $(swift package completion-tool list-executables); do \
install -v `swift build $SWIFT_FLAGS --show-bin-path`/$executable /executables; \
done
# rumtime image
FROM ${RUNTIME_IMAGE}
LABEL org.opencontainers.image.source https://github.com/ittybittyapps/reviewdog-action-xcode-issues
LABEL version="1.0.0"
LABEL repository="https://github.com/ittybittyapps/reviewdog-action-xcode-issues"
LABEL homepage="https://github.com/ittybittyapps/reviewdog-action-xcode-issues"
LABEL "com.github.actions.name"="Report issues from Xcode Result file with reviewdog"
LABEL "com.github.actions.description"="Reports isses from an Xcode .xcresult file on pull requests with reviewdog to improve code review experience."
LABEL "com.github.actions.icon"="alert-octagon"
LABEL "com.github.actions.color"="blue"
ENV REVIEWDOG_VERSION=v0.14.0
RUN apt-get update && apt-get install -y \
wget \
git \
&& rm -r /var/lib/apt/lists/*
RUN wget -O - -q https://raw.githubusercontent.com/reviewdog/reviewdog/master/install.sh| sh -s -- -b /usr/local/bin/ ${REVIEWDOG_VERSION}
COPY --from=builder /usr/lib/swift/linux/libBlocksRuntime.so /usr/lib
COPY --from=builder /usr/lib/swift/linux/libdispatch.so /usr/lib
COPY --from=builder /executables/* /usr/bin
COPY entrypoint.sh /entrypoint.sh
CMD ["xcissues"]