Skip to content

Commit a601c2c

Browse files
totoprayogo1916paulbalandanmichalsnddevsr
committed
fix: improve wording for .env file location recommendation
Co-authored-by: John Paul E. Balandan, CPA <[email protected]> Co-authored-by: Michal Sniatala <[email protected]> Co-authored-by: ddevsr <[email protected]>
1 parent cedc568 commit a601c2c

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed

app/Config/Paths.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,8 +81,10 @@ class Paths
8181
* ENVIRONMENT DIRECTORY NAME
8282
* ---------------------------------------------------------------
8383
*
84-
* This variable must contain the name of the directory for
85-
* environment files.
84+
* This variable must contain the name of the directory where
85+
* the .env file is located.
86+
* Please consider security implications when changing this
87+
* value - the directory should not be publicly accessible.
8688
*/
8789
public string $envDirectory = __DIR__ . '/../../';
8890
}

user_guide_src/source/general/managing_apps.rst

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -110,10 +110,9 @@ pointed to the ``public/`` directory, as recommended.
110110

111111
In practice, however, some applications are served from a subdirectory (e.g., ``http://example.com/myapp``)
112112
rather than from the main domain. In such cases, placing the ``.env`` file within the ``ROOTPATH`` may expose
113-
sensitive configuration if ``.htaccess`` or other protections are misconfigured.
113+
sensitive configuration data if ``.htaccess`` or other protections are misconfigured.
114114

115-
To avoid this risk in such setups, it is recommended to ensure the ``.env`` file is located outside any
116-
web-accessible directories.
115+
To avoid this risk in such setups, it is recommended that you ensure the ``.env`` file is located outside any web-accessible directories.
117116

118117
.. warning::
119118

0 commit comments

Comments
 (0)