Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

enter the console #29

Open
Zappelphilipp opened this issue Jan 3, 2018 · 6 comments
Open

enter the console #29

Zappelphilipp opened this issue Jan 3, 2018 · 6 comments

Comments

@Zappelphilipp
Copy link

first of all, thank you very much. Its just awsome how easy this project is making admins life ;)
but one thing is just a bit of a hassle: to use the console. Is it possible somehow to return to the console instead of just using "mc_start" and so on? Just like with using screen i would love to somehow get into the server console.

@nimmis
Copy link
Owner

nimmis commented Jan 3, 2018

This version is built without using screen or tmux, it uses files as pipes to communicate with the server.

Is it to difficult to use the mc_send command to pass commands to the console?

@nimmis nimmis closed this as completed Jan 3, 2018
@nimmis nimmis reopened this Jan 3, 2018
@nimmis
Copy link
Owner

nimmis commented Jan 3, 2018

sorry pressed the wrong button

@nimmis
Copy link
Owner

nimmis commented Jan 3, 2018

can you describe the actual problem so can I see if I can find a solution

@Zappelphilipp
Copy link
Author

it isnt a problem at all, just a bit inconvenient imo because you ether can see the log "mc_log" or send a command but i helped myself by using two terminals, one for sending commands, one for tracking the status but yeah, maybe there is another way to solve this in the future :)

@BertKleewein
Copy link

I think I have the same request. I'm using this to set up a server for my son, so i'm finding myself typing lots of console commands, especially as I'm learning all the different commands. I have 2 bash windows open, one with mc_log running, and one for typing commands. In the command bash, I'm constantly using mc_send, looking at the output, and hitting ctrl-c again.

(I also have a third window running DragonProxy, but that's just a matter of me finding the right way to script it to launch automatically.)

It would be nice if I could have one window with the mc_log output that could also accept input, so that

  1. I didn't need the second window
  2. My fingers could get used to typing commands with a slash prefix instead of an mc_send prefix.
  3. I wasn't constantly pressing ctrl-c between each command.

Like @Zappelphilipp said, it's not a big problem, but it is inconvenient.

By the way, this project is incredible. You have saved me so much pain and this exactly the kind of thing that docker is good at. I really appreciate the work you've put into this!

@BertKleewein
Copy link

OK, I found a better workaround for my purposes:
from my host, I launch a bash shell on the container:

bert@Beast:/$ docker exec -it spigot /bin/bash

Then, from the container shell, I stop the current instance:

root@2f72218455a3:~# mc_stop
spigot: stopped

Then I launch interactively:

root@2f72218455a3:~#su -s /bin/sh -c "/usr/bin/java -Xmx1G -Xms1G -jar /minecraft/spigot.jar nogui" minecraft
Loading libraries, please wait...

At this point, I can party on. However, if I control-c or otherwise exit the interactive prompt, the server stops. That makes this trick good for quick iteration and learning, but useless for production.

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

No branches or pull requests

3 participants