Update README.md with current documentation

This commit is contained in:
Anthony Oteri
2023-09-21 16:33:18 -04:00
parent 9a7cb368f9
commit 41ddcb1f5d
2 changed files with 83 additions and 27 deletions
+82 -25
View File
@@ -2,41 +2,98 @@
Dredge is a command line tool for working with the Docker Registry V2 API.
## Configuration
Dredge is configured using a simple TOML based configuration file format.
By default, it will look in the default configuration location for your
operating system i.e. on Linux this is `~/.config/dredge/dredge.toml`.
You may also override the configuration file at the command line with the
`-c` or `--config` argument. The supplied argument must refer to an
existing file.
The format of the configuration file is simple, and contains only the
base URL for the registry server.
```toml
registry_url = "https://localhost:5000"
```
If Dredge is run without a configuration file present, one will be created
with the default configuration shown above.
## Usage
```shell
Dredge is a command line tool for working with the Docker Registry V2 API.
Usage: dredge [OPTIONS] <REGISTRY> <COMMAND>
Commands:
catalog Fetch the list of available repositories from the catalog
tags Fetch the list of tags for a given image
show Show detailed information about a particular image
delete Delete a tagged image from the registry
check Perform a simple API Version check towards the configured registry endpoint
help Print this message or the help of the given subcommand(s)
Arguments:
<REGISTRY>
The host or host:port or full base URL of the Docker Registry
Options:
--log-level[=<LEVEL>]
[default: info]
[possible values: trace, debug, info, warn, error, off]
-h, --help
Print help (see a summary with '-h')
-V, --version
Print version
```
### Checking the API Version
Performs a simple API version check.
Perform a simple API Version check towards the registry endpoint
```sh
dredge check
Usage: dredge <REGISTRY> check
Options:
-h, --help Print help
```
### Fetch Repository List
Fetch a sorted list of available repository names from the Registry's
catalog.
Fetch the list of available repositories from the catalog
```sh
dredge catalog
Usage: dredge <REGISTRY> catalog
Options:
-h, --help Print help
```
### Listing tags for an image
Fetch the list of tags for a given image
```shell
Usage: dredge <REGISTRY> tags <NAME>
Arguments:
<NAME>
Options:
-h, --help Print help
```
### Viewing details of a tagged image
Show detailed information about a particular image
```shell
Usage: dredge <REGISTRY> show <IMAGE> [TAG]
Arguments:
<IMAGE>
[TAG]
Options:
-h, --help Print help
```
### Deleteing a tagged image
Delete a tagged image from the registry
```shell
Usage: dredge <REGISTRY> delete <IMAGE> <TAG>
Arguments:
<IMAGE>
<TAG>
Options:
-h, --help Print help
```
+1 -2
View File
@@ -92,7 +92,6 @@ pub enum Commands {
#[command(arg_required_else_help = true)]
Delete { image: String, tag: String },
/// Perform a simple API Version check towards the configured registry
/// endpoint.
/// Perform a simple version check towards the Docker Registry API
Check,
}