-
Notifications
You must be signed in to change notification settings - Fork 2k
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
mail function works incorrectly in PHP8 alpine builds #1327
Comments
I'm guessing it's busybox-specific, have you tried the non-alpine version? |
Yeah, that seems pretty busybox-specific (and I can't imagine https://pkgs.alpinelinux.org/contents?file=sendmail&branch=v3.16&arch=x86_64 includes a few alternative options you should probably consider installing in your image. 👀 For further help, I would suggest a dedicated support forum, such as the Docker Community Forums, the Docker Community Slack, or Stack Overflow. |
@wglambert @tianon I suppose you as the maintainers should be aware of the issue because one of the basic PHP features is non-functional in Alpine images. This is not a bug of PHP, this may be a bug of Busybox, but why users of the image should apply workarounds and not maintainers? Of course, I will do something because I need it, but I think the way when core PHP functionality doesn't work because maintainers don't care is not the best way. |
How can I do that? |
I just tried ssmtp but the result is the same. Here is the beginning of an email:
All mail data sent from PHP has extra line breaks. Can it be that something is wrong on the OS level, not on the application level? |
I'm using latest PHP 8.1 alpine image with the following sendmail version:
The mail function sends headers and body with \r\n line delimiters according to standards and passes this data to sendmail. But sendmail converts all line-endings to \r\r\n making the whole mail broken.
A related issue in the PHP repo: php/php-src#8086 (closed as PHP does everything correctly).
The text was updated successfully, but these errors were encountered: