PHPackages                             rixxi/env - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. rixxi/env

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

rixxi/env
=========

1.1.0(11y ago)61151BSD-3-ClausePHPPHP &gt;=5.3.1

Since Jul 20Pushed 11y ago2 watchersCompare

[ Source](https://github.com/rixxi/env)[ Packagist](https://packagist.org/packages/rixxi/env)[ RSS](/packages/rixxi-env/feed)WikiDiscussions master Synced 3w ago

READMEChangelogDependencies (2)Versions (3)Used By (0)

ENV variables in Nette DI configuration (`nette`, `php` and `parameters` sections excluded).

Install
=======

[](#install)

`composer require rixxi/env:~1.0` or `@dev` if you are mad.

Put extension at least before other extensions that use ENV variables in configuration.

Configure
=========

[](#configure)

By default only defined parameters are registered. If you want all environment variables be available then turn `whitelist: off`..

Example of kdyby/doctrine configuration
---------------------------------------

[](#example-of-kdybydoctrine-configuration)

```
env:
	parameters:
		DB_HOST: 127.0.0.1
		DB_NAME:
		DB_DRIVER: pgsql
		DB_USERNAME:
		DB_PASSWORD:

doctrine:
	host: %env.DB_HOST%
	dbname: %env.DB_NAME%
	driver: pdo_%env.DB_DRIVER%
	username: %env.DB_USERNAME%
	password: %env.DB_PASSWORD%
	// ... other stuff

extensions:
	env: Rixxi\Env\DI\EnvExtension
```

When running application at least DB\_NAME ENV must be set. You can do that directly via shell

```
DB_NAME=test php www/index.php
```

or in config of apache or fpm pool.

Limitations
===========

[](#limitations)

- Only other 3rd party extension configuration is supported that means no variables in `nette` or `php`.
- Sections `parameters` and `services` are not supported. It is not possible at this time due to limitations of [nette/di](https://github.com/nette/di).
- Only **string names** and **scalar and null** values are supported. This one is on purpose.

###  Health Score

29

—

LowBetter than 57% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity16

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity59

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~11 days

Total

2

Last Release

4356d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/276500?v=4)[Michal Gebauer](/maintainers/mishak87)[@mishak87](https://github.com/mishak87)

---

Top Contributors

[![mishak87](https://avatars.githubusercontent.com/u/276500?v=4)](https://github.com/mishak87 "mishak87 (5 commits)")

### Embed Badge

![Health badge](/badges/rixxi-env/health.svg)

```
[![Health](https://phpackages.com/badges/rixxi-env/health.svg)](https://phpackages.com/packages/rixxi-env)
```

###  Alternatives

[nette/bootstrap

🅱 Nette Bootstrap: the simple way to configure and bootstrap your Nette application.

68637.6M653](/packages/nette-bootstrap)[nette/component-model

⚛ Nette Component Model

28817.0M105](/packages/nette-component-model)[symplify/monorepo-builder

Not only Composer tools to build a Monorepo.

5275.9M121](/packages/symplify-monorepo-builder)[brandembassy/slim-nette-extension

19201.2k](/packages/brandembassy-slim-nette-extension)[shipmonk/input-mapper

Performant array-to-object mapper supporting generics, array shapes, optional fields and much more!

3030.9k](/packages/shipmonk-input-mapper)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
