c4k-mastodon-bot/doc/GraalVM.md

24 lines
727 B
Markdown
Raw Normal View History

2021-03-19 11:14:50 +00:00
# install graalvm
curl -LO https://github.com/graalvm/graalvm-ce-builds/releases/download/vm-21.0.0.2/graalvm-ce-java11-linux-amd64-21.0.0.2.tar.gz
2021-03-19 11:12:45 +00:00
2021-03-19 11:14:50 +00:00
# unpack
tar -xzf graalvm-ce-java11-linux-amd64-21.0.0.2.tar.gz
2021-03-19 11:12:45 +00:00
2021-03-19 11:14:50 +00:00
# install native-image in graalvm-ce-java11-linux-amd64-21.0.0.2/bin
2021-03-19 12:36:54 +00:00
```
# ./gu is inside the /bin folder
2021-03-19 11:14:50 +00:00
./gu install native-image
2021-03-19 11:12:45 +00:00
2021-03-19 12:36:54 +00:00
# after you installed native-image, there should appere a ./native-image file
```
2021-03-19 11:14:50 +00:00
# deps
sudo apt-get install build-essential libz-dev zlib1g-dev
# build image. e.g.
./bin/native-image -jar ~/repo/dda/k8s-mastodon-bot/target/uberjar/k8s-mastodon-bot-0.1.3-SNAPSHOT.jar ~/repo/dda/k8s-mastodon-bot/target/bot
2021-03-19 12:36:54 +00:00
# execute
```
cd ~/repo/dda/k8s-mastodon-bot/target/bot
./bot
```