-
Notifications
You must be signed in to change notification settings - Fork 528
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(chore): remove zgc in dockerfile for ARM env (#2421)
* remove zgc * Apply suggestions from code review Co-authored-by: imbajin <[email protected]> * add comment for hugegraph-server.sh * fix enable-auth.sh * init store in entrypoint * use flag file to skip re-init * delete tar.gz * simply dockerfile * mvn optimize * simply dockerfile * add init log in docker --------- Co-authored-by: imbajin <[email protected]>
- Loading branch information
1 parent
1dd0580
commit b980df8
Showing
5 changed files
with
46 additions
and
34 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -23,13 +23,13 @@ COPY . /pkg | |
WORKDIR /pkg | ||
ARG MAVEN_ARGS | ||
|
||
RUN mvn package $MAVEN_ARGS -e -B -ntp -DskipTests -Dmaven.javadoc.skip=true && pwd && ls -l | ||
RUN mvn package $MAVEN_ARGS -e -B -ntp -DskipTests -Dmaven.javadoc.skip=true && pwd && ls -l && rm ./hugegraph-server/*.tar.gz | ||
|
||
# 2nd stage: runtime env | ||
# Note: ZGC (The Z Garbage Collector) is only supported on ARM-Mac with java > 13 | ||
FROM openjdk:11-slim | ||
# TODO: get the version from the pom.xml | ||
ENV version=1.2.0 | ||
COPY --from=build /pkg/hugegraph-server/apache-hugegraph-incubating-$version/ /hugegraph-server | ||
|
||
COPY --from=build /pkg/hugegraph-server/apache-hugegraph-incubating-*/ /hugegraph-server/ | ||
LABEL maintainer="HugeGraph Docker Maintainers <[email protected]>" | ||
|
||
# TODO: use g1gc or zgc as default | ||
|
@@ -39,7 +39,7 @@ ENV JAVA_OPTS="-XX:+UnlockExperimentalVMOptions -XX:+UseContainerSupport -XX:Max | |
#COPY . /hugegraph/hugegraph-server | ||
WORKDIR /hugegraph-server/ | ||
|
||
# 1. Install environment | ||
# 1. Install environment and init HugeGraph Sever | ||
RUN set -x \ | ||
&& apt-get -q update \ | ||
&& apt-get -q install -y --no-install-recommends --no-install-suggests \ | ||
|
@@ -48,15 +48,14 @@ RUN set -x \ | |
curl \ | ||
lsof \ | ||
vim \ | ||
cron \ | ||
&& apt-get clean \ | ||
&& rm -rf /var/lib/apt/lists/* | ||
|
||
# 2. Init HugeGraph Sever | ||
RUN set -e \ | ||
&& rm -rf /var/lib/apt/lists/* \ | ||
&& service cron start \ | ||
&& pwd && cd /hugegraph-server/ \ | ||
&& sed -i "s/^restserver.url.*$/restserver.url=http:\/\/0.0.0.0:8080/g" ./conf/rest-server.properties | ||
|
||
# 3. Init docker script | ||
# 2. Init docker script | ||
COPY hugegraph-server/hugegraph-dist/docker/scripts/remote-connect.groovy ./scripts | ||
COPY hugegraph-server/hugegraph-dist/docker/scripts/detect-storage.groovy ./scripts | ||
COPY hugegraph-server/hugegraph-dist/docker/docker-entrypoint.sh . | ||
|
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
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