Fix send-command to work on arm64 (#328)

This commit is contained in:
Geoff Bourne authored and GitHub committed 2023-06-01 10:28:32 -05:00
1 parent 63f2ff9604
commit e421ad2ca6
1 file changed
+2 -1
+2 -1
View File
@@ -1,7 +1,8 @@
#!/bin/bash #!/bin/bash
if [[ $* ]]; then if [[ $* ]]; then
if proc=$(find /proc -mindepth 2 -maxdepth 2 -name exe -lname '/data/bedrock_server-*' -printf '%h' -quit); then # On arm64, the process exe is actually box64 since it in turn wraps the bedrock_server executable
if proc=$(find /proc -mindepth 2 -maxdepth 2 -name exe \( -lname '/data/bedrock_server-*' -o -lname /usr/local/bin/box64 \) -printf '%h' -quit); then
if [[ $proc ]]; then if [[ $proc ]]; then
echo "$@" > "$proc/fd/0" echo "$@" > "$proc/fd/0"
else else