HOME » Documents » KUSANAGI 9 Commands » container on

container on

container on

*This command is only available for the KUSANAGI 9 Business Edition.

Enables the PHP container of the specified profile. Available only for nginx and MariaDB.

PHP container is a feature that allows a profile to run a different version of PHP than the one in the KUSANAGI Virtual Machine (the host PHP).
This allows you to test a newer version of PHP only in specific profiles while keeping the host PHP at the older version, or conversely, to update the host PHP to a newer version, while keeping specific profiles at the older PHP version.

Before using PHP container, keep in mind the following notes.

  • PHP running in a PHP container is an image of KUSANAGI Runs on Docker. Each version requires approximately 2GB of disk space.
  • PHP container can not be restarted using the "kusanagi php" command. Please run the "kusanagi container restart" command individually or use the "kusanagi restart" command.
  • If you are using WordPress, change the FTP_HOST value in "wp-config.php" from "localhost" to the "IP address" of your virtual machine.

Example

kusanagi container on --use php80 kusanagi_html

Options

PHP Container Version (Required)

--use {php82 | php81 | php80 | php74}

Specify the PHP container version to be used. When one of the following PHP container versions has been specified, it will be the one used.

  • --use php82 : PHP 8.2
  • --use php81 : PHP 8.1
  • --use php80 : PHP 8.0
  • --use php74 : PHP 7.4

The "--use" option is mandatory.

Profile Name

[profile]

Default: The current directory profile

If "profile" is specified, the "container" of the specified profile will be processed.
However, if the current directory is not a profile, an error will occur.

Output

# kusanagi container on --use php80 kusanagi_html
container completed.