-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
61 lines (49 loc) · 1.8 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
49
50
51
52
53
54
55
56
57
58
59
60
61
################################
### APEREO CAS 6.6.x ###
################################
FROM kimbrechts/docker-jdk-alpine:17.0.9-alp-3.18.0
LABEL maintainer="imbrechts.kevin+cas@protonmail.com"
ENV LASTREFRESH="20231030" \
PATH=$PATH:$JRE_HOME/bin \
CAS_VERSION="6.6.x"
RUN apk update && \
apk add --no-cache --virtual utils \
git=2.40.1-r0 \
bash=5.2.15-r5
# Download CAS overlay project
WORKDIR /
RUN git clone --depth 1 --single-branch -b ${CAS_VERSION} https://github.com/apereo/cas.git cas-overlay
# Download Maven-Wrapper
WORKDIR /tmp
RUN git clone --depth 1 --single-branch -b master https://github.com/takari/maven-wrapper.git maven-wrapper && \
mkdir -p /cas-overlay/.mvn/wrapper && \
mv /tmp/maven-wrapper/.mvn/wrapper/maven-wrapper.jar /cas-overlay/.mvn/wrapper/ && \
mv /tmp/maven-wrapper/.mvn/wrapper/maven-wrapper.properties /cas-overlay/.mvn/wrapper/ && \
mv /tmp/maven-wrapper/mvnw /cas-overlay/
COPY cas-overlay/build.sh /cas-overlay/
COPY cas-overlay/pom.xml /cas-overlay/
COPY etc/cas/ /etc/cas/
WORKDIR /
RUN chmod 750 cas-overlay/.mvn && \
chmod 750 cas-overlay/*.sh && \
chmod 750 /opt/java-home/bin/java
# Cleaning
RUN apk del git && \
rm -rf /cas-overlay/.git* && \
rm -rf /cas-overlay/ci && \
rm -rf /cas-overlay/docs && \
rm -rf /cas-overlay/gradle && \
rm -f /cas-overlay/.mergify.yml && \
rm -f /cas-overlay/.travis.yml && \
rm -f /cas-overlay/LICENSE && \
rm -f /cas-overlay/NOTICE && \
rm -f /cas-overlay/README.md && \
rm -f /cas-overlay/build.gradle && \
rm -f /cas-overlay/gradle.properties && \
rm -f /cas-overlay/gradlew* && \
rm -f /cas-overlay/release.sh && \
rm -f /cas-overlay/settings.gradle
EXPOSE 8080 8443
WORKDIR /cas-overlay
ENTRYPOINT ["build.sh"]
CMD ["run"]