Hi,
I have created custom image in private repo. How to pull and rebase with authentication? I put ‘/etc/ostree/auth.json’ with login and password to Github but access is still “403 forbidden”.
rpm-ostree rebase ostree-unverified-registry:ghcr.io.....path_to_private_repo
Solved. Thank you.
Short manaul for others:
- Generate private classic token just to read packages
- generate base46 from: username:privatetoken
- create
/etc/ostree/auth.json
file
- put authentication credentials there:
{
"auths": {
"ghcr.io": {
"auth": "base64generatedcode"
}
}
}
- Save the file
- run the rebase command:
rpm-ostree rebase ostree-unverified-registry:ghcr.io ..... path_to_private_repo
- and do other rebase tasks if needed
2 Likes
Custom Bluebuild image cannot be signed:
rpm-ostree rebase ostree-unverified-registry:ghcr.io......
works
rpm-ostree rebase ostree-image-signed:docker://ghcr.io.....
does not.
error:
Creating importer: Failed to invoke skopeo proxy method OpenImage: remote error: Running image docker://ghcr.io/...... is rejected by policy.
I thought I should add another scope on token generation page read:public_key
alongside read:packages
but it doesn’t help.
What’s the solution?