Adding mssql support in php 5.3

I have an old project that I need to setup locally that runs on php 5.3 and uses the mssql extension to talk to SQL Server.

Can someone point me in the right direction to get the mssql extension installed in the php 5.3 container?

I am currently also out of luck.

If someone provides a snippet for Debian based systems to get this installed for PHP 5.3 I can ship it by default inside the 5.3 Docker image.

@cytopia is there a way to reload php-fpm without restarting devilbox?

I’ve just made all my changes directly inside the php container for now and have the module built and ready to test. I added a file at /usr/local/etc/php/conf.d/docker-php-ext-mssql.ini following the structure of the other extensions, but can’t figure out how to make it reload the php.ini (without restarting the whole stack and losing my changes).

PHP is managed by supervisord which will take care of restarting it in case it’s killed. So you can safely kill the process:

docker-compose exec php bash
kill $(pidof php-fpm)

Alternatively what I would suggest is instead making those changes directly in the container, you could use the autostart feature and add your commands in there:

This allows you to define whatever steps you had done manually upfront and it will apply every time you start the Devilbox with docker-compose up.

Ok thanks - phpinfo() is now showing the mssql extension as installed.

I am developing on a Mac. I have a Windows machine running SQL Server. It has an IP address on my network of (and SQL Server is being server over port 1433).

If I run nc -z 1433 from my local machine I get:
Connection to port 1433 [tcp/ms-sql-s] succeeded!

But if I run ping from inside the php container I get an error:
ping: unknown host

So I can’t seem to connect to the SQL Server machine from inside the docker container… any tips on how to get that to work?

The ping command does not support/require a port. Try: ping (without the port :1433)