Skip to content

Commit 76e60e1

Browse files
committed
Link fixes
Signed-off-by: Steve Lasker <[email protected]>
1 parent cf2d5f0 commit 76e60e1

File tree

2 files changed

+58
-5
lines changed

2 files changed

+58
-5
lines changed

articles/container-registry/container-registry-oci-artifacts.md

Lines changed: 57 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ To demonstrate this capability, this article shows how to use the [OCI Registry
1919
* **Azure container registry** - Create a container registry in your Azure subscription. For example, use the [Azure portal](container-registry-get-started-portal.md) or the [Azure CLI](container-registry-get-started-azure-cli.md).
2020
* **Azure CLI** - Version `2.29.1` or later is recommended. Run `az --version `to find the required. If you need to install or upgrade, see [Install Azure CLI](/cli/azure/install-azure-cli).
2121
* **ORAS CLI** - Download and install the ORAS CLI `v0.16.0` for your operating system from the [ORAS installation guide](https://oras.land/cli/).
22+
* **Docker** - ORAS leverages the Docker desktop credential store for authentication. You can use [Docker installed locally][docker-install] to build and push a container image, reference an existing container image or use [ACR Build][az-acr-build] to build remotely, in Azure.
2223

2324
## Configure a registry
2425

@@ -104,11 +105,16 @@ Digest: sha256:e2d60d1b171f08bd10e2ed171d56092e39c7bac1aec5d9dcf7748dd702682d53
104105

105106
## Push a multi-file root artifact
106107

108+
When OCI artifacts are pushed to a registry with ORAS, each file reference is pushed as a blob. To push separate blobs, reference the files individually, or collection of files by referencing a directory.
109+
For more information how to push a collection of files, see [Pushing artifacts with multiple files][oras-push-multifiles]
110+
107111
Create some documentation around an artifact.
108112

109113
```bash
110114
echo 'Readme Content' > readme.md
111-
echo 'Detailed Content' > readme-details.md
115+
mkdir details/
116+
echo 'Detailed Content' > details/readme-details.md
117+
echo 'More detailed Content' > details/readme-more-details.md
112118
```
113119

114120
Attach the multi-file artifact as a reference.
@@ -119,7 +125,7 @@ Attach the multi-file artifact as a reference.
119125
oras push $REGISTRY/samples/artifact:readme \
120126
--config /dev/null:readme/example\
121127
./readme.md:application/markdown\
122-
./readme-details.md:application/markdown
128+
./details
123129
```
124130

125131
**Windows**
@@ -128,7 +134,52 @@ oras push $REGISTRY/samples/artifact:readme \
128134
.\oras.exe push $REGISTRY/samples/artifact:readme ^
129135
--config NUL:readme/example ^
130136
.\readme.md:application/markdown ^
131-
.\readme-details.md:application/markdown
137+
.\details
138+
```
139+
140+
## Discover the manifest
141+
142+
To view the manifest created as a result of `oras push`, use `oras manifest fetch`:
143+
144+
```bash
145+
oras manifest fetch --pretty $REGISTRY/samples/artifact:readme
146+
```
147+
148+
The output will be similar to:
149+
150+
```json
151+
{
152+
"schemaVersion": 2,
153+
"mediaType": "application/vnd.oci.image.manifest.v1+json",
154+
"config": {
155+
"mediaType": "readme/example",
156+
"digest": "sha256:e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
157+
"size": 0
158+
},
159+
"layers": [
160+
{
161+
"mediaType": "application/markdown",
162+
"digest": "sha256:2fdeac43552b71eb9db534137714c7bad86b53a93c56ca96d4850c9b41b777fc",
163+
"size": 15,
164+
"annotations": {
165+
"org.opencontainers.image.title": "readme.md"
166+
}
167+
},
168+
{
169+
"mediaType": "application/vnd.oci.image.layer.v1.tar+gzip",
170+
"digest": "sha256:089111d738bd4b883c88ab9bdd7b8d5eba18e9a448d6d8f428b94de140f4f492",
171+
"size": 191,
172+
"annotations": {
173+
"io.deis.oras.content.digest": "sha256:1dd2737c1078e36bbd8128712dbf2b0d41ef1abefb954bb5219c5e1096ac8b6a",
174+
"io.deis.oras.content.unpack": "true",
175+
"org.opencontainers.image.title": "details"
176+
}
177+
}
178+
],
179+
"annotations": {
180+
"org.opencontainers.image.created": "2023-01-06T20:07:15Z"
181+
}
182+
}
132183
```
133184

134185
## Pull a root artifact
@@ -149,6 +200,7 @@ oras pull -o ./download $REGISTRY/samples/artifact:readme
149200

150201
```bash
151202
ls ./download
203+
ls ./download/details
152204
```
153205

154206
## Remove the artifact (optional)
@@ -169,9 +221,10 @@ az acr repository delete \
169221

170222
<!-- LINKS - external -->
171223
[iana-mediatypes]: https://www.rfc-editor.org/rfc/rfc6838
224+
[oras-push-multifiles]: https://oras.land/cli/1_pushing/#pushing-artifacts-with-multiple-files
172225
<!-- LINKS - internal -->
173226
[acr-landing]: https://aka.ms/acr
174-
[acr-authentication]: /azure/container-registry/container-registry-authentication.md?tabs=azure-cli
227+
[acr-authentication]: /azure/container-registry/container-registry-authentication?tabs=azure-cli
175228
[az-acr-create]: /container-registry/container-registry-get-started-azure-cli
176229
[az-acr-repository-show]: /cli/azure/acr/repository?#az_acr_repository_show
177230
[az-acr-repository-delete]: /cli/azure/acr/repository#az_acr_repository_delete

articles/container-registry/container-registry-oras-artifacts.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -317,7 +317,7 @@ az acr manifest list-metadata \
317317
[oci-1_1-spec]: https://github.com/opencontainers/distribution-spec/releases/tag/v1.1.0-rc1
318318

319319
<!-- LINKS - internal -->
320-
[acr-authentication]: /azure/container-registry/container-registry-authentication.md?tabs=azure-cli
320+
[acr-authentication]: /azure/container-registry/container-registry-authentication?tabs=azure-cli
321321
[az-acr-create]: /container-registry/container-registry-get-started-azure-cli
322322
[az-acr-build]: /cli/azure/acr#az_acr_build
323323
[az-acr-repository-show]: /cli/azure/acr/repository?#az_acr_repository_show

0 commit comments

Comments
 (0)