|
1 | 1 | # RRZE-CLI
|
2 | 2 |
|
3 |
| -WP-CLI Erweiterung für die CMS-Verwaltung des RRZE. |
| 3 | +WP-CLI extension for RRZE's CMS management. |
4 | 4 |
|
5 |
| -## Anforderungen |
| 5 | +## Requirements |
6 | 6 |
|
7 |
| -- PHP >= 8.0 |
8 |
| -- WP-CLI >= 2.7.1 |
| 7 | +- PHP >= 8.2 |
| 8 | +- WP-CLI >= 2.11.0 |
9 | 9 |
|
10 | 10 | ## Migration
|
11 | 11 |
|
12 |
| -Diese WP-CLI-Erweiterung macht den Prozess der Migration von Websites von einzelnen Wordpress-Instanzen zu einer Multisite-Instanz (oder umgekehrt) viel einfacher. Es exportiert alles in ein ZIP-Paket, das verwendet werden kann, um es automatisch in die gewünschte Multisite-Installation zu importieren. |
| 12 | +This WP-CLI extension simplifies the process of migrating websites on a WordPress multisite installation. It exports everything to a ZIP package, which can then be automatically imported into the desired multisite installation. |
13 | 13 |
|
14 |
| -### Verwendung |
| 14 | +### Export |
15 | 15 |
|
16 |
| -Der Befehl `rrze-migration export` exportiert eine ganze Website in ein Zip-Paket. |
| 16 | +The `rrze-migration export` command exports an entire website into a ZIP package. |
17 | 17 |
|
18 | 18 | ```
|
19 |
| -$ wp rrze-migration export all website.zip --plugins --themes --uploads |
| 19 | +$ wp rrze-migration export all |
20 | 20 | ```
|
21 | 21 |
|
22 |
| -Der obige Befehl exportiert Benutzer, Tabellen, Plugins-Ordner, Themes-Ordner und den Uploads-Ordner in eine ZIP-Datei, die man auf der Multisite-Instanz migrieren kann, um sie mit dem Befehl `import all` zu importieren. Die optionalen Flags `--plugins --themes --uploads` fügen den Plugins-Ordner, den Themes-Ordner bzw. den Uploads-Ordner zur ZIP-Datei hinzu. |
23 |
| - |
24 |
| -Man kann auch Websites aus einer Multisite-Instanz exportieren, man muss dazu den Parameter `--blog_id` übergeben. Bspw: |
| 22 | +You can also export websites from a Multisite instance by passing the `--url` parameter. For example: |
25 | 23 |
|
26 | 24 | ```
|
27 |
| -$ wp rrze-migration export all website.zip --blog_id=2 |
| 25 | +$ wp rrze-migration export all --url=website-url |
28 | 26 | ```
|
29 |
| - |
30 |
| -Der Befehl `rrze-migration import` kann verwendet werden, um eine Website aus einem ZIP-Paket zu importieren. |
| 27 | +In some special cases, `rrze-migration export` may not detect all custom tables when exporting a website to a Multisite instance. If you need to migrate non-standard tables, you can use the `--tables` or `--custom-tables` parameter. For example: |
31 | 28 |
|
32 | 29 | ```
|
33 |
| -$ wp rrze-migration import all website.zip |
| 30 | +$ wp rrze-migration export all --url=website-url --custom-tables=custom_table_1,custom_table_2 |
34 | 31 | ```
|
35 | 32 |
|
36 |
| -Beim Importieren in eine Multisite-Instanz wird eine neue Website innerhalb der Multisite-Instanz erstellt, basierend auf der Website, die man gerade exportiert hat. Beim Importieren in eine einzelne Installation wird die aktuelle Website mit der exportierten Website überschrieben. |
| 33 | +If you pass `--tables`, only the specified tables will be exported. Therefore, when using this option, ensure that all necessary tables, including WordPress default tables, are included in the export. |
37 | 34 |
|
38 |
| -Der Befehl `rrze-migration import all` kümmert sich um alles, was getan werden muss, wenn eine Website in der Multisite-Instanz migrieren wird (Ersetzen von Tabellenpräfixen, Aktualisieren von `post_author`-IDs usw.). |
| 35 | +If you pass `--uploads`, the files in the media library will also be exported. However, it is only recommended to use this option where the media library does not exceed 500 MB in total. Otherwise, it is recommended to use `rsync` for example. |
39 | 36 |
|
40 |
| -Wenn man eine neue URL für die zu importierende Website einrichten muss, kann man diese an den Befehl `rrze-migration import all` übergeben. |
| 37 | +### Import |
| 38 | + |
| 39 | +The `rrze-migration import` command can be used to import a website from a ZIP package. |
41 | 40 |
|
42 | 41 | ```
|
43 |
| -$ wp rrze-migration import all website.zip --new_url=new-website-domain |
| 42 | +$ wp rrze-migration import all website.zip |
44 | 43 | ```
|
| 44 | +When importing into a Multisite instance, a new website within the Multisite network is created based on the exported website. When importing into a standalone installation, the current website is overwritten with the exported website. |
45 | 45 |
|
46 |
| -Der Befehl `rrze-migration import` unterstützt auch den Parameter `--mysql-single-transaction`, der den SQL-Export in eine einzige Transaktion umschließt, um alle Änderungen aus dem Import auf einmal festzuschreiben und zu verhindern, dass der Schreibvorgang den Datenbankserver überlastet. |
| 46 | +The `rrze-migration import all` command handles everything required for migrating a website within a Multisite instance. |
47 | 47 |
|
48 |
| -Man kann auch `--blog_id` an den Befehl `import all` übergeben, in diesem Fall überschreibt der Import eine vorhandene Website. |
| 48 | +If you need to set up a new URL for the imported website, you can pass it to the `rrze-migration import all` command. |
49 | 49 |
|
50 | 50 | ```
|
51 |
| -$ wp rrze-migration import all website.zip --new_url=new-website-domain --blog_id=2 |
| 51 | +$ wp rrze-migration import all website.zip --new_url=new-website-url |
52 | 52 | ```
|
53 | 53 |
|
54 |
| -In einigen Sonderfällen ist es möglich, `rrze-migration export` nicht alle benutzerdefinierten Tabellen erkennen kann, während eine Website in eine Multisite-Instanz exportiert wird. Wenn man also nicht standardmäßige Tabellen migrieren muss, kann man das Parameter `--tables` oder `--custom-tables` verwenden. Bspw: |
| 54 | +The `rrze-migration import` command also supports the `--mysql-single-transaction` parameter, which wraps the SQL export into a single transaction to commit all import changes at once, preventing database server overload. |
55 | 55 |
|
56 | 56 | ```
|
57 |
| -$ wp rrze-migration export all website.zip --blog_id=1 --custom-tables=custom_table_1,custom_table_2 |
| 57 | +$ wp rrze-migration import all website.zip --new_url=new-website-url --mysql-single-transaction |
58 | 58 | ```
|
59 | 59 |
|
60 |
| -Wenn man `--tables` übergeben, werden nur die übergebenen Tabellen exportiert. Wenn man es also verwendet, muss man sicher stellen, dass alle Tabellen übergibt, die man exportieren möchtet, einschließlich der Standardtabellen des WordPress. |
61 |
| - |
62 |
| -### Anmerkungen |
| 60 | +### Notes |
63 | 61 |
|
64 |
| -Wenn die Themes und die Plugins auf WordPress-Art erstellt wurden, sollte man nach der Migration keine größeren Probleme haben. Man muss daran denken, dass bei einigen Themes Inkompatibilitätsprobleme auftreten können (bspw. fest codierte Links wie '/kontakt' usw.). Abhängig von der Codebasis der Website, die man migriert, muss man möglicherweise einige Anpassungen an dem Code vornehmen. |
| 62 | +If themes and plugins are developed according to WordPress standards, migration should proceed without major issues. However, depending on the codebase of the website being migrated, you may need to make some adjustments to the code. |
0 commit comments