-
Notifications
You must be signed in to change notification settings - Fork 25
/
wp-config.php
71 lines (60 loc) · 1.84 KB
/
wp-config.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
<?php
/**
* Include composer autoload for 3d-party libraries
*/
require( __DIR__ . '/vendor/autoload.php' );
$root_dir = dirname( __FILE__ );
require $root_dir . '/environments/dotenv.php';
/**
* Use Dotenv to set required environment variables and load .env file in root
*/
$dotenv = dotenv( $root_dir );
$dotenv->load();
$dotenv->required( [ 'DB_NAME', 'DB_USER', 'DB_PASSWORD', 'WP_HOME', 'WP_SITEURL' ] );
/**
* Set up our global environment constant and load its config first
* Default: production
*/
define( 'WP_ENV', env( 'WP_ENV', 'production' ) );
require_once $root_dir . '/environments/' . WP_ENV . '.php';
/**
* URLs
*/
define( 'WP_HOME', env( 'WP_HOME' ) );
define( 'WP_SITEURL', env( 'WP_SITEURL' ) );
/**
* Custom Content Directory
*/
define( 'CONTENT_DIR', '/wp-content' );
define( 'WP_CONTENT_DIR', $root_dir . CONTENT_DIR );
define( 'WP_CONTENT_URL', WP_HOME . CONTENT_DIR );
/**
* DB settings
*/
define( 'DB_NAME', env( 'DB_NAME' ) );
define( 'DB_USER', env( 'DB_USER' ) );
define( 'DB_PASSWORD', env( 'DB_PASSWORD' ) );
define( 'DB_HOST', env( 'DB_HOST', '127.0.0.1' ) );
define( 'DB_CHARSET', 'utf8' );
define( 'DB_COLLATE', '' );
$table_prefix = env( 'DB_PREFIX', 'wp_' );
/**
* Authentication Unique Keys and Salts
*/
define( 'AUTH_KEY', env( 'AUTH_KEY' ) );
define( 'SECURE_AUTH_KEY', env( 'SECURE_AUTH_KEY' ) );
define( 'LOGGED_IN_KEY', env( 'LOGGED_IN_KEY' ) );
define( 'NONCE_KEY', env( 'NONCE_KEY' ) );
define( 'AUTH_SALT', env( 'AUTH_SALT' ) );
define( 'SECURE_AUTH_SALT', env( 'SECURE_AUTH_SALT' ) );
define( 'LOGGED_IN_SALT', env( 'LOGGED_IN_SALT' ) );
define( 'NONCE_SALT', env( 'NONCE_SALT' ) );
/**
* Custom Settings
*/
define( 'AUTOMATIC_UPDATER_DISABLED', true );
define( 'DISABLE_WP_CRON', env( 'DISABLE_WP_CRON', false ) );
/**
* Sets up WordPress vars and included files.
*/
require_once( ABSPATH . 'wp-settings.php' );