Yaribz / SPADS

SpringRTS Perl Autohost for Dedicated Server
GNU General Public License v3.0
17 stars 16 forks source link

Failing to build unitsync inside docker #41

Closed TurBoss closed 6 years ago

TurBoss commented 6 years ago

ubutnu 16.04 + docker-ce

here is the DockerFile

FROM alpine
MAINTAINER  TurBoss

RUN apk add --update  perl perl-dev swig g++

RUN mkdir -p /opt/spads

RUN wget https://github.com/Yaribz/SPADS/raw/master/src/spadsInstaller.pl -P /opt/spads/
RUN wget https://github.com/Yaribz/SPADS/raw/master/src/SpadsUpdater.pm -P /opt/spads/
RUN wget https://github.com/Yaribz/SPADS/raw/master/src/PerlUnitSync.pm -P /opt/spads/
RUN wget https://github.com/Yaribz/SimpleLog/raw/master/SimpleLog.pm -P /opt/spads/
RUN wget https://github.com/Yaribz/SimpleEvent/raw/master/SimpleEvent.pm -P /opt/spads/
RUN wget https://github.com/Yaribz/SpringLobbyInterface/raw/master/SpringLobbyInterface.pm -P /opt/spads/
RUN wget https://github.com/Yaribz/SpringAutoHostInterface/raw/master/SpringAutoHostInterface.pm -P /opt/spads/

RUN perl /opt/spads/spadsInstaller.pl

CMD perl /opt/spads/spads.pl /opt/spads/etc/spads.conf
~                                                                

and the resulting error

Step 12/13 : RUN perl /opt/spads/spadsInstaller.pl
 ---> Running in 9c6f8ee07765

This program will install SPADS in the current working directory, overwriting files if needed.
The installer will ask you 15 questions maximum to customize your installation and pre-configure SPADS.
You can stop this installation at any time by hitting Ctrl-c.
Note: if SPADS is already installed on the system, you don't need to reinstall it to run multiple autohosts. Instead, you can share SPADS binaries and use multiple configuration files and/or configuration macros.

1/15 - Which SPADS release do you want to install (stable,testing,unstable,contrib) [testing] ? 
20171229022946 - INFO     - [SpadsUpdater] Updating package "getDefaultModOptions.pl" to "getDefaultModOptions_0.6.pl"
20171229022946 - INFO     - [SpadsUpdater] Updating package "help.dat" to "help_0.13.1.dat"
20171229022946 - INFO     - [SpadsUpdater] Updating package "helpSettings.dat" to "helpSettings_0.6.0.dat"
20171229022946 - INFO     - [SpadsUpdater] Updating package "SpringAutoHostInterface.pm" to "SpringAutoHostInterface_0.11.pm"
20171229022946 - INFO     - [SpadsUpdater] Updating package "SpringLobbyInterface.pm" to "SpringLobbyInterface_0.23.pm"
20171229022946 - INFO     - [SpadsUpdater] Updating package "SimpleEvent.pm" to "SimpleEvent_0.1c.pm"
20171229022947 - INFO     - [SpadsUpdater] Updating package "SimpleLog.pm" to "SimpleLog_0.7.pm"
20171229022947 - INFO     - [SpadsUpdater] Updating package "spads.pl" to "spads_0.12.2a.pl"
20171229022947 - INFO     - [SpadsUpdater] Updating package "SpadsConf.pm" to "SpadsConf_0.12.0a.pm"
20171229022947 - INFO     - [SpadsUpdater] Updating package "spadsInstaller.pl" to "spadsInstaller_0.21.pl"
20171229022947 - INFO     - [SpadsUpdater] Updating package "SpadsUpdater.pm" to "SpadsUpdater_0.13a.pm"
20171229022948 - INFO     - [SpadsUpdater] Updating package "SpadsPluginApi.pm" to "SpadsPluginApi_0.22a.pm"
20171229022948 - INFO     - [SpadsUpdater] Updating package "update.pl" to "update_0.11.pl"
20171229022948 - INFO     - [SpadsUpdater] Updating package "argparse.py" to "argparse-1.2.1.py"
20171229022948 - INFO     - [SpadsUpdater] Updating package "replay_upload.py" to "replay_upload_0.6.py"
20171229022948 - INFO     - [SpadsUpdater] Updating package "7za" to "7za-16.2"
20171229022949 - NOTICE   - [SpadsUpdater] 16 package(s) updated
20171229022949 - NOTICE   - [SpadsInstaller] Restarting installer after update...
20171229022951 - NOTICE   - [SpadsInstaller] SPADS components are up to date, proceeding with installation...
2/15 - Please choose the directory where SPADS configuration files will be stored [etc] ? 
20171229022951 - NOTICE   - [SpadsInstaller] Directory "/opt/spads/etc" created
20171229022951 - NOTICE   - [SpadsInstaller] Directory "/opt/spads/etc/templates" created
3/15 - Please choose the directory where SPADS dynamic data will be stored [var] ? 
20171229022951 - NOTICE   - [SpadsInstaller] Directory "/opt/spads/var" created
20171229022951 - NOTICE   - [SpadsInstaller] Directory "/opt/spads/var/plugins" created
20171229022951 - NOTICE   - [SpadsInstaller] Directory "/opt/spads/var/spring" created
4/15 - Please choose the directory where SPADS will write the logs [log] ? 
20171229022951 - NOTICE   - [SpadsInstaller] Directory "/opt/spads/var/log" created
20171229022951 - NOTICE   - [SpadsInstaller] Directory "/opt/spads/var/log/chat" created
5/15 - Do you want to use official Spring binary files (auto-managed by SPADS), or a custom Spring installation already existing on the system? (official,custom) [official] ? 
20171229022951 - NOTICE   - [SpadsInstaller] Checking available Spring versions...

Available Spring versions:
  104.0.1
  104.0.1-448-g243c5dd [UNSTABLE] (latest develop version)
  104.0.1-446-gcb2e6d5
  104.0.1-445-g6d402aa
  104.0.1-443-ga67d7cc
  104.0.1-442-gd5228b6
  [...]
  104.0 [STABLE] (recommended release) + [TESTING] (next release candidate)
  103.0
  102.0
  101.0
  100.0
  [...]

Please choose the Spring version which will be used by the autohost.
If you choose "stable", "testing" or "unstable", SPADS will stay up to date with the corresponding official Spring release by automatically downloading and using new Spring binary files when needed.
If you choose a specific Spring version number ("104.0", "104.0.1-448-g243c5dd", ...), SPADS will stick to this version until you manualy change it in the configuration file.

6/15 - Which Spring version do you want to use (104.0,104.0.1-448-g243c5dd,stable,testing,unstable,...) [104.0] ? 
20171229022952 - INFO     - [SpadsUpdater] Created new directory "/opt/spads/var/spring/104.0-linux64" for Spring installation
20171229022952 - NOTICE   - [SpadsUpdater] Installing Spring 104.0 into "/opt/spads/var/spring/104.0-linux64"...
20171229022954 - NOTICE   - [SpadsUpdater] Spring 104.0 installation complete.
20171229022955 - NOTICE   - [SpadsInstaller] SPADS components are up to date, proceeding with installation...
20171229022955 - NOTICE   - [SpadsInstaller] Generating Perl Unitsync interface module...
7/15 - Please enter the absolute path of the Spring data directory containing the games and maps hosted by the autohost, or press enter to use a new directory instead [new] ? 
20171229022957 - NOTICE   - [SpadsInstaller] Retrieving the list of games available for download...
20171229022959 - WARNING  - [SpadsInstaller] Unable to retrieve archives list for game Zero-K
20171229022959 - NOTICE   - [SpadsInstaller] Directory "/opt/spads/var/spring/data/games" created

Directory "/opt/spads/var/spring/data/games" has been created to store the games used by the autohost.
You can download one of the following games in this directory automatically by entering the corresponding game abreviation, or you can choose to manually place some games archives there then enter "none" when finished:
  ba : Balanced Annihilation V9.46
  bac : BA Chicken Defense V3.23
  evo : Evolution RTS v10.97
  jauria : Jauria RTS 0.6.7
  metalfactions : Metal Factions v0.991
  nota : NOTA 1.92
  phoenix : Phoenix Annihilation V1.01
  s44 : Spring: 1944 3.00
  swiw : Imperial Winter b63
  tard : Robot Defense v3.05.7
  tc : The Cursed 1.437
  techa : Tech Annihilation v3.05.0
  xta : XTA 9.752

8/15 - Which game do you want to download to initialize the autohost "games" directory (ba,bac,evo,jauria,metalfactions,nota,phoenix,s44,swiw,tard,tc,techa,xta,none) [ba] ? 
20171229022959 - NOTICE   - [SpadsInstaller] Downloading Balanced Annihilation V9.46...
20171229023002 - NOTICE   - [SpadsInstaller] File ba-V9.46.sdz downloaded.
20171229023002 - NOTICE   - [SpadsInstaller] Directory "/opt/spads/var/spring/data/maps" created

Directory "/opt/spads/var/spring/data/maps" has been created to store the maps used by the autohost.
You can download a minimal set of 3 maps ("Red Comet", "Comet Catcher Redux" and "Delta Siege Dry") in this directory automatically, or you can choose to manually place some maps archives there then enter "no" when finished.

9/15 - Do you want to download a minimal set of 3 maps to initialize the autohost "maps" directory (yes,no) [yes] ? 
20171229023002 - NOTICE   - [SpadsInstaller] Downloading maps...
20171229023005 - NOTICE   - [SpadsInstaller] Checking Perl Unitsync interface module...
20171229023005 - CRITICAL - [SpadsInstaller] Unable to load Perl Unitsync interface module (Can't locate Win32.pm in @INC (you may need to install the Win32 module) (@INC contains: /opt/spads /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.24.1 /usr/local/share/perl/5.24.1 /usr/lib/x86_64-linux-gnu/perl5/5.24 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.24 /usr/share/perl/5.24 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base) at /opt/spads/PerlUnitSync.pm line 26.
BEGIN failed--compilation aborted at /opt/spads/PerlUnitSync.pm line 26.
Compilation failed in require at (eval 22) line 2.
BEGIN failed--compilation aborted at (eval 22) line 2.
)
The command '/bin/sh -c perl /opt/spads/spadsInstaller.pl' returned a non-zero code: 1

Thanks

Yaribz commented 6 years ago

The PerlUnitSync.pm file on Git repository is only for Windows OS, you shouldn't download it on linux.

TurBoss commented 6 years ago

oh sorry I'll try again

thank you

Yaribz commented 6 years ago

Re-open if you still have problems

Yaribz commented 6 years ago

Oh btw, you don't need to download all these files to be able to launch the installer, you just need the files included in the installer package ( http://planetspads.free.fr/spads/installer/spadsInstaller.tar ), that is: SimpleLog.pm, spadsInstaller.pl and SpadsUpdater.pm