-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #31 from Laceyoo/main
添加apereo/cas目录,提供Dockerfile
- Loading branch information
Showing
67 changed files
with
4,663 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
target/** | ||
build/** | ||
bin/** | ||
.idea/** | ||
.history/** | ||
.github/** | ||
.git/** |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
# Set line endings to LF, even on Windows. Otherwise, execution within Docker fails. | ||
# See https://help.github.com/articles/dealing-with-line-endings/ | ||
*.sh text eol=lf | ||
gradlew text eol=lf | ||
*.cmd text eol=crlf | ||
*.bat text eol=crlf |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
|
||
### STS ### | ||
.apt_generated | ||
.classpath | ||
.factorypath | ||
.project | ||
.settings | ||
.springBeans | ||
.sts4-cache | ||
|
||
### IntelliJ IDEA ### | ||
.idea | ||
*.iws | ||
*.iml | ||
*.ipr | ||
|
||
### NetBeans ### | ||
/nbproject/private/ | ||
/nbbuild/ | ||
/dist/ | ||
/nbdist/ | ||
/.nb-gradle/ | ||
|
||
### VS Code ### | ||
.vscode/ | ||
.classpath | ||
!/.project | ||
.project | ||
.settings | ||
.history | ||
.vscode | ||
target/ | ||
.idea/ | ||
.DS_Store | ||
.idea | ||
overlays/ | ||
.gradle/ | ||
build/ | ||
log/ | ||
bin/ | ||
*.war | ||
*.iml | ||
*.log | ||
tmp/ | ||
.java-version | ||
./apache-tomcat | ||
apache-tomcat.zip | ||
config-metadata.properties |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
FROM eclipse-temurin:11-jdk AS overlay | ||
|
||
RUN mkdir -p cas-overlay | ||
COPY ./src cas-overlay/src/ | ||
COPY ./gradle/ cas-overlay/gradle/ | ||
COPY ./gradlew ./settings.gradle ./build.gradle ./gradle.properties ./lombok.config /cas-overlay/ | ||
|
||
RUN mkdir -p ~/.gradle \ | ||
&& echo "org.gradle.daemon=false" >> ~/.gradle/gradle.properties \ | ||
&& echo "org.gradle.configureondemand=true" >> ~/.gradle/gradle.properties \ | ||
&& cd cas-overlay \ | ||
&& chmod 750 ./gradlew \ | ||
&& ./gradlew --version; | ||
|
||
RUN cd cas-overlay \ | ||
&& ./gradlew clean build --parallel --no-daemon; | ||
|
||
FROM eclipse-temurin:11-jdk AS cas | ||
|
||
LABEL "Organization"="Apereo" | ||
LABEL "Description"="Apereo CAS" | ||
|
||
# 安装 sqlite3 | ||
RUN apt-get update \ | ||
&& apt-get install -y --no-install-recommends sqlite3 \ | ||
&& rm -rf /var/lib/apt/lists/* | ||
|
||
RUN cd / \ | ||
&& mkdir -p /etc/cas/config \ | ||
&& mkdir -p /etc/cas/services \ | ||
&& mkdir -p /etc/cas/saml \ | ||
&& mkdir -p cas-overlay; | ||
|
||
COPY --from=overlay cas-overlay/build/libs/cas.war cas-overlay/ | ||
COPY etc/cas/ /etc/cas/ | ||
COPY etc/cas/config/ /etc/cas/config/ | ||
COPY etc/cas/services/ /etc/cas/services/ | ||
COPY etc/cas/saml/ /etc/cas/saml/ | ||
|
||
EXPOSE 8080 8443 | ||
|
||
ENV PATH $PATH:$JAVA_HOME/bin:. | ||
|
||
WORKDIR cas-overlay | ||
ENTRYPOINT ["java", "-server", "-noverify", "-Xmx2048M", "-jar", "cas.war"] |
Oops, something went wrong.