Introducing the New Zend Puppet PHP Modules
Tags: puppet, zend, php
Published: 2023-03-31 19:15:16

---
title: Introducing the New Zend Puppet PHP Modules
published: true
date: 2023-03-30 00:00:00 UTC
tags: puppet, zend, php
canonical_url: https://www.zend.com/blog/puppet-php-module
---

Working with ZendPHP and Puppet just got a lot easier. With the introduction of two new modules for ZendPHP and ZendHQ — and the ability to manage ZendPHP using the puppet/php module —  teams now have a faster way to work with fully-supported EOL PHP runtimes from Zend.

In this article, we give an overview of the new Zend PHP Puppet modules, how they work, and how to get started.

## Introducing the New Zend PHP Puppet Modules

Have you ever wanted to integrate Zend’s PHP LTS runtimes with your Puppet pipeline only to find you’d need to roll your own manifests to do so? If so, we have new modules that can help.

Zend has now released open source puppet modules for our enterprise tools, like ZendHQ, as well as integrated with the community Puppet PHP module to allow for simple module settings that tell the module to use Zend’s PHP LTS instead of community PHP.

Zend currently has two official modules on [Puppet Forge](https://forge.puppet.com/), with others planned as more features and products related to ZendPHP are released. 

The two new Zend PHP Puppet modules are:

- [zend/zend_common](https://forge.puppet.com/modules/zend/zend_common/)
- [zend/zendhq](https://forge.puppet.com/modules/zend/zendhq)

### zend/zend_common

The zend_common module is used by other Puppet modules, like zend/zendhq, to reliably set up and configure the Zend package repositories — as well as any required license files. This module, zend_common, is a dependency that can be disregarded when using product modules, but it can also be used as standalone in a more tailored and customized Puppet pipeline to simply ensure the Zend repositories and license are maintained by Puppet. See its [usage documentation](https://forge.puppet.com/modules/zend/zend_common/readme#usage) for more details.

### zend/zendhq

Users can now easily install ZendHQ and manage its configuration by using Zend’s zend/zendhq Puppet module, currently available on Puppet Forge. The ZendHQ puppet module allows users to define the license source and configuration settings, like the daemon URI, they would like ZendHQ to have. From there, the module uses zend/zend_common to ensure the Zend package repositories and license are setup and ensures that ZendHQ is installed and configured as intended. See its [usage documentation](https://forge.puppet.com/modules/zend/zendhq/readme#usage) for more details.

## Using ZendPHP With puppet/php

The maintainers of puppet/php, Vox Pupuli, recently accepted a [pull request](https://github.com/voxpupuli/puppet-php/pull/671) that adds support for managing ZendPHP using the puppet/php module. This enhancement currently exists on the main branch of the repository, and it should make it into the next release. 

For now, users can tell Puppet to use the main branch for dependency instead of a version number by pointing it to the repository branch in their Puppetfile, like so:

```
mod 'puppet-php',
    :git => 'https://github.com/voxpupuli/puppet-php'
```

The pull request for ZendPHP support added two parameters to puppet/php: $flavor and $zend_creds. The flavor can either be community or zend, allowing users to choose whether to use community PHP or ZendPHP, respectively. If their flavor is zend and they define a version number that’s in LTS (i.e. 7.4), then zend_creds will be required, which are the credentials provided when you purchase a license. These credentials are necessary for accessing LTS versions in our Zend package repositories. See its [usage documentation in puppet/php’s README](https://github.com/voxpupuli/puppet-php#zendphp-support) for more details.

## Final Thoughts

Puppet and community PHP have worked well together historically thanks to the efforts of maintainers at [Vox Pupuli](https://voxpupuli.org/). But, with more and more teams deploying EOL PHP versions, having [ZendPHP](https://www.zend.com/products/zendphp-enterprise) (which includes [PHP LTS](https://www.zend.com/services/php-long-term-support)) as an option that incorporates easily into their Puppet workflows can be a big help.

If you haven't had a chance yet, we highly encourage you to [try ZendPHP](https://www.zend.com/products/zendphp-enterprise/trial), and to check out our container registry at [cr.zend.com](https://cr.zend.com/). If you have any questions on how to get started, or what we offer, be sure to [contact us](https://www.zend.com/contact-us).