Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Nov 8, 2025

Pull Request – Simulation Only

Summary

Fixes critical bash syntax errors introduced in commit f2633e1 that prevented setup_minecraft.sh and setup_minecraft_lxc.sh from executing. The malformed lines concatenated multiple conditions without proper && operators.

Before (broken):

(( xmx < 2048 )) (( xmx < 448 )) && xmx=448(( xmx < 448 )) && xmx=448 xmx=2048
(( xms < 1024 )) (( xms < 256 )) && xms=256(( xms < 256 )) && xms=256 xms=1024

After (corrected):

(( xmx < 2048 )) && xmx=2048
(( xms < 1024 )) && xms=1024

Also updates memory floor comments from 256M/448M to 1024M/2048M to match implementation.

Checklist

  • No commands executed locally; all steps are simulated/explained only.
  • Changes are limited to scripts and/or documentation.
  • SIMULATION.md updated to reflect behavior and risks.
  • If adding a new script or option, included example usage commands (chmod +x; ./script; screen -r ...).
  • Security considerations addressed (least-privilege user, ports, backups).

Testing (Simulation)

Both scripts pass bash -n syntax validation. When executed on a Proxmox VM/LXC:

  • JVM will allocate minimum 1GB Xms and 2GB Xmx regardless of system RAM
  • Prevents undersized heap on low-memory hosts (< 4GB RAM)
  • Cap at 16GB Xmx remains unchanged
  • No rollback needed; scripts create new server instances under /opt/minecraft

💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

Copilot AI self-assigned this Nov 8, 2025
@TimInTech TimInTech marked this pull request as ready for review November 8, 2025 16:13
Copilot AI review requested due to automatic review settings November 8, 2025 16:13
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot wasn't able to review any files in this pull request.

Co-authored-by: TimInTech <129355283+TimInTech@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix JVM memory allocation settings and URL format fix: correct bash syntax in JVM memory floor enforcement Nov 8, 2025
Copilot AI requested a review from TimInTech November 8, 2025 16:17
@TimInTech TimInTech merged commit e2ff153 into feat/java-mem-floors Nov 8, 2025
@TimInTech TimInTech deleted the copilot/sub-pr-56-again branch November 8, 2025 16:21
TimInTech added a commit that referenced this pull request Nov 12, 2025
* docs(README): fix Issues link to HTTPS

* feat(setup): raise JVM floors to Xms≥1G and Xmx≥2G

* fix: correct bash syntax in JVM memory floor enforcement (#59)

* Initial plan

* fix(setup): correct bash syntax for JVM memory floor checks

Co-authored-by: TimInTech <129355283+TimInTech@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TimInTech <129355283+TimInTech@users.noreply.github.com>

* fix: correct bash syntax in JVM memory floor assignments (#58)

* Initial plan

* fix: correct bash syntax errors in memory floor assignments

Co-authored-by: TimInTech <129355283+TimInTech@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TimInTech <129355283+TimInTech@users.noreply.github.com>

---------

Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants