docker image error: standard_init_linux.go:211: exec user process caused “exec format error”
Summary
I run the command sudo docker run --detach \ --hostname xxx \ --publish 443:443 --publish 80:80 --publish 22:22 \ --name gitlab \ --restart always \ --volume /srv/gitlab/config:/etc/gitlab \ --volume /srv/gitlab/logs:/var/log/gitlab \ --volume /srv/gitlab/data:/var/opt/gitlab \ gitlab/gitlab-ce:latest
It turns docker image error: standard_init_linux.go:211: exec user process caused “exec format error”
Steps to reproduce
Run sudo docker run --detach \ --hostname xxx \ --publish 443:443 --publish 80:80 --publish 22:22 \ --name gitlab \ --restart always \ --volume /srv/gitlab/config:/etc/gitlab \ --volume /srv/gitlab/logs:/var/log/gitlab \ --volume /srv/gitlab/data:/var/opt/gitlab \ gitlab/gitlab-ce:latest
What is the current bug behavior?
Docker container cannot be created
What is the expected correct behavior?
Docker container can be created
Relevant logs
docker image error: standard_init_linux.go:211: exec user process caused “exec format error”
Details of package version
gitlab/gitlab-ce:lastest Image ID: 083c1c4f3b8e
Environment details
- Operating System:
ubuntu 16.4.6
Configuration details
I don't have my own sh files. Looks like adding #!/bin/bash
to the top of the sh file can fix this problem