Show More
@@ -12,6 +12,26 b' The commands available with |RCT| can be' | |||
|
12 | 12 | - Local configuration commands used to help set up your |RCT| configuration. |
|
13 | 13 | |
|
14 | 14 | |
|
15 | .. _tools-rhodecode-list-instance: | |
|
16 | ||
|
17 | rhodecode-list-instances | |
|
18 | ------------------------ | |
|
19 | ||
|
20 | Use this command to list the instance details configured in the | |
|
21 | :file:`/etc/rhodecode/conf/.rhoderc` file. | |
|
22 | ||
|
23 | .. code-block:: bash | |
|
24 | ||
|
25 | $ ./rcstack cli cmd rhodecode-list-instances --config=/etc/rhodecode/conf/.rhoderc | |
|
26 | [instance:production] - Config only | |
|
27 | API-HOST: https://some.url.com | |
|
28 | API-KEY: some.auth.token | |
|
29 | ||
|
30 | [instance:development] - Config only | |
|
31 | API-HOST: http://some.ip.address | |
|
32 | API-KEY: some.auth.token | |
|
33 | ||
|
34 | ||
|
15 | 35 | rhodecode-tools |
|
16 | 36 | --------------- |
|
17 | 37 | |
@@ -163,6 +183,7 b' Example usage:' | |||
|
163 | 183 | removing gist /home/brian/repos/.rc_gist_store/5 |
|
164 | 184 | removing gist /home/brian/repos/.rc_gist_store/8FtCKdcbRKmEvRzTVsEt |
|
165 | 185 | |
|
186 | ||
|
166 | 187 | rhodecode-cleanup-repos |
|
167 | 188 | ----------------------- |
|
168 | 189 | |
@@ -201,30 +222,37 b' Example usage:' | |||
|
201 | 222 | |
|
202 | 223 | .. code-block:: bash |
|
203 | 224 | |
|
204 | # Cleaning up repos using tools installed with RCE 350 and above | |
|
205 | $ ~/.rccontrol/enterprise-4/profile/bin/rhodecode-cleanup-repos \ | |
|
206 | --instance-name=enterprise-4 --older-than=1d | |
|
207 | Scanning for repositories in /home/brian/repos... | |
|
208 | preparing to remove [2] found repositories older than 1 day, 0:00:00 (1d) | |
|
225 | ||
|
226 | # create a .rhoderc file in your host config directory (in :file:`config/_shared/.rhoderc`): | |
|
227 | ||
|
228 | [instance:rcstack-instance] | |
|
229 | api_host = http://rhodecode:10020 | |
|
230 | api_key = <API_KEY> | |
|
231 | repo_dir = /var/opt/rhodecode_repo_store | |
|
232 | ||
|
233 | # Run rcstack cli | |
|
234 | ./rcstack cli cmd rhodecode-cleanup-repos --instance-name=rcstack-instance --config=/etc/rhodecode/conf/.rhoderc | |
|
235 | ||
|
236 | checking if config files needs bootstrapping | |
|
237 | Scanning for repositories in /var/opt/rhodecode_repo_store... | |
|
209 | 238 | |
|
210 | 239 | the following repositories will be deleted completely: |
|
211 |
* REMOVED: 2015-08-05 00:23:18 | / |
|
|
212 |
* REMOVED: 2015-08-04 01:22:10 | / |
|
|
240 | * REMOVED: 2015-08-05 00:23:18 | /var/opt/rhodecode_repo_store/rm__20150805_002318_831 | |
|
241 | * REMOVED: 2015-08-04 01:22:10 | /var/opt/rhodecode_repo_store/rm__20150804_012210_336 | |
|
213 | 242 | are you sure you want to remove them? [y/N]: |
|
214 | 243 | |
|
215 | 244 | # Clean up repos older than 1 year |
|
216 | # If using virtualenv and pre RCE 350 tools installation | |
|
217 | (venv)$ rhodecode-cleanup-repos --instance-name=enterprise-1 \ | |
|
218 | --older-than=365d | |
|
245 | ./rcstack cli cmd rhodecode-cleanup-repos --instance-name=rcstack-instance --config=/etc/rhodecode/conf/.rhoderc --older-than=365d | |
|
219 | 246 | |
|
220 | Scanning for repositories in /home/brian/repos... | |
|
247 | checking if config files needs bootstrapping | |
|
248 | Scanning for repositories in /var/opt/rhodecode_repo_store... | |
|
221 | 249 | preparing to remove [343] found repositories older than 365 days |
|
222 | 250 | |
|
223 | 251 | # clean up repos older than 3 days |
|
224 | # If using virtualenv and pre RCE 350 tools installation | |
|
225 | (venv)$ rhodecode-cleanup-repos --instance-name=enterprise-1 \ | |
|
226 | --older-than=3d | |
|
227 |
Scanning for repositories in / |
|
|
252 | ./rcstack cli cmd rhodecode-cleanup-repos --instance-name=rcstack-instance --config=/etc/rhodecode/conf/.rhoderc --older-than=3d | |
|
253 | ||
|
254 | checking if config files needs bootstrapping | |
|
255 | Scanning for repositories in /var/opt/rhodecode_repo_store... | |
|
228 | 256 | preparing to remove [3] found repositories older than 3 days |
|
229 | 257 | |
|
230 | 258 | .. _tools-config: |
@@ -420,9 +448,8 b' Example usage:' | |||
|
420 | 448 | } |
|
421 | 449 | |
|
422 | 450 | # Cat a file and pipe to gist |
|
423 | # in RCE 3.5.0 tools and above | |
|
424 | $ cat ~/.rhoderc | ~/.rccontrol/{instance-id}/profile/bin/rhodecode-gist \ | |
|
425 | --instance-name=enterprise-4 -d '.rhoderc copy' create | |
|
451 | ||
|
452 | $ cat ~/.rhoderc | ./rcstack cli cmd rhodecode-gist --instance-name=rcstack-instance --config=/etc/rhodecode/conf/.rhoderc -d '.rhoderc copy' create | |
|
426 | 453 | { |
|
427 | 454 | "error": null, |
|
428 | 455 | "id": 9253, |
@@ -512,41 +539,18 b' Example usage:' | |||
|
512 | 539 | |
|
513 | 540 | .. code-block:: bash |
|
514 | 541 | |
|
515 | # Run the indexer | |
|
516 | $ ~/.rccontrol/enterprise-4/profile/bin/rhodecode-index \ | |
|
517 | --instance-name=enterprise-4 | |
|
542 | # Create the indexing mapping file | |
|
543 | $ ./rcstack cli cmd rhodecode-index --instance-name=rcstack-instance --config=/etc/rhodecode/conf/.rhoderc --create-mapping search_mapping.ini | |
|
518 | 544 | |
|
519 | # Run indexer based on search_mapping.ini file | |
|
520 | # This is using pre-350 virtualenv | |
|
521 | (venv)$ rhodecode-index --instance-name=enterprise-1 | |
|
545 | # Run the indexer | |
|
546 | $ ./rcstack cli cmd rhodecode-index --instance-name=rcstack-instance --config=/etc/rhodecode/conf/.rhoderc | |
|
547 | ||
|
548 | # Run indexer based on search_mapping.ini file using rhodecode-tools virtualenv | |
|
549 | (venv)$ rhodecode-index --instance-name=rcstack-instance | |
|
522 | 550 | |
|
523 | 551 | # Index from the command line without creating |
|
524 | 552 | # the .rhoderc file |
|
525 |
$ rhodecode-index --apikey=key --apihost=http://rhodecode.server |
|
|
526 | --instance-name=enterprise-2 --save-config | |
|
527 | ||
|
528 | # Create the indexing mapping file | |
|
529 | $ ~/.rccontrol/enterprise-4/profile/bin/rhodecode-index \ | |
|
530 | --create-mapping search_mapping.ini --instance-name=enterprise-4 | |
|
531 | ||
|
532 | .. _tools-rhodecode-list-instance: | |
|
533 | ||
|
534 | rhodecode-list-instances | |
|
535 | ------------------------ | |
|
536 | ||
|
537 | Use this command to list the instance details configured in the | |
|
538 | :file:`~/.rhoderc` file. | |
|
539 | ||
|
540 | .. code-block:: bash | |
|
541 | ||
|
542 | $ .rccontrol/enterprise-1/profile/bin/rhodecode-list-instances | |
|
543 | [instance:production] - Config only | |
|
544 | API-HOST: https://some.url.com | |
|
545 | API-KEY: some.auth.token | |
|
546 | ||
|
547 | [instance:development] - Config only | |
|
548 | API-HOST: http://some.ip.address | |
|
549 | API-KEY: some.auth.token | |
|
553 | $ rhodecode-index --apikey=key --apihost=http://rhodecode.server --instance-name=rcstack-instance --save-config | |
|
550 | 554 | |
|
551 | 555 | |
|
552 | 556 | .. _tools-setup-config: |
General Comments 0
You need to be logged in to leave comments.
Login now