From 5a98cf326b9d8f4903f14030f91a248d77152580 Mon Sep 17 00:00:00 2001 From: Dom Whewell Date: Sat, 9 Nov 2024 21:56:02 +0000 Subject: [PATCH] set the JAVA_HOME environment variable on fedora --- bbot/modules/jadx.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/bbot/modules/jadx.py b/bbot/modules/jadx.py index 8b873face..835d22343 100644 --- a/bbot/modules/jadx.py +++ b/bbot/modules/jadx.py @@ -37,6 +37,18 @@ class jadx(BaseModule): "become": True, "when": "ansible_facts['os_family'] == 'RedHat'", }, + { + "name": "Set JAVA_HOME (Fedora)", + "command": "echo \"export JAVA_HOME=$(readlink -f /usr/bin/java | sed 's:bin/java::')\" >> ~/.bashrc", + "become": True, + "when": "ansible_facts['os_family'] == 'RedHat'", + }, + { + "name": "Use JAVA_HOME (Fedora)", + "command": "source ~/.bashrc", + "become": True, + "when": "ansible_facts['os_family'] == 'RedHat'", + }, { "name": "Install latest JRE (Alpine)", "package": {"name": ["openjdk11"], "state": "present"},