New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Site Aliases #2039
Comments
In what ways is this different than the alias system we already have? For instance, in your
These arguments become the default whenever you run |
Can you define a remote host like this? Maybe I just don't undertand the current alias system. |
WP-CLI doesn't currently support connecting to a remote host. You may want to consider https://github.com/xwp/wp-cli-ssh
This example you're pointing to seems to refer to a remote staging site. WP-CLI can connect to any local WordPress install with the
Have you tried using it? Here's a blog post documenting the feature when it was introduced. |
Picking this up in conjunction with #2754 for v0.24.0 |
The initial version of this feature works like this... One or more aliases can be defined in
An alias is called as the first argument to the
The matching alias will overload the global parameters it defines. When an alias is used, any passed arguments will be treated as local parameters:
|
Feeling pretty good about this now. You can define a group of aliases to run a command against all WordPress instances in the group:
|
It would be really helpful if
wp-cli
supported site-aliases like drush:https://github.com/drush-ops/drush/blob/master/examples/example.aliases.drushrc.php
This would allow you to do something like this:
without having to ssh into the server, cd into the directory and execute the command.
Drush also supports the magic
@all
which allows you to perform the command on all of your aliases. This way, you could have an alias file of hundreds of wordpress sites and update all of them in a single command. :)The text was updated successfully, but these errors were encountered: