Skip to content

Commit 00a3e37

Browse files
Add backup:database documentation, as well as config and env command docs
1 parent a896d44 commit 00a3e37

File tree

5 files changed

+109
-3
lines changed

5 files changed

+109
-3
lines changed

docs/cli/built-in-commands/addons.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,12 +26,12 @@ or
2626

2727
php eecli.php addons:list update-available
2828

29-
List add-ons that can be uninstalled
29+
List add-ons that can be uninstalled:
3030

3131
php eecli.php addons:list u
3232
or
3333

34-
php eecli.php addons:list uninstalled:
34+
php eecli.php addons:list uninstalled
3535

3636
## `addons:install`
3737

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
# backup:database
2+
3+
Database backups
4+
5+
## Options list:
6+
7+
--relative_path=<value>
8+
-p <value>
9+
Path to database backup, relative to the cache folder
10+
11+
--absolute_path=<value>
12+
-a <value>
13+
Absolute path to database backup
14+
15+
--file_name=<value>
16+
-f <value>
17+
Name of sql file to be saved
18+
19+
--speed=<value>
20+
-s <value>
21+
Speed of database backup (between 1-10). Setting a lower speed allows for more time between database commands. Default speed is 5.
22+
23+
24+
## Examples:
25+
26+
### Backup the database to the default path, at the default speed
27+
28+
php eecli.php backup:database
29+
30+
# Example backup path and filename:
31+
system/user/cache/eedatabase_2023-05-30_18h05m39sUTC.sql
32+
33+
### Backup the database to the to an absolute path, with a custom filename
34+
35+
php eecli.php backup:database --file_name=deploy_backup.sql --absolute_path='/home/forge/backups'
36+
37+
### Backup the database at a slow speed, to help with the potential to lock up the database.
38+
39+
php eecli.php backup:database --speed=1
Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
# Config Management
2+
3+
Set of CLI commands that updates the config file values, as well as ENV values. These are commonly use to provision a site or as part of a deploy script.
4+
5+
[TOC]
6+
7+
## `config:config`
8+
9+
Updates values in the config.php file.
10+
11+
### Options list
12+
--config-variable=<value>
13+
-c <value>
14+
The config item to modify
15+
16+
--value=<value>
17+
-v <value>
18+
The value to set the config item to
19+
20+
### Examples
21+
22+
Set system to offline:
23+
24+
php eecli.php config:config -c is_system_on -v n
25+
26+
Set system to online:
27+
28+
php eecli.php config:config -c is_system_on -v y
29+
30+
31+
Set debug to 1:
32+
33+
php eecli.php config:config -c debug -v 1
34+
35+
36+
## `config:env`
37+
38+
Updates values in the .env.php file.
39+
40+
### Options list
41+
--env-variable=<value>
42+
-e <value>
43+
The env item to set/modify
44+
45+
--value=<value>
46+
-v <value>
47+
The value to set the env item to
48+
49+
### Examples
50+
51+
Set system to offline:
52+
53+
php eecli.php config:env -e IS_SYSTEM_ON -v n
54+
55+
Set system to online:
56+
57+
php eecli.php config:env -e IS_SYSTEM_ON -v y
58+
59+
Set EE_INSTALL_MODE to false
60+
61+
php eecli.php config:env -e EE_INSTALL_MODE -v FALSE
62+
63+

docs/cli/built-in-commands/make-action.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# make:action
22

3-
Action Generator -- Creates a new action for an add-on
3+
Action Generator -- Creates a new action for an add-on
44

55
## Options list:
66

docs/toc_sections/_advanced_usage_toc.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -643,10 +643,14 @@
643643
href: cli/built-in-commands/addons.md
644644
- name: Add-on Generator
645645
href: cli/built-in-commands/make-addon.md
646+
- name: Backup Database
647+
href: cli/built-in-commands/backup-database.md
646648
- name: Clear Cache
647649
href: cli/built-in-commands/cache-clear.md
648650
- name: Command Generator
649651
href: cli/built-in-commands/make-command.md
652+
- name: Config Management
653+
href: cli/built-in-commands/config-management.md
650654
- name: Migrations
651655
href: cli/built-in-commands/migrate.md
652656
- name: List

0 commit comments

Comments
 (0)