ertagh / teamspeak3-server-arm

150 stars 11 forks source link

error while trying to run in kubernetes - docker exec format error #36

Closed Gordonfreeman882 closed 1 year ago

Gordonfreeman882 commented 1 year ago

Hey man,

thanks for the provided files. I'm trying to run your container in kubernetes on a PI cm4 which should be ARMv8.

I'm using your image with 'latest' tag since it supports ARMv8. When starting the following error appears in the logs of my pod:

Version 3.13.7 installed succesfully!
Starting TeamSpeak 3 Server ..
Starting TeamSpeak 3 Server ..
/teamspeak/ts3server_minimal_runscript.sh: 20: /teamspeak/ts3server_minimal_runscript.sh: ./ts3server: Exec format error
[cont-finish.d] executing container finish scripts...
[cont-finish.d] done.
[s6-finish] waiting for services.
[s6-finish] sending all processes the TERM signal.
[s6-finish] sending all processes the KILL signal and exiting.

I'm not quite sure where to look for the error since it looks like 'exec format error' can mean a missing #!/bin/bash or an image on unsupported architecture.

Any ideas?

Thanks!

ertagh commented 1 year ago

Well that's odd... I just tested it on my RPi 3b+ and there is no problem. May you provide what envs you set?

Also just wanna mention it: You may wanna switch to the latest-box tag. Better performance and it even runs the actual x64 binaries on ARMv8.

Gordonfreeman882 commented 1 year ago

Hey, i've set the following envs using latest-box image:

env:
            - name: TIME_ZONE
              value: Europe/Berlin
            - name: DIST_UPDATE
              value: "0"
            - name: TS_UPDATE
              value: "0"
            - name: TS_UPDATE_BACKUP
              value: "1"
            - name: UID
              value: "1000"
            - name: GID
              value: "1000"
            - name: INIFILE
              value: "0"
            - name: DEBUG
              value: "0"
            - name: TS_ARCHITECTURE
              value: x86_64
            - name: SYSTEM_ARCHITECTURE
              value: x86_64
            - name: TS3SERVER_LICENSE
              value: accept
            - name: LANG
              value: en_US.UTF-8
Gordonfreeman882 commented 1 year ago

To get things more sorted i've installed docker on the cm4 (debian 11.5). Then i've cloned your repo and build from dockerfile and run it successfully.

So it looks like it isn't a problem with armv8 or your image.

If you don't mind i will try to find out why it is not working in kubernetes and will post my ideas/solutions.

Greets

Gordonfreeman882 commented 1 year ago

So if somebody wants to run this image in kubernetes make sure to set workingDir: /teamspeak and

command: 
       - /init 

for ENTRYPOINT(Docker) in your yml file. Moreover i've deleted:

- name: SYSTEM_ARCHITECTURE
              value: x86_64

which is not needed and not valid.

I'm going to close issue with this comment. Thanks for helping me out!