Clones a website from source to a new website in destination.
- WordPress sites only. The destination site must not exist yet;
ee site clonecreates it. - One remote side at most. Write the remote side as
[user@ssh-hostname:]sitename..as the destination means “same name as the source”. - SSH and rsync: the server where you run the command must reach the remote server with key-based SSH as that user, and
rsyncmust be installed on both servers. Run v4.13.2 or newer on both servers. - Not copied: alias domains, HTTP auth (
ee auth), cron jobs (ee cron) and changes you made towp-config.php. Add them on the new site after cloning.
SYNOPSIS
ee site clone <source> <destination> [--files] [--db] [--uploads] [--ssl=<ssl>] [--ssl-key=<ssl-key-path>] [--ssl-crt=<ssl-crt-path>] [--wildcard]
OPTIONS
<source>
: Name of source website to be cloned. Format [user@ssh-hostname:]sitename
<destination>
: Name of destination website to be cloned. Format [user@ssh-hostname:]sitename
[--files]
: Copy only files. Combine --files, --db and --uploads to copy several; without any of them, all three are copied.
[--db]
: Copy only database.
[--uploads]
: Copy only uploads.
[--ssl=<ssl>]
: Enables ssl on site. Without it, the new site gets the same SSL type as the source. custom needs --ssl-key and --ssl-crt.
Options:
- le
- off
- self
- inherit
- custom
[--ssl-key=<ssl-key-path>]
: Path to the SSL key file.
[--ssl-crt=<ssl-crt-path>]
: Path to the SSL crt file.
[--wildcard]
: Gets wildcard SSL.
EXAMPLES
# Clone site on same host
$ ee site clone foo.com bar.com
# Clone site from remote server
$ ee site clone root@foo.com:foo.com bar.com
# Clone site from remote with same name
$ ee site clone root@foo.com:foo.com .
# Clone site to remote
$ ee site clone foo.com root@foo.com:bar.com
# Clone site from remote. Only clone files and db, not uploads
$ ee site clone root@foo.com:foo.com bar.com --files --db
# Clone site from remote and enable ssl
$ ee site clone root@foo.com:foo.com bar.com --ssl=le --wildcard
SUBCOMMANDS
| Name | Description |
|---|---|
| ee site clean | Clears Object and Page cache for site. |
| ee site create | Runs site installation with provided site type. |
| ee site delete | Deletes a website. |
| ee site disable | Disables a website. It will stop and remove the docker containers of the website if they are running. |
| ee site enable | Enables a website. It will start the docker containers of the website if they are stopped. |
| ee site info | Display all the relevant site information, credentials and useful links. |
| ee site list | Lists the created websites. |
| ee site publish | Publishes site online using ngrok. |
| ee site refresh | Re-create sites docker-compose file and update the containers. |
| ee site reload | Reload services in containers without restarting container(s) associated with site. |
| ee site restart | Restarts containers associated with site. |
| ee site share | Share a site online using ngrok. |
| ee site ssl | Verifies ssl challenge and also renews certificates(if expired). |
| ee site ssl-renew | Renews letsencrypt ssl certificates. |
| ee site ssl-verify | Completes or retries Let’s Encrypt certificate issuance for a site. |
| ee site sync | Syncs a website from source to an existing website in destination. |
| ee site update | Supports updating and upgrading site. |
GLOBAL PARAMETERS
--sites_path=<path>
Absolute path to where all sites will be stored.
--locale=<locale>
Locale for WordPress.
--le-mail=<le-mail>
Mail-id to be used for letsencrypt.
--env=<env>
EasyEngine server environment.
--wp-mail=<wp-mail>
Default Mail-id to be used for WordPress site installation.
--sysctl=<true/false>
Whether to add sysctl config in docker-compose.
--skip-tty=<true/false>
Skip tty allocation for remote command execution.
--custom-compose=<custom-compose file>
Path to custom compose file.
--[no-]color
Whether to colorize the output.
--debug[=<group>]
Show all PHP errors; add verbosity to EE bootstrap.
--quiet
Suppress informational messages.