Skip to content

Commit c838279

Browse files
author
Cristy
committed
...
1 parent 0e10e46 commit c838279

1 file changed

Lines changed: 6 additions & 4 deletions

File tree

README.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,11 @@ You will require a place to store and retrieve your content. Let's create a cac
1919
$ magick-cache -passkey passkey.txt create /opt/magick-cache
2020
```
2121

22-
Where `passkey.txt` contains your cache passkey. Don't forget your passkey. Without it, you will be unable to identify, expire, or delete content in your cache.
22+
Where `passkey.txt` contains your cache passkey. Don't lose your passkey. Without it, you will be unable to identify, expire, or delete content in your cache.
2323

24-
Once its created, you will want to populate the cache with content that includes images, video, audio, or metadata.
24+
You only need to create a MagickCache once. You can, however, create more than one MagickCache with different paths.
25+
26+
Once the MagickCache is created, you will want to populate the cache with content that includes images, video, audio, or metadata.
2527

2628
## Put content in the MagickCache
2729

@@ -31,15 +33,15 @@ Let's add a movie cast image to our newly created cache:</p>
3133
$ magick-cache put /opt/magick-cache movies/image/mission-impossible/cast/rebecca-ferguson 20210508-rebecca-ferguson.jpg
3234
```
3335

34-
Note, the image identifier is an IRI composed of `project/type/resource-path`. In this example, the project is `movies`, type is `image`, and the resource path is `mission-impossible/cast/rebecca-ferguson`. The path uniquely identifies a resource. Two different images cannot be stored with the same resource path. Instead use something like `mission-impossible/cast/20210508-rebecca-ferguson-1` and `mission-impossible/cast/20210508-rebecca-ferguson-2`.
36+
Note, the image identifier is an IRI composed of `project/type/resource-path`. In this example, the project is `movies`, type is `image`, and the resource path is `mission-impossible/cast/rebecca-ferguson`. The path uniquely identifies a cache resource. Two different images cannot be stored with the same resource path. Instead use something like `mission-impossible/cast/20210508-rebecca-ferguson-1` and `mission-impossible/cast/20210508-rebecca-ferguson-2`.
3537

3638
Now, let's set a resource passkey and the time to live to 2 days. Anytime after the second day, the image is automatically deleted with the `expire` function. To get, expire, or delete the image, you will need to use the same resource passkey:
3739

3840
```
3941
$ magick-cache -passkey passkey.txt -ttl "2 days" put /opt/magick-cache movies/image/mission-impossible/cast/rebecca-ferguson 20210508-rebecca-ferguson.jpg
4042
```
4143

42-
Where `passkey.txt` contains your resource key. Don't forget your resource passkey. Without it, you will be unable to get, identify, expire, or delete your content.
44+
Where `passkey.txt` contains your resource key. Don't lose your resource passkey. Without it, you will be unable to get, identify, expire, or delete resource you own.
4345

4446
The resource passkey ensures only you and the cache owner can access your image. To prevent the cache owner from viewing its content, scramble it with:
4547

0 commit comments

Comments
 (0)