|
Owen W. Taylor |
a55fbec |
From 0853089457a3e2ca343ea467dfc703bf99c416b9 Mon Sep 17 00:00:00 2001
|
|
Owen W. Taylor |
a55fbec |
From: "Owen W. Taylor" <otaylor@fishsoup.net>
|
|
Owen W. Taylor |
a55fbec |
Date: Thu, 6 Jul 2017 17:07:08 -0400
|
|
Owen W. Taylor |
a55fbec |
Subject: [PATCH] OCI: Update org.opencontainers.ref.name to
|
|
Owen W. Taylor |
a55fbec |
org.opencontainers.image.ref.name
|
|
Owen W. Taylor |
a55fbec |
|
|
Owen W. Taylor |
a55fbec |
This annotation was changed in later versions of the OCI Image specification.
|
|
Owen W. Taylor |
a55fbec |
(See https://github.com/projectatomic/skopeo/issues/369#issuecomment-310158211)
|
|
Owen W. Taylor |
a55fbec |
---
|
|
Owen W. Taylor |
a55fbec |
common/flatpak-json-oci.c | 10 +++++-----
|
|
Owen W. Taylor |
a55fbec |
1 file changed, 5 insertions(+), 5 deletions(-)
|
|
Owen W. Taylor |
a55fbec |
|
|
Owen W. Taylor |
a55fbec |
diff --git a/common/flatpak-json-oci.c b/common/flatpak-json-oci.c
|
|
Owen W. Taylor |
a55fbec |
index a64a0e0..718e0dc 100644
|
|
Owen W. Taylor |
a55fbec |
--- a/common/flatpak-json-oci.c
|
|
Owen W. Taylor |
a55fbec |
+++ b/common/flatpak-json-oci.c
|
|
Owen W. Taylor |
a55fbec |
@@ -426,7 +426,7 @@ flatpak_oci_index_add_manifest (FlatpakOciIndex *self,
|
|
Owen W. Taylor |
a55fbec |
int count;
|
|
Owen W. Taylor |
a55fbec |
|
|
Owen W. Taylor |
a55fbec |
if (desc->annotations != NULL)
|
|
Owen W. Taylor |
a55fbec |
- m_ref = g_hash_table_lookup (desc->annotations, "org.opencontainers.ref.name");
|
|
Owen W. Taylor |
a55fbec |
+ m_ref = g_hash_table_lookup (desc->annotations, "org.opencontainers.image.ref.name");
|
|
Owen W. Taylor |
a55fbec |
|
|
Owen W. Taylor |
a55fbec |
if (m_ref != NULL)
|
|
Owen W. Taylor |
a55fbec |
flatpak_oci_index_remove_manifest (self, m_ref);
|
|
Owen W. Taylor |
a55fbec |
@@ -449,7 +449,7 @@ flatpak_oci_manifest_descriptor_get_ref (FlatpakOciManifestDescriptor *m)
|
|
Owen W. Taylor |
a55fbec |
if (m->parent.annotations == NULL)
|
|
Owen W. Taylor |
a55fbec |
return NULL;
|
|
Owen W. Taylor |
a55fbec |
|
|
Owen W. Taylor |
a55fbec |
- return g_hash_table_lookup (m->parent.annotations, "org.opencontainers.ref.name");
|
|
Owen W. Taylor |
a55fbec |
+ return g_hash_table_lookup (m->parent.annotations, "org.opencontainers.image.ref.name");
|
|
Owen W. Taylor |
a55fbec |
}
|
|
Owen W. Taylor |
a55fbec |
|
|
Owen W. Taylor |
a55fbec |
static int
|
|
Owen W. Taylor |
a55fbec |
@@ -703,7 +703,7 @@ flatpak_oci_export_annotations (GHashTable *source,
|
|
Owen W. Taylor |
a55fbec |
GHashTable *dest)
|
|
Owen W. Taylor |
a55fbec |
{
|
|
Owen W. Taylor |
a55fbec |
const char *keys[] = {
|
|
Owen W. Taylor |
a55fbec |
- "org.opencontainers.ref.name",
|
|
Owen W. Taylor |
a55fbec |
+ "org.opencontainers.image.ref.name",
|
|
Owen W. Taylor |
a55fbec |
"org.flatpak.installed-size",
|
|
Owen W. Taylor |
a55fbec |
"org.flatpak.download-size",
|
|
Owen W. Taylor |
a55fbec |
"org.flatpak.metadata",
|
|
Owen W. Taylor |
a55fbec |
@@ -750,7 +750,7 @@ flatpak_oci_add_annotations_for_commit (GHashTable *annotations,
|
|
Owen W. Taylor |
a55fbec |
GVariant *commit_data)
|
|
Owen W. Taylor |
a55fbec |
{
|
|
Owen W. Taylor |
a55fbec |
if (ref)
|
|
Owen W. Taylor |
a55fbec |
- add_annotation (annotations,"org.opencontainers.ref.name", ref);
|
|
Owen W. Taylor |
a55fbec |
+ add_annotation (annotations,"org.opencontainers.image.ref.name", ref);
|
|
Owen W. Taylor |
a55fbec |
|
|
Owen W. Taylor |
a55fbec |
if (commit)
|
|
Owen W. Taylor |
a55fbec |
add_annotation (annotations,"org.flatpak.commit", commit);
|
|
Owen W. Taylor |
a55fbec |
@@ -809,7 +809,7 @@ flatpak_oci_parse_commit_annotations (GHashTable *annotations,
|
|
Owen W. Taylor |
a55fbec |
GHashTableIter iter;
|
|
Owen W. Taylor |
a55fbec |
gpointer _key, _value;
|
|
Owen W. Taylor |
a55fbec |
|
|
Owen W. Taylor |
a55fbec |
- oci_ref = g_hash_table_lookup (annotations, "org.opencontainers.ref.name");
|
|
Owen W. Taylor |
a55fbec |
+ oci_ref = g_hash_table_lookup (annotations, "org.opencontainers.image.ref.name");
|
|
Owen W. Taylor |
a55fbec |
if (oci_ref != NULL && out_ref != NULL && *out_ref == NULL)
|
|
Owen W. Taylor |
a55fbec |
*out_ref = g_strdup (oci_ref);
|
|
Owen W. Taylor |
a55fbec |
|
|
Owen W. Taylor |
a55fbec |
--
|
|
Owen W. Taylor |
a55fbec |
2.13.0
|
|
Owen W. Taylor |
a55fbec |
|