2024-10-26 12:07:57 +02:00
|
|
|
# crane mutate
|
|
|
|
|
|
|
|
> Wijzig image-labels en annotaties.
|
|
|
|
> De container moet naar een registry worden gepusht, en het manifest wordt daar bijgewerkt.
|
|
|
|
> Meer informatie: <https://github.com/google/go-containerregistry/blob/main/cmd/crane/doc/crane_mutate.md>.
|
|
|
|
|
|
|
|
- Nieuwe annotaties om in te stellen (standaard []):
|
|
|
|
|
2025-03-14 09:18:08 +02:00
|
|
|
`crane mutate {{[-a|--annotation]}}/{{[-l|--label]}} {{annotation/label}}`
|
2024-10-26 12:07:57 +02:00
|
|
|
|
|
|
|
- Pad naar tarball/opdracht/entrypoint/omgeving variabele/exposed-ports om aan de image toe te voegen:
|
|
|
|
|
2025-03-14 09:18:08 +02:00
|
|
|
`crane mutate {{--append}}/{{--cmd}}/{{--entrypoint}}/{{[-e|--env]}}/{{--exposed-ports}} {{var1 var2 ...}}`
|
2024-10-26 12:07:57 +02:00
|
|
|
|
|
|
|
- Pad naar nieuwe tarball van de resulterende image:
|
|
|
|
|
2025-03-14 09:18:08 +02:00
|
|
|
`crane mutate {{[-o|--output]}} {{pad/naar/tarball}}`
|
2024-10-26 12:07:57 +02:00
|
|
|
|
|
|
|
- Repository in de vorm os/arch{{/variant}}{{:osversion}}{{,<platform>}} om de gewijzigde image te pushen:
|
|
|
|
|
|
|
|
`crane mutate --set-platform {{platform_naam}}`
|
|
|
|
|
|
|
|
- Nieuwe tagreferentie die moet worden toegepast op de gewijzigde image:
|
|
|
|
|
2025-03-14 09:18:08 +02:00
|
|
|
`crane mutate {{[-t|--tag]}} {{tag_naam}}`
|
2024-10-26 12:07:57 +02:00
|
|
|
|
|
|
|
- Nieuwe gebruiker in te stellen:
|
|
|
|
|
2025-03-14 09:18:08 +02:00
|
|
|
`crane mutate {{[-u|--user]}} {{gebruikersnaam}}`
|
2024-10-26 12:07:57 +02:00
|
|
|
|
|
|
|
- Nieuwe werk-map in te stellen:
|
|
|
|
|
2025-03-14 09:18:08 +02:00
|
|
|
`crane mutate {{[-w|--workdir]}} {{pad/naar/werk-map}}`
|
2024-10-26 12:07:57 +02:00
|
|
|
|
2025-01-11 19:47:43 +01:00
|
|
|
- Toon de help:
|
2024-10-26 12:07:57 +02:00
|
|
|
|
2025-03-14 09:18:08 +02:00
|
|
|
`crane mutate {{[-h|--help]}}`
|