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

Static binary : wrong PHP version #761

Open
mvuidev opened this issue May 3, 2024 · 2 comments
Open

Static binary : wrong PHP version #761

mvuidev opened this issue May 3, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@mvuidev
Copy link

mvuidev commented May 3, 2024

What happened?

I try to create a custom static binary with PHP 8.2 and imagick extension :

sudo docker buildx bake --load --set "*.platform=linux/amd64" --set static-builder.args.PHP_VERSION=8.2 --set static-builder.args.PHP_EXTENSIONS=imagick --set static-builder.args.PHP_EXTENSIONS_LIBS="" --set static-builder.args.CLEAN=1 static-builder

sudo docker cp $(sudo docker create --name static-builder dunglas/frankenphp:static-builder):/go/src/app/dist/frankenphp-linux-$(uname -m) frankenphp ; sudo docker rm static-builder

Binary is well created, but it's still in version 8.3 of PHP :

./frankenphp version

FrankenPHP v1.1.4 PHP 8.3.6 Caddy v2.7.6

Also checked with phpinfo() and same result (and imagick is not installed).

What am I doing wrong ?

Build Type

Custom (tell us more in the description)

Worker Mode

No

Operating System

GNU/Linux

CPU Architecture

x86_64

PHP configuration

--

Relevant log output

No response

@mvuidev mvuidev added the bug Something isn't working label May 3, 2024
@dunglas
Copy link
Owner

dunglas commented May 13, 2024

Could you try with the Docker cache disabled (add --no-cache)?

@mvuidev
Copy link
Author

mvuidev commented May 13, 2024

@dunglas Hi,

Just tried with --no-cache on docker buildx bake :

sudo docker buildx bake --load --set "*.platform=linux/amd64" --set static-builder.args.PHP_VERSION=8.2 --set static-builder.args.PHP_EXTENSIONS=imagick --set static-builder.args.PHP_EXTENSIONS_LIBS="" --set static-builder.args.CLEAN=1 --no-cache static-builder

sudo docker cp $(sudo docker create --name static-builder dunglas/frankenphp:static-builder):/go/src/app/dist/frankenphp-linux-$(uname -m) frankenphp ; sudo docker rm static-builder

But the problem persists :/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants