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

bad interpreter: No such file or directory #79

Closed
rfvgyhn opened this issue Sep 22, 2020 · 7 comments
Closed

bad interpreter: No such file or directory #79

rfvgyhn opened this issue Sep 22, 2020 · 7 comments
Assignees
Labels

Comments

@rfvgyhn
Copy link

rfvgyhn commented Sep 22, 2020

In both the 1.3 and 1.2 docker images, I receive the following errors:

/entrypoint.sh: /init: /bin/execlineb: bad interpreter: No such file or directory
/entrypoint.sh: line 321: /init: No error information

Running 1.1 doesn't have the issue. Were there any config changes/additions/etc... that maybe I missed?

Full log:

>> Chdir to /app...
 ____  _                 _         __  __       _ _
/ ___|(_)_ __ ___  _ __ | | ___   |  \/  | __ _(_) |
\___ \| | '_ ` _ \| '_ \| |/ _ \  | |\/| |/ _` | | |
 ___) | | | | | | | |_) | |  __/  | |  | | (_| | | |
|____/|_|_| |_| |_| .__/|_|\___|  |_|  |_|\__,_|_|_|
                  |_|
  _____                                _
 |  ___|__  _ ____      ____ _ _ __ __| | ___ _ __
 | |_ / _ \| '__\ \ /\ / / _` | '__/ _` |/ _ \ '__|
 |  _| (_) | |   \ V  V / (_| | | | (_| |  __/ |
 |_|  \___/|_|    \_/\_/ \__,_|_|  \__,_|\___|_|


Source#2bacd4b Thu Oct 15 00:02:48 2020 +0800 * master
Built on Fri Sep 11 18:33:58 UTC 2020 by buildkitsandbox

>> END SMF_DOMAIN found. value:[*****.*****.***]
>> ENV SMF_CONFIG found. value:[@*****.***:*****@*****.***]
>> ARGV arguments found. value:[start]
>> SMF_CONFIG found in ENV. use this settings for forward maps.
>> Setting password[********] for user @*****.*** ...
postmap: warning: /etc/postfix/virtual.db: duplicate entry: "@*****.***"
>> Set hostname to *****.*****.***
>> Start self-testing...
1..17
ok 1 SMF_CONFIG exist
ok 2 SMF_DOMAIN exist
ok 3 virtual maping source is set
ok 4 virtual maping data is set
ok 5 virtual maping db is set
ok 6 system hostname FQDN resolvable
ok 7 postfix myhostname FQDN & resolvable
ok 8 check other hostname setting
ok 9 confirm postfix is running
ok 10 confirm port 25 is open
ok 11 crond is running # skip skip this for 0.3.0 -> 0.4.0
ok 12 ESMTP STATTLS supported
ok 13 ESMTP AUTH supported
ok 14 ESMTP STARTTLS connect ok
ok 15 create user [email protected] by password test
ok 16 ESMTP AUTH by [email protected]/test
ok 17 ESMTP TLS AUTH by [email protected]/test
>> Test PASSED


>> CONGRATULATIONS! System is UP and You are SET!
>> Powered by SMF - a Simple Mail Forwarder
>> View in DockerHub: https://hub.docker.com/r/zixia/simple-mail-forwarder


>> Init System for Servicing...
/entrypoint.sh: /init: /bin/execlineb: bad interpreter: No such file or directory
/entrypoint.sh: line 321: /init: No error information

docker-compose

version: '3'
services:

  mail:
    container_name: mail
    restart: always
    image: zixia/simple-mail-forwarder:latest
    ports:
      - "25:25"
    volumes:
      - /home/user/mail/certs:/etc/postfix/cert
      - /etc/timezone:/etc/timezone:ro
      - /etc/localtime:/etc/localtime:ro

    environment:
      SMF_CONFIG: "@*****.***:*****@*****.***"
      SMF_DOMAIN: *****.*****.***
      VIRTUAL_HOST: *****.*****.***
    networks:
      - proxy
    labels:
      - "traefik.enable=true"
      - "traefik.tcp.routers.mail.entrypoints=mail"
      - "traefik.tcp.routers.mail.service=mail"
      - "traefik.tcp.routers.mail.rule=HostSNI(`*****.*****.***`)"
      - "traefik.tcp.routers.mail.tls=true"
      - "traefik.tcp.routers.mail.tls.certresolver=le"
      - "traefik.tcp.services.mail.loadbalancer.server.port=25"
networks:
  proxy:
    external: true
@zaneclaes
Copy link

zaneclaes commented Sep 22, 2020

Likewise. My cluster pulled the v1.2 image automatically, which would not even start.

I didn't have monitoring on the service, so my company's emails were broken for 2 days before I noticed.

I tried to downgrade to 1.1, but this old version appears to not have authentication support. If you exec -it the container and cat the entrypoint.sh, there is no reference to SMF_RELAYAUTH. Has the working version of this tool disappeared from docker? It seems like latest got overwritten, and now there is no working image.

@zaneclaes
Copy link

I ended up checking out sha f50ed9693194ebe65d816825f1951921b792ec50 (from a few months ago), building it, and pushing to inzania/email:latest. This version supports SMF_RELAYAUTH and is working just like it used to be before the cluster update.

@mikafouenski
Copy link

Hello I got the same issue...

I tracked down this issue to the update of the S6 overlay by this 08daf27.

❯ dco -f simple-mail-forwarder.yml run --rm --entrypoint /bin/bash mail
bash-5.0# ls /init
/init
bash-5.0# vi /init
bash-5.0# ls /bin/execlineb
ls: cannot access '/bin/execlineb': No such file or directory
bash-5.0# find / -name "execlineb"
/usr/bin/execlineb
bash-5.0# 

Every S6 script use /bin/execlineb as shell bang.

We need to split the overlay extraction as described on their page https://github.com/just-containers/s6-overlay#bin-and-sbin-are-symlinks .

Here https://github.com/huan/docker-simple-mail-forwarder/blob/master/Dockerfile#L34-L36

Mika

@huan
Copy link
Owner

huan commented Sep 23, 2020

Hi all,

I'm terribly sorry for causing this problem with my mistake. I have sent a fix and hope this issue has been solved.

Please try the v1.2 that I have just re-published on the docker hub, which I have tested, and the /bin/execlineb should be OK now. (the tag with 1.3 was deleted)

Please feel free to let me know if there are still any problems. ( and PR is welcome )

Explanation

When I tried to build a multi-platform docker image with buildx (#76), I do not know how to select the s6-overlay with the right platform version in the Dockerfile with different platforms.

That's the time when I saw a nobin version in the s6-overlay release, which I thought it's platform-independent and I can just use it.

However, the nobin version is just the scripts without any binary, which will not be able to work, and that's the reason that makes this trouble for us.

See: The "nobin" variant is strictly the scripts of the s6-overlay, with absolutely no binaries.

@huan huan added the bug label Sep 23, 2020
@huan huan self-assigned this Sep 23, 2020
@rfvgyhn
Copy link
Author

rfvgyhn commented Sep 23, 2020

Looks like it's working now. Thanks for the quick-fix.

@rfvgyhn rfvgyhn closed this as completed Sep 23, 2020
@zaneclaes
Copy link

+1, back up and running. Thanks for all the hard work on this, @huan, it's great to have such a useful tool.

@huan
Copy link
Owner

huan commented Sep 26, 2020

Great to know that everything back to normal now, cheers!

haratosan pushed a commit to haratosan/docker-simple-mail-forwarder that referenced this issue Apr 5, 2021
huan added a commit that referenced this issue Jul 6, 2021
…103)

* Use alpine:latest as base image

* Roll back to sillelien/base-alpine:0.10 (#23)

* fix doc

* Update README.md

* Update README.md

* Update Base to Alpine 3.8

* Update base image to Alpine 3.8
* Install s6 process manager directly
* Upgraded BATS to 1.1.0
* Install syslog-ng for postfix logging to stdout

* syslog-ng: Disable statistic messages

These spam the console too much, so disable them.

* Fix typo in README

couse => course

* Upgrade circleci from v1 to v2

* add ide config

* fix circleci config

* fix circleci config

* fix circleci config

* fix circleci config

* fix yml

* fix yml add docker run type

* fix yml add machine run type

* fix yml

* year 2019

* Add voice from Paweł Czochański

* EC key support (#51)

* Fix nickname typo

* Add support for EC keys

* Update README.md

* Update README.md

* add ec key support

* Fix layout

* Timezone tzdata packagge (#57)

Add custom timezone support

* make circler yaml linter happy

* Fix leak of EC Cert/Key problem (#58)

* code clean

* only generate not existing files (#51 #58)

* one line -> one-line

* Timezone supported

* Update author & copyright

* Update master changelog

* fix chinese charactor bug

* v1.1

* Update README.md timezone (#59)

Update README.md for Timezone support

* clean doc

* Fix H1 title

* Update README.md

* Update README.md

* Fix typo (#66)

* add auth for relayhost (#68)

* add auth for relayhost

* indent fix

* example for AUTH

* remove excess line

* environment var typo fix

* fix for mail log not displaying

* Enable GitHub Actions

* Add Actions Badge

* basic "proofreading" (#69)

* basic "proofreading"

fixed some grammatical and spelling errors, made the descriptions flow a little better

* PR revisions

* Update README.md

* add hall of flame

* Upgrade BATS & S6, with multiple-platform docker image published with version 1.2 (#76)

* v1.2

* Upgrade Alpine to 3.8 (#77)

* upgrade base image to alpine 3.8

* v1.3

* Deploy docker image arm platform from github action

* test

* test

* checkout before deploy

* clean

* use buildx as default bugild

* republish v1.2 for amd64 with s6 fix (#79)

* republish v1.3 for amd64 with s6 fix

* fix comment

* v1.2

* Add test for deleting test user (#82)

* Add makefile

* makefile

* makefile

* makefile

* 1.2.14

* add make version

* 1.2.15

* v1.3.0 for multi platforms image

* Use script to install s6 with right platforms (arm/x86) (#76)

* use aarch64 for s6 release (#76)

* v1.3.1

* Add DKIM support (#83)

* Add DKIM support

* 1.2.11

Co-authored-by: Huan (李卓桓) <[email protected]>

* generating a DKIM key for all virtualDomains

* including HOSTNAME in folder of domains for DKIM

* KeyTable, SigningTable, TrustedHosts for HOSTNAME and all virtualDomain

* Generate new DKIM data only if keys do not exist yet

* disabled opendkim.conf settings for single domain, added KeyTable,SigningTable,ExternalIgnoreList,InternalHosts

* Correct permissions of DKIM files regardless of prior creation

* Added test for multiple domains and DKIM. Ready for #88

* Updated README on DKIM for multiple domains

* Fixed indentation on entrypoint

* Fixed wrong indentation (style)

* Cleaner handling of multiple DKIM keys. No settings required. Renders #83 redundant

* Making sure we never insert the same config twice #89

* Forgot one last mention of SMF_DKIM_ALL

* Better tld naming for DKIM in README

Co-authored-by: Peeter N <[email protected]>

* DKIM test no longer changes working directory

Co-authored-by: Peeter N <[email protected]>

* More elegant generation of DKIM entries for HOSTNAME and virtual domains

* Correct switch to suppress grep complains when files miss

* Update VERSION

* Strips sender details (IP, client, user agent) when sending (#91)

* Strips sender's IP, client, and user agent headers

* Bumping patch verison number

* Allow for setting any Postfix variables in the config file (both main.cf and master.cf) (#93)

* Strips sender's IP, client, and user agent headers

* Bumping patch verison number

* SMF_POSTFIXMAIN_* to set custom postfix main.cf entries

* SMF_POSTFIXMASTER_* to set custom postfix master.cf entries

* Using sed to handle master.cf custom variables

* README.md explains env variables for custom main.cf and master.cf

* Tests for custom main.cf and master.cf

* Fixes #92

* Simplify docker run command with SMF_CONFIG

* v1.4.3 (#94)

* Add VERSION & Update README.md (#94)

* fix ignore

* 1.4.4

* add v1.4 changelog

* clean

* show version

* 1.4.5

* layout

* Update configuration after variables has been injected to the main configuration (#98)

* Add an option to override postfix's default logging configuration

* Add tests

* Update README.md

* push to build

* fix overwriting variable

* update with postfix-configuration

* delete drone for pull request

Co-authored-by: Tamaro Skaljic <[email protected]>

* Add an option to override postfix's default logging configuration (#97)

* Add an option to override postfix's default logging configuration

* Add tests

* Update README.md

* v1.4.6

* Change Postfix logging configuration tests behaviour (#99)

* fix default postfix logging configuration test

* Change logfile path in custom postfix logging configuration test

* Make postfix logging configuration tests restore the preconditions

* start PostSRSd and generate Secret

* start PostSRSd and generate Secret

* start PostSRSd if  is set

* start PostSRSd if  is set

* only start PostSRSd if  is set

* only start PostSRSd if  is set

* Updated README.md

* Updated README.md

* spelling...

* spelling...

* Updated the if-statement for PostSRSd

* Updated the if-statement for PostSRSd

Co-authored-by: Martijn Rondeel <[email protected]>
Co-authored-by: Huan LI <[email protected]>
Co-authored-by: Chris Blake <[email protected]>
Co-authored-by: universeroc <[email protected]>
Co-authored-by: Paweł Czochański <[email protected]>
Co-authored-by: me1299 <[email protected]>
Co-authored-by: David Gonzalez <[email protected]>
Co-authored-by: Choon-Siang Lai <[email protected]>
Co-authored-by: Bailey <[email protected]>
Co-authored-by: Peeter N <[email protected]>
Co-authored-by: Daniel Graziotin <[email protected]>
Co-authored-by: Daniel Graziotin <[email protected]>
Co-authored-by: Cenk Kılıç <[email protected]>
Co-authored-by: Tamaro Skaljic <[email protected]>
Co-authored-by: Linux User <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants