GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — platforms/php at master · tsuru/platforms

Expand file tree

/

php

/
Copy path

Directory actions

More options

More options

Directory actions

More options

More options

Latest commit

 

History

History
History
/

php

/
Copy path

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
frontend
frontend
 
 
interpretor/fpm
interpretor/fpm
 
 
Dockerfile
Dockerfile
 
 
README.md
README.md
 
 
__init__.py
__init__.py
 
 
deploy
deploy
 
 
deploy.py
deploy.py
 
 
frontend.py
frontend.py
 
 
install
install
 
 
interpretor.py
interpretor.py
 
 
utils.py
utils.py
 
 
vars.py
vars.py
 
 

README.md

Outline

PHP platform

The PHP platform is built to be able to manage multiple front-end and interpretors. You can manage them in your tsuru.yml configuration file.

php:
    version: 5.6
    frontend:
        name: nginx
    interpretor:
        name: fpm
    composer: true

Versions

Currently, php supported versions are:

  • 5.6
  • 7.0
  • 7.1
  • 7.2
  • 8.0
  • 8.1
  • 8.2
  • 8.3

Front ends

The following frontends are currently supported:

  • apache: Apache
  • nginx: Nginx

You can chose between them by setting the php.frontend.name parameter:

php:
    frontend:
        name: apache

Each frontend supports options that can be set in the php.frontend.options parameters.

All these options are not required, and can be used the following way:

php:
    frontend:
        name: apache
        options:
            vhost_file: /path/to/vhost.conf
            modules:
                - rewrite

Apache options

  • vhost_file: The relative path of your Apache virtual host configuration file
  • modules: An array of module names, such as rewrite for instance

Nginx options

  • vhost_file: The relative path of your Nginx virtual host configuration file

Interpretors

The following PHP interpretors are supported:

  • fpm: PHP-FPM

You can chose between them by setting the php.interpretor.name parameter:

php:
    interpretor:
        name: fpm

These interpretors can also have options configured in the php.interpretor.options parameter.

If you choose fpm interpretor, use extensions option to install php extensions instead of using requirements.apt

All these options are not required and can be used the following ways

php:
    interpretor:
        name: fpm54
        options:
            ini_file: /path/to/file.ini
            extensions:
                - php-mysql

fpm options

  • ini_file: The relative path of your php.ini file in your project, that will replace the default one
  • extensions: A list of php extensions you need

General options

In addition to the frontend and interpretor options, there's an other one:

  • composer: A boolean that is by default to true. If the value is true, it'll run a composer install if there's a composer.json file at the root of your application.

Backward compatibility

To keep the backward compatibility, there's also a apache-mod-php frontend that is in fact the Apache with modphp enabled, that remove the need of an interpretor. That's currently the default configuration if no parameter is set along php version 5.6.

Next steps

With the current implementation, it's quite easy to add another interpretor for instance.

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.