lockss-turtles 0.5.0.dev3__py3-none-any.whl → 0.6.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,1041 +0,0 @@
1
- Metadata-Version: 2.1
2
- Name: lockss-turtles
3
- Version: 0.5.0.dev3
4
- Summary: Tool to manage LOCKSS plugin sets and LOCKSS plugin registries
5
- Home-page: https://www.lockss.org/
6
- License: BSD-3-Clause
7
- Author: Thib Guicherd-Callin
8
- Author-email: thib@cs.stanford.edu
9
- Requires-Python: >=3.8,<4.0
10
- Classifier: Development Status :: 5 - Production/Stable
11
- Classifier: Environment :: Console
12
- Classifier: Intended Audience :: Developers
13
- Classifier: Intended Audience :: System Administrators
14
- Classifier: License :: OSI Approved :: BSD License
15
- Classifier: Operating System :: POSIX :: Linux
16
- Classifier: Programming Language :: Python :: 3
17
- Classifier: Programming Language :: Python :: 3.8
18
- Classifier: Programming Language :: Python :: 3.9
19
- Classifier: Programming Language :: Python :: 3.10
20
- Classifier: Programming Language :: Python :: 3.11
21
- Classifier: Programming Language :: Python :: 3.12
22
- Classifier: Topic :: Utilities
23
- Requires-Dist: java-manifest (>=1.1.0,<2.0.0)
24
- Requires-Dist: jsonschema (>=4.23.0,<5.0.0)
25
- Requires-Dist: pyyaml (>=6.0.2,<7.0.0)
26
- Requires-Dist: rich-argparse (>=1.5.2,<2.0.0)
27
- Requires-Dist: tabulate (>=0.9.0,<0.10.0)
28
- Requires-Dist: xdg (>=6.0.0,<7.0.0)
29
- Project-URL: Repository, https://github.com/lockss/lockss-turtles
30
- Description-Content-Type: text/x-rst
31
-
32
- =======
33
- Turtles
34
- =======
35
-
36
- .. |RELEASE| replace:: 0.5.0-dev1
37
- .. |RELEASE_DATE| replace:: ?
38
-
39
- .. |HELP| replace:: ``--help/-h``
40
- .. |IDENTIFIER| replace:: ``--identifier/-i``
41
- .. |IDENTIFIERS| replace:: ``--identifiers/-I``
42
- .. |JAR| replace:: ``--jar/-j``
43
- .. |JARS| replace:: ``--jars/-J``
44
- .. |LAYER| replace:: ``--layer/-l``
45
- .. |LAYERS| replace:: ``--layers/-L``
46
- .. |PLUGIN_REGISTRY_CATALOG| replace:: ``--plugin-registry-catalog/-r``
47
- .. |PLUGIN_SET_CATALOG| replace:: ``--plugin-set-catalog/-s``
48
- .. |PLUGIN_SIGNING_CREDENTIALS| replace:: ``--plugin-signing-credentials/-c``
49
- .. |PRODUCTION| replace:: ``--production/-p``
50
- .. |TESTING| replace:: ``--testing/-t``
51
-
52
- .. image:: https://assets.lockss.org/images/logos/turtles/turtles_128x128.png
53
- :alt: Turtles logo
54
- :align: right
55
-
56
- Turtles is a tool to manage LOCKSS plugin sets and LOCKSS plugin registries.
57
-
58
- **Latest release:** |RELEASE| (|RELEASE_DATE|)
59
-
60
- -----------------
61
- Table of Contents
62
- -----------------
63
-
64
- * `Installation`_
65
-
66
- * `Prerequisites`_
67
-
68
- * `pip`_
69
-
70
- * `Overview`_
71
-
72
- * `Building Plugins`_
73
-
74
- * `Deploying Plugins`_
75
-
76
- * `Configuration Files`_
77
-
78
- * `Plugin Set Catalog`_
79
-
80
- * `Plugin Sets`_
81
-
82
- * `Plugin Set Builders`_
83
-
84
- * `Maven Plugin Set Builder`_
85
-
86
- * `Maven Plugin Set Builder Prerequisites`_
87
-
88
- * `Maven Plugin Set Builder Declaration`_
89
-
90
- * `Ant Plugin Set Builder`_
91
-
92
- * `Ant Plugin Set Builder Prerequisites`_
93
-
94
- * `Ant Plugin Set Builder Declaration`_
95
-
96
- * `Plugin Registry Catalog`_
97
-
98
- * `Plugin Registries`_
99
-
100
- * `Plugin Registry Layouts`_
101
-
102
- * `Directory Plugin Registry Layout`_
103
-
104
- * `Directory Plugin Registry Layout Prerequisites`_
105
-
106
- * `Directory Plugin Registry Layout Declaration`_
107
-
108
- * `RCS Plugin Registry Layout`_
109
-
110
- * `RCS Plugin Registry Layout Prerequisites`_
111
-
112
- * `RCS Plugin Registry Layout Declaration`_
113
-
114
- * `Plugin Registry Layers`_
115
-
116
- * `Plugin Signing Credentials`_
117
-
118
- * `Command Line Tool`_
119
-
120
- * `Synopsis`_
121
-
122
- * `Commands`_
123
-
124
- * `Top-Level Program`_
125
-
126
- * `build-plugin`_
127
-
128
- * `copyright`_
129
-
130
- * `deploy-plugin`_
131
-
132
- * `license`_
133
-
134
- * `release-plugin`_
135
-
136
- * `usage`_
137
-
138
- * `version`_
139
-
140
- * `Options`_
141
-
142
- * `Plugin Identifier Arguments and Options`_
143
-
144
- * `Plugin Registry Layer Options`_
145
-
146
- * `Output Format Control`_
147
-
148
- ------------
149
- Installation
150
- ------------
151
-
152
- Turtles is available from the `Python Package Index <https://pypi.org/>`_ (PyPI) as ``lockss-turtles`` (https://pypi.org/project/lockss-turtles), and can be installed with `pip`_.
153
-
154
- The installation process adds a ``turtles`` `Command Line Tool`_. You can check at the command line that the installation is functional by running ``turtles version`` or ``turtles --help``.
155
-
156
- Prerequisites
157
- =============
158
-
159
- * `Python <https://www.python.org/>`_ 3.7 or greater.
160
-
161
- * Additional prerequisites depending on the types of `Plugin Set Builders`_ or `Plugin Registry Layouts`_ in use (see their respective requirements).
162
-
163
- Prerequisites for development work only:
164
-
165
- * `Poetry <https://python-poetry.org/>`_ 1.4 or greater.
166
-
167
- .. _pip:
168
-
169
- ``pip``
170
- =======
171
-
172
- You can install Turtles with ``pip``.
173
-
174
- To install it in your own non-root, non-virtual environment, use the ``--user`` option::
175
-
176
- pip3 install --user lockss-turtles
177
-
178
- To install it in a virtual environment, simply use::
179
-
180
- pip3 install lockss-turtles
181
-
182
- .. danger::
183
-
184
- Do not run ``pip3``/``pip`` as ``root``, with ``sudo`` or otherwise.
185
-
186
- --------
187
- Overview
188
- --------
189
-
190
- Building Plugins
191
- ================
192
-
193
- You can use Turtles to build (package and sign) LOCKSS plugins from one or more LOCKSS plugin sets (codebases containing plugins).
194
-
195
- You will need to define one or more `Plugin Sets`_, list them in a `Plugin Set Catalog`_, and declare your `Plugin Signing Credentials`_.
196
-
197
- You then use the `build-plugin`_ command to build plugins, or the `release-plugin`_ command to build and deploy plugins (equivalent of `build-plugin`_ followed by `deploy-plugin`_).
198
-
199
- Deploying Plugins
200
- =================
201
-
202
- You can use Turtles to deploy LOCKSS plugins to LOCKSS plugin registries.
203
-
204
- You will need to define one or more `Plugin Registries`_ and declare them in a `Plugin Registry Catalog`_.
205
-
206
- You then use the `deploy-plugin`_ command to deploy plugin JARs, or the `release-plugin`_ command to build and deploy plugins from `Plugin Sets`_ (equivalent of `build-plugin`_ followed by `deploy-plugin`_).
207
-
208
- -------------------
209
- Configuration Files
210
- -------------------
211
-
212
- All Turtles configuration files are YAML files and have a top-level ``kind`` key that declares what kind of configuration file it is.
213
-
214
- Some Turtles commands require a `Plugin Set Catalog`_, `Plugin Registry Catalog`_, or `Plugin Signing Credentials`_. You can specify the configuration file to use via the appropriate command line option (for example |PLUGIN_SET_CATALOG|). Otherwise, Turtles will look for then appropriate configuration file (for example ``plugin-set-catalog.yaml``) in several standard directories, in this order:
215
-
216
- * ``$XDG_CONFIG_HOME/lockss.turtles`` (by default ``$HOME/.config/lockss.turtles``)
217
-
218
- * ``/usr/local/share/lockss.turtles``
219
-
220
- * ``/etc/lockss.turtles``
221
-
222
- Plugin Set Catalog
223
- ==================
224
-
225
- Turtles commands that are `Building Plugins`_ (`build-plugin`_, `release-plugin`_) need a plugin set catalog. It can be specified via the |PLUGIN_SET_CATALOG| option, otherwise Turtles looks through `Configuration Files`_ for a file named ``plugin-set-catalog.yaml``.
226
-
227
- A plugin set catalog is defined by a YAML document::
228
-
229
- ---
230
- kind: PluginSetCatalog
231
- plugin-set-files:
232
- - /path/to/some/file1.yaml
233
- - /path/to/another/file2.yaml
234
- - ...
235
-
236
- The contents are described below:
237
-
238
- ``kind``
239
- *Required.* Must be set to ``PluginSetCatalog``.
240
-
241
- ``plugin-set-files``
242
- *Required.* A list of one or more paths to `Plugin Sets`_.
243
-
244
- Plugin Sets
245
- ===========
246
-
247
- A plugin set is a project containing the source code of one or more LOCKSS plugins.
248
-
249
- A plugin set is defined by a YAML document::
250
-
251
- ---
252
- kind: PluginSet
253
- id: mypluginset
254
- name: My Plugin Set
255
- builder:
256
- type: ...
257
- ...
258
-
259
- The contents are described below:
260
-
261
- ``kind``
262
- *Required.* Must be set to ``PluginSet``.
263
-
264
- ``id``
265
- *Required.* A short identifier for the plugin set, for example ``mypluginset``.
266
-
267
- ``name``
268
- *Required.* A display name for the plugin set, for example ``My Plugin Set``.
269
-
270
- ``builder``
271
- *Required.* An object defining the plugin set's builder together with its options.
272
-
273
- ``type``
274
- *Required.* A plugin set builder type. See `Plugin Set Builders`_ below.
275
-
276
- Other
277
- Additional properties depending on the plugin set builder type. See `Plugin Set Builders`_ below.
278
-
279
- Plugin Set Builders
280
- ===================
281
-
282
- Turtles `Plugin Sets`_ support two types of plugin set builders:
283
-
284
- * `Maven Plugin Set Builder`_
285
-
286
- * `Ant Plugin Set Builder`_
287
-
288
- Maven Plugin Set Builder
289
- ------------------------
290
-
291
- This type of plugin set builder is for a Maven project inheriting from ``org.lockss:lockss-plugins-parent-pom``.
292
-
293
- Maven Plugin Set Builder Prerequisites
294
- ++++++++++++++++++++++++++++++++++++++
295
-
296
- * Java Development Kit 8 (JDK).
297
-
298
- * `Apache Maven <https://maven.apache.org/>`_.
299
-
300
- Maven Plugin Set Builder Declaration
301
- ++++++++++++++++++++++++++++++++++++
302
-
303
- For this plugin set builder type, the ``builder`` object in the plugin set definition has the following structure::
304
-
305
- ---
306
- kind: PluginSet
307
- id: ...
308
- name: ...
309
- builder:
310
- type: mvn
311
- main: ...
312
- test: ...
313
-
314
- ``type``
315
- *Required.* Must be set to ``mvn``.
316
-
317
- ``main``
318
- *Optional.* The path (relative to the root of the project) to the plugins' source code. *Default:* ``src/main/java``.
319
-
320
- ``test``
321
- *Optional.* The path (relative to the root of the project) to the plugins' unit tests. *Default:* ``src/test/java``.
322
-
323
- Ant Plugin Set Builder
324
- ----------------------
325
-
326
- This type of plugin set builder is for the LOCKSS 1.x (https://github.com/lockss/lockss-daemon) code tree, based on Ant.
327
-
328
- Ant Plugin Set Builder Prerequisites
329
- ++++++++++++++++++++++++++++++++++++
330
-
331
- * Java Development Kit 8 (JDK).
332
-
333
- * `Apache Ant <https://ant.apache.org/>`_.
334
-
335
- * ``JAVA_HOME`` must be set appropriately.
336
-
337
- Ant Plugin Set Builder Declaration
338
- ++++++++++++++++++++++++++++++++++
339
-
340
- For this plugin set builder type, the ``builder`` object in the plugin set definition has the following structure::
341
-
342
- ---
343
- kind: PluginSet
344
- id: ...
345
- name: ...
346
- builder:
347
- type: ant
348
- main: ...
349
- test: ...
350
-
351
- ``type``
352
- *Required.* Must be set to ``ant``.
353
-
354
- ``main``
355
- *Optional.* The path (relative to the root of the project) to the plugins' source code. *Default:* ``plugins/src``.
356
-
357
- ``test``
358
- *Optional.* The path (relative to the root of the project) to the plugins' unit tests. *Default:* ``plugins/test/src``.
359
-
360
- Plugin Registry Catalog
361
- =======================
362
-
363
- Turtles commands that are `Deploying Plugins`_ (`deploy-plugin`_, `release-plugin`_) need a plugin registry catalog. It can be specified via the |PLUGIN_REGISTRY_CATALOG| option, otherwise Turtles looks through `Configuration Files`_ for a file named ``plugin-registry-catalog.yaml``.
364
-
365
- A plugin set catalog is defined by a YAML document::
366
-
367
- ---
368
- kind: PluginRegistryCatalog
369
- plugin-registry-files:
370
- - /path/to/some/file1.yaml
371
- - /path/to/another/file2.yaml
372
- - ...
373
-
374
- The contents are described below:
375
-
376
- ``kind``
377
- *Required.* Must be set to ``PluginRegistryCatalog``.
378
-
379
- ``plugin-registry-files``
380
- *Required.* A list of one or more paths to `Plugin Registries`_.
381
-
382
- Plugin Registries
383
- =================
384
-
385
- A plugin registry is a structure containing LOCKSS plugins packaged as signed JAR files.
386
-
387
- Currently the only predefined structures are directory structures local to the file system, which are then typically served by a Web server.
388
-
389
- A plugin registry is defined by a YAML document::
390
-
391
- ---
392
- kind: PluginRegistry
393
- id: mypluginregistry
394
- name: My Plugin Registry
395
- layout:
396
- type: ...
397
- ...
398
- layers:
399
- - ...
400
- plugin-identifiers:
401
- - edu.myuniversity.plugin.publisherx.PublisherXPlugin
402
- - edu.myuniversity.plugin.publishery.PublisherYPlugin
403
- - ...
404
- suppressed-plugin-identifiers:
405
- - edu.myuniversity.plugin.old.OldPlugin
406
- - ...
407
-
408
- The contents are described below:
409
-
410
- ``kind``
411
- *Required.* Must be set to ``PluginRegistry``.
412
-
413
- ``id``
414
- *Required.* A short identifier for the plugin registry, for example ``mypluginregistry``.
415
-
416
- ``name``
417
- *Required.* A display name for the plugin registry, for example ``My Plugin Registry``.
418
-
419
- ``layout``
420
- *Required.* An object defining the plugin registry's layout together with its options.
421
-
422
- ``type``
423
- *Required.* A plugin registry layout type. See `Plugin Registry Layouts`_ below.
424
-
425
- Other
426
- Additional properties depending on the plugin registry layout type. See `Plugin Registry Layouts`_ below.
427
-
428
- ``layers``
429
- *Required.* A list of objects describing the layers of the plugin registry. See `Plugin Registry Layers`_ below.
430
-
431
- ``plugin-identifiers``
432
- *Required.* Non-empty list of the plugin identifiers in this plugin registry.
433
-
434
- ``suppressed-plugin-identifiers``
435
- *Optional.* Non-empty list of plugin identifiers that are excluded from this plugin registry.
436
-
437
- Turtles does not currently do anything with this information, but it can be used to record plugins that have been abandoned or retracted over the lifetime of the plugin registry.
438
-
439
- Plugin Registry Layouts
440
- =======================
441
-
442
- Turtles supports two kinds of plugin registry layouts:
443
-
444
- * `Directory Plugin Registry Layout`_
445
-
446
- * `RCS Plugin Registry Layout`_
447
-
448
- Directory Plugin Registry Layout
449
- --------------------------------
450
-
451
- In this type of plugin registry layout, each layer consists of a directory on the local file system where signed plugin JARs are stored, which is then typically served by a Web server. The directory for each layer is designated by the layer's ``path`` property.
452
-
453
- Directory Plugin Registry Layout Prerequisites
454
- ++++++++++++++++++++++++++++++++++++++++++++++
455
-
456
- None.
457
-
458
- Directory Plugin Registry Layout Declaration
459
- ++++++++++++++++++++++++++++++++++++++++++++
460
-
461
- For this plugin registry layout type, the ``layout`` object in the plugin registry definition has the following structure::
462
-
463
- ---
464
- kind: PluginRegistry
465
- id: ...
466
- name: ...
467
- layout:
468
- type: directory
469
- file-naming-convention: ...
470
- layers:
471
- - ...
472
- plugin-identifiers:
473
- - ...
474
- suppressed-plugin-identifiers:
475
- - ...
476
-
477
- ``type``
478
- *Required.* Must be set to ``directory``.
479
-
480
- ``file-naming-convention``
481
- *Optional.* A rule for what to name each deployed JAR file. If unspecified, the behavior is that of ``identifier``. Can be one of:
482
-
483
- * ``identifier``: Use the plugin identifier and add ``.jar``. For example ``edu.myuniversity.plugin.publisherx.PublisherXPlugin`` results in ``edu.myuniversity.plugin.publisherx.PublisherXPlugin.jar``.
484
-
485
- * ``underscore``: Replace ``.`` in the plugin identifier with ``_``, and add ``.jar``. For example ``edu.myuniversity.plugin.publisherx.PublisherXPlugin`` results in ``edu_myuniversity_plugin_publisherx_PublisherXPlugin.jar``.
486
-
487
- * ``abbreviated``: Use the last dotted component of the plugin identifier and add ``.jar``. For example ``edu.myuniversity.plugin.publisherx.PublisherXPlugin`` results in ``PublisherXPlugin.jar``.
488
-
489
- RCS Plugin Registry Layout
490
- --------------------------
491
-
492
- In this specialization of the `Directory Plugin Registry Layout`_, each successive version of a given JAR is kept locally in RCS.
493
-
494
- RCS Plugin Registry Layout Prerequisites
495
- ++++++++++++++++++++++++++++++++++++++++
496
-
497
- * `GNU RCS <https://www.gnu.org/software/rcs/>`_.
498
-
499
- RCS Plugin Registry Layout Declaration
500
- ++++++++++++++++++++++++++++++++++++++
501
-
502
- For this plugin registry layout type, the ``layout`` object in the plugin registry definition has the following structure::
503
-
504
- ---
505
- kind: PluginRegistry
506
- id: ...
507
- name: ...
508
- layout:
509
- type: rcs
510
- file-naming-convention: ...
511
- layers:
512
- - ...
513
- plugin-identifiers:
514
- - ...
515
- suppressed-plugin-identifiers:
516
- - ...
517
-
518
- ``type``
519
- *Required.* Must be set to ``rcs``.
520
-
521
- ``file-naming-convention``
522
- *Optional.* A rule for what to name each deployed JAR file. If unspecified, the behavior is that of ``identifier``. Can be one of:
523
-
524
- * ``identifier``: Use the plugin identifier and add ``.jar``. For example ``edu.myuniversity.plugin.publisherx.PublisherXPlugin`` results in ``edu.myuniversity.plugin.publisherx.PublisherXPlugin.jar``.
525
-
526
- * ``underscore``: Replace ``.`` in the plugin identifier with ``_``, and add ``.jar``. For example ``edu.myuniversity.plugin.publisherx.PublisherXPlugin`` results in ``edu_myuniversity_plugin_publisherx_PublisherXPlugin.jar``.
527
-
528
- * ``abbreviated``: Use the last dotted component of the plugin identifier and add ``.jar``. For example ``edu.myuniversity.plugin.publisherx.PublisherXPlugin`` results in ``PublisherXPlugin.jar``.
529
-
530
- Plugin Registry Layers
531
- ======================
532
-
533
- A plugin registry consists of one or more layers.
534
-
535
- Some plugin registries only one layer, in which case the LOCKSS boxes in a network using the plugin registry will get what is released to it. Some plugin registries may have two or more layers, with the additional layers used for plugin development or content processing quality assurance.
536
-
537
- Layers are sequential in nature; a new version of a plugin is released to the lowest layer first, then to the next layer (after some process), and so on until the highest layer. This sequencing is reflected in the ordering of the ``layers`` list in the plugin registry definition.
538
-
539
- Although the identifiers (see ``id`` below) and display names (see ``name`` below) of plugin registry layers are arbitrary, the highest layer is commonly referred to as the *production* layer, and when there are exactly two layers, the lower layer is commonly referred to as the *testing* layer. Turtles reflects this common idiom with built-in |PRODUCTION| and |TESTING| options that are shorthand for ``--layer=production`` and ``--layer=testing`` respectively.
540
-
541
- It is possible for multiple plugin registries to have a layer ``path`` in common. An example would be a team working on several plugin registries for different purposes, having distinct (public) production layer paths, but sharing a single (internal) testing layer path, if they are the only audience for it.
542
-
543
- A plugin registry layer is defined as one of the objects in the plugin registry definition's ``layers`` list. Each layer object has the following structure::
544
-
545
- ---
546
- kind: PluginRegistry
547
- id: ...
548
- name: ...
549
- layout:
550
- type: ...
551
- ...
552
- layers:
553
- - id: testing
554
- name: My Plugin Registry (Testing)
555
- path: /path/to/testing
556
- - id: production
557
- name: My Plugin Registry (Production)
558
- path: /path/to/production
559
- - ...
560
- plugin-identifiers:
561
- - ...
562
- suppressed-plugin-identifiers:
563
- - ...
564
-
565
- ``id``
566
- *Required.* A short identifier for the plugin registry layer, for example ``testing``.
567
-
568
- ``name``
569
- *Required.* A display name for the plugin registry layer, for example ``My Plugin Registry (Testing)``.
570
-
571
- ``path``
572
- *Required.* The local path to the root of the plugin registry layer, for example ``/path/to/testing``.
573
-
574
- Plugin Signing Credentials
575
- ==========================
576
-
577
- Turtles commands that are `Building Plugins`_ (`build-plugin`_, `release-plugin`_) need a reference to plugin signing credentials. They can be specified via the |PLUGIN_SIGNING_CREDENTIALS| option, otherwise Turtles looks through `Configuration Files`_ for a file named ``plugin-signing-credentials.yaml``.
578
-
579
- Plugin signing credentials are defined by a YAML document::
580
-
581
- ---
582
- kind: PluginSigningCredentials
583
- plugin-signing-keystore: /path/to/myalias.keystore
584
- plugin-signing-alias: myalias
585
-
586
- The contents are described below:
587
-
588
- ``kind``
589
- *Required.* Must be set to ``PluginSigningCredentials``.
590
-
591
- ``plugin-signing-keystore``
592
- *Required.* Path to the plugin signing key (keystore).
593
-
594
- ``plugin-signing-alias``
595
- *Required.* The alias to use, which must be that of the plugin signing key (keystore) and also found in the LOCKSS network's shared keystore.
596
-
597
- -----------------
598
- Command Line Tool
599
- -----------------
600
-
601
- Turtles is invoked at the command line as::
602
-
603
- turtles
604
-
605
- or as a Python module::
606
-
607
- python3 -m lockss.turtles
608
-
609
- Help messages and this document use ``turtles`` throughout, but the two invocation styles are interchangeable.
610
-
611
- Synopsis
612
- ========
613
-
614
- Turtles uses `Commands`_, in the style of programs like ``git``, ``dnf``/``yum``, ``apt``/``apt-get``, and the like. You can see the list of available `Commands`_ by invoking ``turtles --help``, and you can find a usage summary of all the `Commands`_ by invoking ``turtles usage``::
615
-
616
- usage: turtles [-h] [--debug-cli] [--non-interactive] COMMAND ...
617
-
618
- turtles build-plugin [-h] [--output-format FMT] [--password PASS]
619
- [--plugin-set-catalog FILE]
620
- [--plugin-signing-credentials FILE]
621
- [--identifier PLUGID] [--identifiers FILE]
622
- [PLUGID ...]
623
-
624
- turtles copyright [-h]
625
-
626
- turtles deploy-plugin [-h] [--output-format FMT]
627
- [--plugin-registry-catalog FILE] [--production]
628
- [--testing] [--jar PLUGJAR] [--jars FILE]
629
- [--layer LAYER] [--layers FILE]
630
- [PLUGJAR ...]
631
-
632
- turtles license [-h]
633
-
634
- turtles release-plugin [-h] [--output-format FMT] [--password PASS]
635
- [--plugin-registry-catalog FILE]
636
- [--plugin-set-catalog FILE]
637
- [--plugin-signing-credentials FILE]
638
- [--production] [--testing] [--identifier PLUGID]
639
- [--identifiers FILE] [--layer LAYER]
640
- [--layers FILE]
641
- [PLUGID ...]
642
-
643
- turtles usage [-h]
644
-
645
- turtles version [-h]
646
-
647
- Commands
648
- ========
649
-
650
- The available commands are:
651
-
652
- ================= ============ =======
653
- Command Abbreviation Purpose
654
- ================= ============ =======
655
- `build-plugin`_ bp build (package and sign) plugins
656
- `copyright`_ show copyright and exit
657
- `deploy-plugin`_ dp deploy plugins
658
- `license`_ show license and exit
659
- `release-plugin`_ rp release (build and deploy) plugins
660
- `usage`_ show detailed usage and exit
661
- `version`_ show version and exit
662
- ================= ============ =======
663
-
664
- Top-Level Program
665
- -----------------
666
-
667
- The top-level executable alone does not perform any action or default to a given command. It does define a few options, which you can see by invoking Turtles with the |HELP| option::
668
-
669
- usage: turtles [-h] [--debug-cli] [--non-interactive] COMMAND ...
670
-
671
- options:
672
- -h, --help show this help message and exit
673
- --debug-cli print the result of parsing command line arguments
674
- --non-interactive, -n
675
- disallow interactive prompts (default: allow)
676
-
677
- commands:
678
- Add --help to see the command's own help message.
679
-
680
- COMMAND DESCRIPTION
681
- build-plugin (bp) build (package and sign) plugins
682
- copyright show copyright and exit
683
- deploy-plugin (dp) deploy plugins
684
- license show license and exit
685
- release-plugin (rp)
686
- release (build and deploy) plugins
687
- usage show detailed usage and exit
688
- version show version and exit
689
-
690
- .. _build-plugin:
691
-
692
- ``build-plugin`` (``bp``)
693
- -------------------------
694
-
695
- The ``build-plugin`` command is used for `Building Plugins`_. It has its own |HELP| option::
696
-
697
- usage: turtles build-plugin [-h] [--output-format FMT] [--password PASS]
698
- [--plugin-set-catalog FILE]
699
- [--plugin-signing-credentials FILE]
700
- [--identifier PLUGID] [--identifiers FILE]
701
- [PLUGID ...]
702
-
703
- Build (package and sign) plugins.
704
-
705
- options:
706
- -h, --help show this help message and exit
707
- --output-format FMT set tabular output format to FMT (default: simple;
708
- choices: asciidoc, double_grid, double_outline,
709
- fancy_grid, fancy_outline, github, grid, heavy_grid,
710
- heavy_outline, html, jira, latex, latex_booktabs,
711
- latex_longtable, latex_raw, mediawiki, mixed_grid,
712
- mixed_outline, moinmoin, orgtbl, outline, pipe, plain,
713
- presto, pretty, psql, rounded_grid, rounded_outline,
714
- rst, simple, simple_grid, simple_outline, textile,
715
- tsv, unsafehtml, youtrack)
716
- --password PASS set the plugin signing password
717
- --plugin-set-catalog FILE, -s FILE
718
- load plugin set catalog from FILE (default:
719
- $HOME/.config/lockss.turtles/plugin-set-
720
- catalog.yaml or
721
- /usr/local/share/lockss.turtles/plugin-set-
722
- catalog.yaml or /etc/lockss.turtles/plugin-set-
723
- catalog.yaml)
724
- --plugin-signing-credentials FILE, -c FILE
725
- load plugin signing credentials from FILE (default:
726
- $HOME/.config/lockss.turtles/plugin-signing-
727
- credentials.yaml or
728
- /usr/local/share/lockss.turtles/plugin-signing-
729
- credentials.yaml or /etc/lockss.turtles/plugin-
730
- signing-credentials.yaml)
731
-
732
- plugin identifier arguments and options:
733
- --identifier PLUGID, -i PLUGID
734
- add PLUGID to the list of plugin identifiers to build
735
- --identifiers FILE, -I FILE
736
- add the plugin identifiers in FILE to the list of
737
- plugin identifiers to build
738
- PLUGID plugin identifier to build
739
-
740
- The command needs:
741
-
742
- * `Plugin Signing Credentials`_, either from the |PLUGIN_SIGNING_CREDENTIALS| option or from ``plugin-signing-credentials.yaml`` in the `Configuration Files`_.
743
-
744
- * A `Plugin Set Catalog`_, either from the |PLUGIN_SET_CATALOG| option or from ``plugin-set-catalog.yaml`` in the `Configuration Files`_.
745
-
746
- * One or more plugin identifiers, from the `Plugin Identifier Arguments and Options`_ (bare arguments, |IDENTIFIER| options, |IDENTIFIERS| options).
747
-
748
- It also accepts `Options`_ for `Output Format Control`_
749
-
750
- Examples::
751
-
752
- # Help message
753
- turtles build-plugin --help
754
- # Abbreviation
755
- turtles bp -h
756
-
757
- # List of plugin identifiers
758
- turtles build-plugin edu.myuniversity.plugin.publisherx.PublisherXPlugin edu.myuniversity.plugin.publishery.PublisherYPlugin ...
759
- # Abbreviation
760
- turtles bp edu.myuniversity.plugin.publisherx.PublisherXPlugin edu.myuniversity.plugin.publishery.PublisherYPlugin ...
761
-
762
- # Alternative invocation
763
- turtles build-plugin --identifier=edu.myuniversity.plugin.publisherx.PublisherXPlugin --identifier=edu.myuniversity.plugin.publishery.PublisherYPlugin ...
764
- # Abbreviation
765
- turtles bp -i edu.myuniversity.plugin.publisherx.PublisherXPlugin -i edu.myuniversity.plugin.publishery.PublisherYPlugin ...
766
-
767
- # Alternative invocation
768
- # /tmp/pluginids.txt has one plugin identifier per line
769
- turtles build-plugin --identifiers=/tmp/pluginids.txt
770
- # Abbreviation
771
- turtles bp -I /tmp/pluginids.txt
772
-
773
- .. _copyright:
774
-
775
- ``copyright``
776
- -------------
777
-
778
- The ``copyright`` command displays the copyright notice for Turtles and exits.
779
-
780
- .. _deploy-plugin:
781
-
782
- ``deploy-plugin`` (``dp``)
783
- --------------------------
784
-
785
- The ``deploy-plugin`` command is used for `Deploying Plugins`_. It has its own |HELP| option::
786
-
787
- usage: turtles deploy-plugin [-h] [--output-format FMT]
788
- [--plugin-registry-catalog FILE] [--production]
789
- [--testing] [--jar PLUGJAR] [--jars FILE]
790
- [--layer LAYER] [--layers FILE]
791
- [PLUGJAR ...]
792
-
793
- Deploy plugins.
794
-
795
- options:
796
- -h, --help show this help message and exit
797
- --output-format FMT set tabular output format to FMT (default: simple;
798
- choices: asciidoc, double_grid, double_outline,
799
- fancy_grid, fancy_outline, github, grid, heavy_grid,
800
- heavy_outline, html, jira, latex, latex_booktabs,
801
- latex_longtable, latex_raw, mediawiki, mixed_grid,
802
- mixed_outline, moinmoin, orgtbl, outline, pipe, plain,
803
- presto, pretty, psql, rounded_grid, rounded_outline,
804
- rst, simple, simple_grid, simple_outline, textile,
805
- tsv, unsafehtml, youtrack)
806
- --plugin-registry-catalog FILE, -r FILE
807
- load plugin registry catalog from FILE (default:
808
- $HOME/.config/lockss.turtles/plugin-registry-
809
- catalog.yaml or
810
- /usr/local/share/lockss.turtles/plugin-registry-
811
- catalog.yaml or /etc/lockss.turtles/plugin-registry-
812
- catalog.yaml)
813
- --production, -p synonym for --layer=production (i.e. add 'production'
814
- to the list of plugin registry layers to process)
815
- --testing, -t synonym for --layer=testing (i.e. add 'testing' to the
816
- list of plugin registry layers to process)
817
-
818
- plugin JAR arguments and options:
819
- --jar PLUGJAR, -j PLUGJAR
820
- add PLUGJAR to the list of plugin JARs to deploy
821
- --jars FILE, -J FILE add the plugin JARs in FILE to the list of plugin JARs
822
- to deploy
823
- PLUGJAR plugin JAR to deploy
824
-
825
- plugin registry layer options:
826
- --layer LAYER, -l LAYER
827
- add LAYER to the list of plugin registry layers to
828
- process
829
- --layers FILE, -L FILE
830
- add the layers in FILE to the list of plugin registry
831
- layers to process
832
-
833
- The command needs:
834
-
835
- * A `Plugin Registry Catalog`_, either from the |PLUGIN_REGISTRY_CATALOG| option or from ``plugin-signing-credentials.yaml`` in the `Configuration Files`_.
836
-
837
- * One or more plugin registry layer IDs, from the `Plugin Registry Layer Options`_ (|LAYER| options, |LAYERS| options, and alternatively, |TESTING| options, |PRODUCTION| option).
838
-
839
- * One or more JAR paths. The list of JAR paths to process is derived from:
840
-
841
- * The JAR paths listed as bare arguments to the command.
842
-
843
- * The JAR paths listed as |JAR| options.
844
-
845
- * The JAR paths found in the files listed as |JARS| options.
846
-
847
- It also accepts `Options`_ for `Output Format Control`_.
848
-
849
- Examples::
850
-
851
- # Help message
852
- turtles deploy-plugin --help
853
- # Abbreviation
854
- turtles dp -h
855
-
856
- # List of JARs
857
- # Deploy to 'testing' layer only
858
- turtles deploy-plugin --testing /path/to/edu.myuniversity.plugin.publisherx.PublisherXPlugin.jar /path/to/edu.myuniversity.plugin.publishery.PublisherYPlugin.jar ...
859
- # Abbreviation
860
- turtles dp -t /path/to/edu.myuniversity.plugin.publisherx.PublisherXPlugin.jar /path/to/edu.myuniversity.plugin.publishery.PublisherYPlugin.jar ...
861
-
862
- # Alternative invocation
863
- # Deploy to 'production' layer only
864
- turtles deploy-plugin --production --jar=/path/to/edu.myuniversity.plugin.publisherx.PublisherXPlugin.jar --jar=/path/to/edu.myuniversity.plugin.publishery.PublisherYPlugin.jar ...
865
- # Abbreviation
866
- turtles dp -p -j /path/to/edu.myuniversity.plugin.publisherx.PublisherXPlugin.jar -j /path/to/edu.myuniversity.plugin.publishery.PublisherYPlugin.jar ...
867
-
868
- # Alternative invocation
869
- # /tmp/pluginjars.txt has one JAR path per line
870
- # Deploy to both 'testing' and 'production' layers
871
- turtles deploy-plugin --testing --production --jars=/tmp/pluginjars.txt
872
- # Abbreviation
873
- turtles bp -tp -J /tmp/pluginids.txt
874
-
875
- .. _license:
876
-
877
- ``license``
878
- -----------
879
-
880
- The ``license`` command displays the license terms for Turtles and exits.
881
-
882
- .. _release-plugin:
883
-
884
- ``release-plugin`` (``rp``)
885
- ---------------------------
886
-
887
- The ``release-plugin`` command is used for `Building Plugins`_ and `Deploying Plugins`_, being essentially `build-plugin`_ followed by `deploy-plugin`_. It has its own |HELP| option::
888
-
889
- usage: turtles release-plugin [-h] [--output-format FMT] [--password PASS]
890
- [--plugin-registry-catalog FILE]
891
- [--plugin-set-catalog FILE]
892
- [--plugin-signing-credentials FILE]
893
- [--production] [--testing] [--identifier PLUGID]
894
- [--identifiers FILE] [--layer LAYER]
895
- [--layers FILE]
896
- [PLUGID ...]
897
-
898
- Release (build and deploy) plugins.
899
-
900
- options:
901
- -h, --help show this help message and exit
902
- --output-format FMT set tabular output format to FMT (default: simple;
903
- choices: asciidoc, double_grid, double_outline,
904
- fancy_grid, fancy_outline, github, grid, heavy_grid,
905
- heavy_outline, html, jira, latex, latex_booktabs,
906
- latex_longtable, latex_raw, mediawiki, mixed_grid,
907
- mixed_outline, moinmoin, orgtbl, outline, pipe, plain,
908
- presto, pretty, psql, rounded_grid, rounded_outline,
909
- rst, simple, simple_grid, simple_outline, textile,
910
- tsv, unsafehtml, youtrack)
911
- --password PASS set the plugin signing password
912
- --plugin-registry-catalog FILE, -r FILE
913
- load plugin registry catalog from FILE (default:
914
- $HOME/.config/lockss.turtles/plugin-registry-
915
- catalog.yaml or
916
- /usr/local/share/lockss.turtles/plugin-registry-
917
- catalog.yaml or /etc/lockss.turtles/plugin-registry-
918
- catalog.yaml)
919
- --plugin-set-catalog FILE, -s FILE
920
- load plugin set catalog from FILE (default:
921
- $HOME/.config/lockss.turtles/plugin-set-
922
- catalog.yaml or
923
- /usr/local/share/lockss.turtles/plugin-set-
924
- catalog.yaml or /etc/lockss.turtles/plugin-set-
925
- catalog.yaml)
926
- --plugin-signing-credentials FILE, -c FILE
927
- load plugin signing credentials from FILE (default:
928
- $HOME/.config/lockss.turtles/plugin-signing-
929
- credentials.yaml or
930
- /usr/local/share/lockss.turtles/plugin-signing-
931
- credentials.yaml or /etc/lockss.turtles/plugin-
932
- signing-credentials.yaml)
933
- --production, -p synonym for --layer=production (i.e. add 'production'
934
- to the list of plugin registry layers to process)
935
- --testing, -t synonym for --layer=testing (i.e. add 'testing' to the
936
- list of plugin registry layers to process)
937
-
938
- plugin identifier arguments and options:
939
- --identifier PLUGID, -i PLUGID
940
- add PLUGID to the list of plugin identifiers to build
941
- --identifiers FILE, -I FILE
942
- add the plugin identifiers in FILE to the list of
943
- plugin identifiers to build
944
- PLUGID plugin identifier to build
945
-
946
- plugin registry layer options:
947
- --layer LAYER, -l LAYER
948
- add LAYER to the list of plugin registry layers to
949
- process
950
- --layers FILE, -L FILE
951
- add the layers in FILE to the list of plugin registry
952
- layers to process
953
-
954
- The command needs:
955
-
956
- * `Plugin Signing Credentials`_, either from the |PLUGIN_SIGNING_CREDENTIALS| option or from ``plugin-signing-credentials.yaml`` in the `Configuration Files`_.
957
-
958
- * A `Plugin Set Catalog`_, either from the |PLUGIN_SET_CATALOG| option or from ``plugin-set-catalog.yaml`` in the `Configuration Files`_.
959
-
960
- * A `Plugin Registry Catalog`_, either from the |PLUGIN_REGISTRY_CATALOG| option or from ``plugin-signing-credentials.yaml`` in the `Configuration Files`_.
961
-
962
- * One or more plugin registry layer IDs, from the `Plugin Registry Layer Options`_ (|IDENTIFIER| options, |IDENTIFIERS| options, and alternatively, |TESTING| options, |PRODUCTION| option).
963
-
964
- * One or more plugin identifiers, from the `Plugin Identifier Arguments and Options`_ (bare arguments, |IDENTIFIER| options, |IDENTIFIERS| options).
965
-
966
- It also accepts `Options`_ for `Output Format Control`_.
967
-
968
- Examples::
969
-
970
- # Help message
971
- turtles release-plugin --help
972
- # Abbreviation
973
- turtles rp -h
974
-
975
- # List of plugin identifiers
976
- # Deploy to 'testing' layer only
977
- turtles release-plugin --testing edu.myuniversity.plugin.publisherx.PublisherXPlugin edu.myuniversity.plugin.publishery.PublisherYPlugin ...
978
- # Abbreviation
979
- turtles rp -t edu.myuniversity.plugin.publisherx.PublisherXPlugin edu.myuniversity.plugin.publishery.PublisherYPlugin ...
980
-
981
- # Alternative invocation
982
- # Deploy to 'production' layer only
983
- turtles release-plugin --production --identifier=edu.myuniversity.plugin.publisherx.PublisherXPlugin --identifier=edu.myuniversity.plugin.publishery.PublisherYPlugin ...
984
- # Abbreviation
985
- turtles rp -p -i edu.myuniversity.plugin.publisherx.PublisherXPlugin -i edu.myuniversity.plugin.publishery.PublisherYPlugin ...
986
-
987
- # Alternative invocation
988
- # /tmp/pluginids.txt has one plugin identifier per line
989
- # Deploy to both 'testing' and 'production' layers
990
- turtles release-plugin --testing --production --identifiers=/tmp/pluginids.txt
991
- # Abbreviation
992
- turtles rp -tp -I /tmp/pluginids.txt
993
-
994
- .. _usage:
995
-
996
- ``usage``
997
- ---------
998
-
999
- The ``usage`` command displays the usage message of all the Turtles `Commands`_.
1000
-
1001
- .. _version:
1002
-
1003
- ``version``
1004
- -----------
1005
-
1006
- The ``version`` command displays the version number of Turtles and exits.
1007
-
1008
- Options
1009
- =======
1010
-
1011
- Plugin Identifier Arguments and Options
1012
- ---------------------------------------
1013
-
1014
- Commands that are `Building Plugins`_ expect one or more plugin identifiers. The list of plugin identifiers to process is derived from:
1015
-
1016
- * The plugin identifiers listed as bare arguments to the command.
1017
-
1018
- * The plugin identifiers listed as |IDENTIFIER| options.
1019
-
1020
- * The plugin identifiers found in the files listed as |IDENTIFIERS| options.
1021
-
1022
- Plugin Registry Layer Options
1023
- -----------------------------
1024
-
1025
- Commands that are `Deploying Plugins`_ expect one or more plugin registry layer IDs. The list of plugin registry layer IDs to target is derived from:
1026
-
1027
- * The plugin registry layer IDs listed as |LAYER| options.
1028
-
1029
- * The plugin registry layer IDs found in the files listed as |LAYERS| options.
1030
-
1031
- As a convenience, the following synonyms also exist:
1032
-
1033
- * |TESTING| is a synonym for ``--layer=testing``
1034
-
1035
- * |PRODUCTION| is a synonym for ``--layer=production``
1036
-
1037
- Output Format Control
1038
- ---------------------
1039
-
1040
- Turtles' tabular output is performed by the `tabulate <https://pypi.org/project/tabulate>`_ library through the ``--output-format`` option. See its PyPI page for a visual reference of the various output formats available. The **default** is ``simple``.
1041
-