Directories and files
Coduva uses two root directories:
- Component directory
C:\Coduva: servers, generated configuration, data, logs and the default location of projects. It was chosen as a path that uses only ASCII characters and does not depend on the user name. - Application data
%APPDATA%\Coduva: application settings and health reports.
Both directories can be opened from Settings → Storage and from the Folders submenu in the tray's right-click menu.
Component directory
| Path | Contents |
|---|---|
C:\Coduva\bin | Components: nginx\<version>, php\<version>, mariadb\<version>, node\<version>, composer, wp-cli, shims |
C:\Coduva\apps\phpmyadmin | phpMyAdmin (http://localhost/phpmyadmin/) |
C:\Coduva\etc | Generated configuration: nginx, php, mariadb, ssl, localhost.json |
C:\Coduva\www | Default site (www\localhost, welcome page) and the default location for new projects |
C:\Coduva\data | Caches for MariaDB data (data\mariadb), Composer (data\composer) and WP-CLI (data\wp-cli\cache) |
C:\Coduva\logs | Service and project logs |
C:\Coduva\backups\db | Database dumps (<name>-<time>.sql) |
C:\Coduva\downloads | Downloaded component packages and WordPress zips |
C:\Coduva\tmp | PHP temporary files, sessions (tmp\sessions), OPcache file cache, phpMyAdmin temporary files |
Projects can be in any folder you choose; if Location is left empty when creating a new project, C:\Coduva\www\<name> is used.
Generated configuration
| File | Contents |
|---|---|
C:\Coduva\etc\nginx\conf\nginx.conf | Main configuration: PHP pools (upstream), default site, phpMyAdmin |
C:\Coduva\etc\nginx\conf\sites\<name>.conf | Virtual server for each project; a second server block if HTTPS is enabled |
C:\Coduva\etc\php\<version>\php.ini | Settings and extensions for each PHP version |
C:\Coduva\etc\mariadb\my.ini | MariaDB settings ([mysqld], [client]) |
C:\Coduva\etc\ssl\ca\ | Local certificate authority: coduva-ca.crt, coduva-ca.key |
C:\Coduva\etc\ssl\sites\ | Project certificates: <name>.test.crt, <name>.test.key |
C:\Coduva\apps\phpmyadmin\config.inc.php | phpMyAdmin connection settings |
C:\Coduva\etc\localhost.json | Ports and project list read by the welcome page |
When are they rewritten?
Web server configuration (nginx.conf, sites\*.conf, php.ini, phpMyAdmin settings and localhost.json) is regenerated from the templates when:
- Nginx starts or restarts,
- a project is added or removed, or the project's PHP version, HTTPS setting or web root changes,
- PHP settings or extensions are saved on the PHP and Node screen, or the default PHP version changes,
- on the first launch after Coduva is updated (template sync).
If Nginx is running, the new configuration is reloaded without interruption; you do not need to restart the services. my.ini is rewritten each time MariaDB starts.
Manual edits
Changes you make to these files by hand are not kept. The note at the top of each file says so: "Generated by Coduva. Manual changes will be overwritten on the next start." Change PHP settings on the PHP and Node screen, and change ports under Settings → Network.
Writes are atomic: the content is first written to a .tmp file, the existing file is kept as .bak, and then the two are swapped. A file whose content has not changed is not rewritten, so the .bak file always holds the previous different version. If a manual change has been lost, check the .bak file in the same folder.
sites\*.conf files for projects that are not registered are deleted automatically.
Template sync
Coduva keeps running in the background after its window is closed, so services can stay open for days. When Coduva is updated to a new version or the configuration templates change, it rewrites the configuration from the new templates at startup and reloads the running Nginx without interruption. The new version's settings therefore take effect without restarting services. If this fails, the Recent events log records "The new version's configuration could not be applied"; restarting Nginx applies the new configuration.
Welcome page
C:\Coduva\www\localhost\index.php is the welcome page that opens at http://localhost/ (for its contents, see Project types → Default site). Unlike the other configuration files, this page belongs to you:
- If the file does not exist, Coduva creates it; if you delete it, it is recreated on the next start.
- Coduva replaces the page with the new version only if it is exactly identical to one of Coduva's earlier versions and has never been modified.
- A page you have edited is not overwritten, and no
.bakis left next to it.
The page reads the project list and ports from C:\Coduva\etc\localhost.json, which is outside the document root. Nginx passes the path of this file to the page through the CODUVA_INFO FastCGI parameter.
Key values
nginx.conf:
client_max_body_size 128m;
sendfile off; # Prevents stale content from being served when editors modify files in place
fastcgi_read_timeout 300;my.ini:
[mysqld]
port=3306
bind-address=127.0.0.1
character-set-server=utf8mb4
collation-server=utf8mb4_unicode_ci
innodb_buffer_pool_size=256M
max_allowed_packet=256M
skip-name-resolveFor the default values in php.ini, see Screens → PHP and Node.
Logs
| File | Contents |
|---|---|
C:\Coduva\logs\nginx-error.log | Nginx errors |
C:\Coduva\logs\nginx-access.log | Default site access log |
C:\Coduva\logs\php-<version>-error.log | Error log for a PHP version |
C:\Coduva\logs\mariadb-error.log | MariaDB errors |
C:\Coduva\logs\sites\<name>-error.log | Nginx error log for the project |
C:\Coduva\logs\sites\<name>-access.log | Access log for the project |
C:\Coduva\logs\projects\<name>\<process>.log | Project processes: queue, schedule, vite |
Application logs are in the project's own folder: wp-content\debug.log for WordPress, and storage\logs\laravel.log for Laravel.
Application data
| Path | Contents |
|---|---|
%APPDATA%\Coduva\coduva.sqlite | Settings database |
%APPDATA%\Coduva\reports\ | Health reports (saglik-raporu-<time>.md) |
%APPDATA%\Coduva\editor-bridge.json | State file for CodVS (projects and services). Coduva writes it and CodVS reads it; it is refreshed only when its content changes |
The tables in the settings database are: settings, php_versions, services, projects, databases, backups, events. Passwords are not written to this database; secrets in the event log are masked.
Terminal environment
The Coduva terminal and terminals opened from projects start with this environment:
| Variable | Value |
|---|---|
PATH | First C:\Coduva\bin\shims (composer, wp), then the project's PHP folder, then the Node folder, then the system PATH value |
PHPRC | The C:\Coduva\etc\php\<version> folder for the project's PHP version; the command-line PHP uses the same php.ini file |
COMPOSER_HOME | C:\Coduva\data\composer |
WP_CLI_CACHE_DIR | C:\Coduva\data\wp-cli\cache |
As a result, the php, composer, wp, node and npm commands in the terminal run with the versions selected for the project.
Changing paths with environment variables
For development and testing, the default paths can be changed with environment variables:
| Variable | Effect |
|---|---|
CODUVA_HOME | Component directory (instead of C:\Coduva) |
CODUVA_DATA | Application data (instead of %APPDATA%\Coduva) |
CODUVA_HOSTS_FILE | Testing only: this file is used instead of the real hosts file, and no administrator permission is requested |
$env:CODUVA_HOME = "D:\coduva-dev"
$env:CODUVA_DATA = "D:\coduva-dev\appdata"Tip
Also choose an ASCII path for CODUVA_HOME. If the component directory contains non-ASCII characters, the Control center and Diagnostics show a warning.