maispace/environment

This extension provides environment depended helper functions for setting up TYPO3

Maintainers

Package info

github.com/mai-space-de/typo3-extension-environment

Type:typo3-cms-extension

pkg:composer/maispace/environment

Statistics

Installs: 0

Dependents: 0

Suggesters: 0

Stars: 0

Open Issues: 0

dev-main / 13.0.x-dev 2026-03-08 16:17 UTC

This package is auto-updated.

Last update: 2026-03-08 16:21:31 UTC


README

CI PHP TYPO3 License: GPL v2

This extension provides environment-dependent helper functions for setting up TYPO3. It allows you to easily manage different configurations for development, testing, and production environments, including support for DDEV.

Features

  • Environment-based configuration presets.
  • DDEV environment detection and automatic configuration.
  • Easy inclusion of context-dependent configuration files.
  • Helpers for common TYPO3 settings (database, caching, logging, etc.).

Installation

composer require maispace/environment

Usage

In your public/index.php (or wherever you initialize your environment), you can use the ConfigProvider:

use Maispace\Environment\ConfigProvider\ConfigProvider;

ConfigProvider::initialize();

Or with custom defaults:

ConfigProvider::initialize(false)
    ->useDevelopmentPreset()
    ->applyDefaults();

Available Methods

The ConfigProvider implements ConfigProviderTraitInterface, which provides many useful methods:

  • appendContextToSiteName(): Appends the application context (e.g., [Development]) to the site name.
  • useDDEVConfiguration(): Automatically configures database and other settings for DDEV.
  • useProductionPreset() / useDevelopmentPreset(): Applies common settings for production or development.
  • initializeDatabaseConnection(): Set up database connection.
  • initializeRedisCaching(): Set up Redis caching.
  • includeContextDependentConfigurationFiles(): Includes files from config/system/additional/<Context>.php.

License

GPL-2.0-or-later