Question

I am happily using fabric for my Python projects for deployment. Now I am engaged in a larger PHP project and wondering if there is something like fabric for PHP?

Was it helpful?

Solution

Hmm? Why does it matter? Fabric is just python scripting. So it's project language agnostic. You can use it put anything on a server you'd use scp for, as well as script anything via ssh you'd use bash or [insert other tool here] for. Fabric really isn't Python's capistrano. It's more akin to a combining of both cap and rake, though I still think that's pigeonholing fabric's ability.

I do like the one stop recipe bits that cap and (from first look) weploy gives you for projects, as in fabric unless you're leveraging something like woven, you'll be rolling your own. But the customization ability of fabric is a plus to me, as I'm all over the place in my uses for it.

OTHER TIPS

Rasmus Lerdorf have released kind of Capistrano for PHP : WePloy.

Maybe it will fits your needs

Laravel (a very popular and relatively young framework) has Envoy.

Now we have Deployer for PHP, implemented in php, no special ext required, installation is downloading a deployer.phar, have deploy templates for popular frameworks. https://deployer.org/

If you're looking for a build tool (as opposed to deployment), you can use Phing (http://phing.info/), a PHP equivalent of Java's Ant.

Doesn't handle the tunnelling (running remote commands etc.) but does do a nice job of breaking up your deployment into tasks with chained dependancies, and being PHP can interact with your PHP libraries easilly. You might find that some simple cap or fabfiles for the actual deployment, and could then call a Phing script to handle the post-deployment configuration.

Yes, you can use mysqlnd_ms

The mysqlnd replication and load balancing plugin (mysqlnd_ms) adds easy to use MySQL replication support to all PHP MySQL extensions that use mysqlnd.

As of version PHP 5.3.3 the MySQL native driver for PHP (mysqlnd) features an internal plugin C API. C plugins, such as the replication and load balancing plugin, can extend the functionality of mysqlnd.

The MySQL native driver for PHP is a C library that ships together with PHP as of PHP 5.3.0. It serves as a drop-in replacement for the MySQL Client Library (libmysqlclient). Using mysqlnd has several advantages: no extra downloads are required because it's bundled with PHP, it's under the PHP license, there is lower memory consumption in certain cases, and it contains new functionality such as asynchronous queries.

Mysqlnd plugins like mysqlnd_ms operate, for the most part, transparently from a user perspective. The replication and load balancing plugin supports all PHP applications, and all MySQL PHP extensions. It does not change existing APIs. Therefore, it can easily be used with existing PHP applications.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top