mirror of
https://github.com/corda/corda.git
synced 2024-12-18 20:47:57 +00:00
Changes for Apple ARM docker image
This commit is contained in:
parent
0ca969913a
commit
678f420d19
@ -21,7 +21,7 @@ gradlew docker:buildDockerImage --image NON_EXISTENT_IMAGE_VARIANT
|
||||
```
|
||||
results in
|
||||
```
|
||||
> Cannot convert string value 'NON_EXISTENT_IMAGE_VARIANT' to an enum value of type 'ImageVariant' (valid case insensitive values: UBUNTU_ZULU, UBUNTU_ZULU_11, AL_CORRETTO, OFFICIAL)
|
||||
> Cannot convert string value 'NON_EXISTENT_IMAGE_VARIANT' to an enum value of type 'ImageVariant' (valid case insensitive values: UBUNTU_ZULU, UBUNTU_ZULU_11, AL_CORRETTO, ARM, OFFICIAL)
|
||||
```
|
||||
If no image variant is specified, all available image variants will be built.
|
||||
|
||||
|
@ -36,6 +36,7 @@ enum ImageVariant {
|
||||
UBUNTU_ZULU("Dockerfile", "1.8", "zulu-openjdk8"),
|
||||
UBUNTU_ZULU_11("Dockerfile11", "11", "zulu-openjdk11"),
|
||||
AL_CORRETTO("DockerfileAL", "1.8", "amazonlinux2"),
|
||||
ARM("DockerfileARM", "1.8", "openjdk8"),
|
||||
OFFICIAL(UBUNTU_ZULU)
|
||||
|
||||
String dockerFile
|
||||
|
67
docker/src/docker/DockerfileARM
Normal file
67
docker/src/docker/DockerfileARM
Normal file
@ -0,0 +1,67 @@
|
||||
FROM arm64v8/openjdk:8
|
||||
|
||||
## Add packages, clean cache, create dirs, create corda user and change ownership
|
||||
RUN apt-get update && \
|
||||
# apt-mark hold zulu8-jdk && \
|
||||
apt-get -y upgrade && \
|
||||
apt-get -y install bash curl unzip && \
|
||||
rm -rf /var/lib/apt/lists/* && \
|
||||
mkdir -p /opt/corda/cordapps && \
|
||||
mkdir -p /opt/corda/persistence && \
|
||||
mkdir -p /opt/corda/artemis && \
|
||||
mkdir -p /opt/corda/certificates && \
|
||||
mkdir -p /opt/corda/drivers && \
|
||||
mkdir -p /opt/corda/logs && \
|
||||
mkdir -p /opt/corda/bin && \
|
||||
mkdir -p /opt/corda/additional-node-infos && \
|
||||
mkdir -p /etc/corda && \
|
||||
addgroup corda && \
|
||||
useradd corda -g corda -m -d /opt/corda && \
|
||||
chown -R corda:corda /opt/corda && \
|
||||
chown -R corda:corda /etc/corda
|
||||
|
||||
ENV CORDAPPS_FOLDER="/opt/corda/cordapps" \
|
||||
PERSISTENCE_FOLDER="/opt/corda/persistence" \
|
||||
ARTEMIS_FOLDER="/opt/corda/artemis" \
|
||||
CERTIFICATES_FOLDER="/opt/corda/certificates" \
|
||||
DRIVERS_FOLDER="/opt/corda/drivers" \
|
||||
CONFIG_FOLDER="/etc/corda" \
|
||||
MY_P2P_PORT=10200 \
|
||||
MY_RPC_PORT=10201 \
|
||||
MY_RPC_ADMIN_PORT=10202 \
|
||||
PATH=$PATH:/opt/corda/bin \
|
||||
JVM_ARGS="-XX:+UseG1GC -XX:+UnlockExperimentalVMOptions -XX:+UseCGroupMemoryLimitForHeap " \
|
||||
CORDA_ARGS=""
|
||||
|
||||
##CORDAPPS FOLDER
|
||||
VOLUME ["/opt/corda/cordapps"]
|
||||
##PERSISTENCE FOLDER
|
||||
VOLUME ["/opt/corda/persistence"]
|
||||
##ARTEMIS FOLDER
|
||||
VOLUME ["/opt/corda/artemis"]
|
||||
##CERTS FOLDER
|
||||
VOLUME ["/opt/corda/certificates"]
|
||||
##OPTIONAL JDBC DRIVERS FOLDER
|
||||
VOLUME ["/opt/corda/drivers"]
|
||||
##LOG FOLDER
|
||||
VOLUME ["/opt/corda/logs"]
|
||||
##ADDITIONAL NODE INFOS FOLDER
|
||||
VOLUME ["/opt/corda/additional-node-infos"]
|
||||
##CONFIG LOCATION
|
||||
VOLUME ["/etc/corda"]
|
||||
|
||||
##CORDA JAR
|
||||
COPY --chown=corda:corda corda.jar /opt/corda/bin/corda.jar
|
||||
##CONFIG MANIPULATOR JAR
|
||||
COPY --chown=corda:corda config-exporter.jar /opt/corda/config-exporter.jar
|
||||
##CONFIG GENERATOR SHELL SCRIPT
|
||||
COPY --chown=corda:corda generate-config.sh /opt/corda/bin/config-generator
|
||||
##CORDA RUN SCRIPT
|
||||
COPY --chown=corda:corda run-corda.sh /opt/corda/bin/run-corda
|
||||
##BASE CONFIG FOR GENERATOR
|
||||
COPY --chown=corda:corda starting-node.conf /opt/corda/starting-node.conf
|
||||
|
||||
USER "corda"
|
||||
EXPOSE ${MY_P2P_PORT} ${MY_RPC_PORT} ${MY_RPC_ADMIN_PORT}
|
||||
WORKDIR /opt/corda
|
||||
CMD ["run-corda"]
|
Loading…
Reference in New Issue
Block a user