No way for update arguments via IMAGES_HOOK anymore
See original GitHub issueDescription
Since 5.6
we have nice locking mechanism. But all new images created with LOCKING enabled.
So if you have some hook which adds some custom parameters to creating images, it will not work anymore.
IMAGE_HOOK
supports only CREATE
and DELETE
operations, no way to call it after image is READY
To Reproduce
- Write hook for adding specific label to the image:
#!/bin/sh
EDITOR="echo LABELS=mylabel >" oneimage update --append $1
- Install hook in
oned.conf
:
IMAGE_HOOK = [
name = "add_label",
on = "CREATE",
command = "add_label.sh",
arguments = "$ID" ]
- Upload new image, alpine for example:
http://dl-cdn.alpinelinux.org/alpine/v3.8/releases/x86_64/alpine-standard-3.8.1-x86_64.iso
- In logs you will see error
[Z0][ImM][I]: Copying http://dl-cdn.alpinelinux.org/alpine/v3.8/releases/x86_64/alpine-standard-3.8.1-x86_64.iso to repository for image 1440
[Z0][ReM][E]: Req:6704 UID:0 one.image.update result FAILURE [one.image.update] User [0] : IMAGE is locked. [1440].
Expected behavior Attached label to the image
Details
- Affected Component: Core
- Hypervisor: KVM
- Version: 5.6.0
Progress Status
- Branch created
- Code committed to development branch
- Testing - QA
- Documentation
- Release notes - resolved issues, compatibility, known issues
- Code committed to upstream release/hotfix branches
- Documentation committed to upstream release/hotfix branches
Issue Analytics
- State:
- Created 5 years ago
- Comments:8 (8 by maintainers)
Top Results From Across the Web
Using function arguments in update.formula - Stack Overflow
I'd prefer to do this using update.formula() , but of course update.formula(controls, x ~ .) and update.formula(controls, as.name(x) ~ .) don't ...
Read more >Petition · End Forced Pelvic Exams in Connecticut · Change.org
Please note that this petition contains clarifications to the original text. Imagine needing surgery. You would worry about a lot of things.
Read more >Creating Public Texts - EdTech Books
sarcastic, but your audience may not read it that way. It's much ... position's best argument, which is then knocked down by the...
Read more >Upgrade Guide from v1 to v2 — Chainer 7.8.1 documentation
This train/test argument has been removed in Chainer v2. If your code is using the train or test argument, you have to update...
Read more >An history of apparitions, oracles, prophecies, and predictions ...
The event did give credit to the Oracle; for the Gardi being ta∣ken by Cyrus, ... and those that were sent enquiring for...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
For now I use:
as workaround, in my hook it is working fine
Same problem when importing an image issue #2292