Blizzard / s2client-proto

StarCraft II Client - protocol definitions used to communicate with StarCraft II.
MIT License
3.76k stars 431 forks source link

Request : distribute linux package in docker #36

Closed wizzup closed 6 years ago

wizzup commented 6 years ago

It would be nice if you can provide ready-to-run self-contained docker image for linux. I would love to just setup shared volume and send my bot to run.

I download linux-package but can't run it.

$ file StarCraftII/Versions/Base55958/SC2_x64 
StarCraftII/Versions/Base55958/SC2_x64: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 2.6.32, BuildID[sha1]=cb1cea9acb95b0c53e7a3cf18181fe5f7ff0e735, stripped

$ ./StarCraftII/Versions/Base55958/SC2_x64 
bash: ./StarCraftII/Versions/Base55958/SC2_x64: No such file or directory

$ cd works/beta_projects/starcraft2/s2client-api/build/bin/
$ ls
all_tests        bot_micro  bot_simple    feature_layers    libcivetweb.a  libprotobuf-lite.a  libsc2api.a  libsc2protocol.a  libsc2utils.a  libSDL2main.a  replay
annoying_helper  bot_mp     echo_actions  intermediate_bot  libprotobuf.a  libprotoc.a         libsc2lib.a  libsc2renderer.a  libSDL2.a      protoc         tutorial

$ ./all_tests -e ~/StarCraftII/Versions/Base55958/SC2_x64 
Running test: sc2::TestAbilityRemap
Launched SC2 (/home/wizzup/StarCraftII/Versions/Base55958/SC2_x64), PID: 10211
Failed to execute process /home/wizzup/StarCraftII/Versions/Base55958/SC2_x64 error: No such file or directory
^CWaiting for connection....
jrepp commented 6 years ago

Hey I just completed this, you can use the s2client-docker repo to build the images and run them yourself.

I haven't put them on docker hub yet, not sure if we will go that route.

I would love some additional help on the TODO items in the README. I don't have the tests running yet or the Replays auto downloading. I want the replay download to be an addon to the base image since we plan on regularly updating those pieces.

jrepp@jrepptu:~/s2client-docker$ docker ps
CONTAINER ID        IMAGE               COMMAND                  CREATED             STATUS              PORTS               NAMES
be22427d3a46        s2client-game       "/SC2/3.16.1/StarCraf"   13 minutes ago      Up 13 minutes       12000/tcp           peaceful_r
jrepp@jrepptu:~/s2client-docker$ docker logs be22
Version: B55958 (SC2.3.16)
Build: Jul 31 2017 13:19:41
Command Line: '"/SC2/3.16.1/StarCraftII/Versions/Base55958/SC2_x64" -listen 127.0.0.1 -port 12000'
Starting up...
Startup Phase 1 complete
Startup Phase 2 complete
Creating stub renderer...
Listening on: 127.0.0.1:12000 (12000)
Startup Phase 3 complete. Ready for commands.