Skip to content

Commit

Permalink
Try to use custom Dockerfile
Browse files Browse the repository at this point in the history
tors42 committed Oct 6, 2024
1 parent 64f02a7 commit b3317cb
Showing 2 changed files with 23 additions and 1 deletion.
3 changes: 2 additions & 1 deletion .github/workflows/it.yml
Original file line number Diff line number Diff line change
@@ -11,7 +11,8 @@ jobs:
container: ubuntu:22.04
services:
lila:
image: ghcr.io/lichess-org/lila-docker:main
#image: ghcr.io/lichess-org/lila-docker:main
image: 'Dockerfile'
options: --restart=always

steps:
21 changes: 21 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
FROM ghcr.io/lichess-org/lila-docker:main

RUN rm -rf /opt/java/openjdk

RUN curl -L -o jdk.tgz https://download.java.net/java/GA/jdk23/3c5b90190c68498b986a97f276efd28a/37/GPL/openjdk-23_linux-$(uname -i)_bin.tar.gz
RUN tar xzf jdk.tgz
RUN mv jdk-23 /opt/java/openjdk

ADD FastAutoStartRelayAgent.java .

RUN javac --enable-preview --release 23 -d agentclasses FastAutoStartRelayAgent.java

RUN printf 'Premain-Class: FastAutoStartRelayAgent \n\
Can-Retransform-Classes: true \n\
' >> agent.mf

RUN jar --create --file=/FastAutoStartRelayAgent.jar --manifest=agent.mf -C agentclasses .


ENV _JAVA_OPTIONS="--enable-preview -javaagent:/FastAutoStartRelayAgent.jar"

0 comments on commit b3317cb

Please sign in to comment.