glance.api.authorization module

class glance.api.authorization.ImageFactoryProxy(image_factory, context)[source]

Bases: glance.domain.proxy.ImageFactory

new_image(**kwargs)[source]
class glance.api.authorization.ImageMemberFactoryProxy(image_member_factory, context)[source]

Bases: glance.domain.proxy.ImageMembershipFactory

new_image_member(image, member_id)[source]
class glance.api.authorization.ImageMemberProxy(image_member, context)[source]

Bases: glance.domain.proxy.ImageMember

class glance.api.authorization.ImageMemberRepoProxy(member_repo, image, context)[source]

Bases: glance.domain.proxy.MemberRepo

add(image_member)[source]
get(member_id)[source]
list(*args, **kwargs)[source]
remove(image_member)[source]
save(image_member, from_state=None)[source]
class glance.api.authorization.ImageProxy(image, context)[source]

Bases: glance.domain.proxy.Image

class glance.api.authorization.ImageRepoProxy(image_repo, context)[source]

Bases: glance.domain.proxy.Repo

get(image_id)[source]
list(*args, **kwargs)[source]
class glance.api.authorization.ImmutableImageProxy(base, context)[source]

Bases: object

property checksum
property container_format
property created_at
deactivate(*args, **kwargs)[source]
delete()[source]
property disk_format
property extra_properties
get_data(*args, **kwargs)[source]
property image_id
property locations
property min_disk
property min_ram
property name
property os_hash_algo
property os_hash_value
property os_hidden
property owner
property protected
reactivate(*args, **kwargs)[source]
set_data(*args, **kwargs)[source]
property size
property status
property tags
property updated_at
property virtual_size
property visibility
class glance.api.authorization.ImmutableLocations[source]

Bases: list

append(object) → None – append object to end
extend(iterable) → None – extend list by appending elements from the iterable
forbidden(*args, **kwargs)[source]
insert(*args, **kwargs)

L.insert(index, object) – insert object before index

pop([index]) → item – remove and return item at index (default last).

Raises IndexError if list is empty or index is out of range.

remove(value) → None – remove first occurrence of value.

Raises ValueError if the value is not present.

reverse(*args, **kwargs)

L.reverse() – reverse IN PLACE

sort(key=None, reverse=False) → None – stable sort *IN PLACE*
class glance.api.authorization.ImmutableMemberProxy(base)[source]

Bases: object

property created_at
property id
property image_id
property member_id
property status
property updated_at
class glance.api.authorization.ImmutableMetadefNamespaceProxy(base)[source]

Bases: object

property created_at
delete()[source]
property description
property display_name
property namespace
property namespace_id
property owner
property protected
save()[source]
property updated_at
property visibility
class glance.api.authorization.ImmutableMetadefObjectProxy(base)[source]

Bases: object

property created_at
delete()[source]
property description
property name
property object_id
property properties
property required
save()[source]
property updated_at
class glance.api.authorization.ImmutableMetadefPropertyProxy(base)[source]

Bases: object

delete()[source]
property name
property property_id
save()[source]
property schema
class glance.api.authorization.ImmutableMetadefResourceTypeProxy(base)[source]

Bases: object

property created_at
delete()[source]
property name
property namespace
property prefix
property properties_target
property updated_at
class glance.api.authorization.ImmutableMetadefTagProxy(base)[source]

Bases: object

property created_at
delete()[source]
property name
save()[source]
property tag_id
property updated_at
class glance.api.authorization.ImmutableProperties[source]

Bases: dict

forbidden(*args, **kwargs)[source]
forbidden_key(key, *args, **kwargs)[source]
pop(k[, d]) → v, remove specified key and return the corresponding value.

If key is not found, d is returned if given, otherwise KeyError is raised

popitem() → (k, v), remove and return some (key, value) pair as a

2-tuple; but raise KeyError if D is empty.

setdefault(k[, d]) → D.get(k,d), also set D[k]=d if k not in D
update([E, ]**F) → None. Update D from dict/iterable E and F.

If E is present and has a .keys() method, then does: for k in E: D[k] = E[k] If E is present and lacks a .keys() method, then does: for k, v in E: D[k] = v In either case, this is followed by: for k in F: D[k] = F[k]

class glance.api.authorization.ImmutableTags[source]

Bases: set

add(*args, **kwargs)

Add an element to a set.

This has no effect if the element is already present.

clear(*args, **kwargs)

Remove all elements from this set.

difference_update(*args, **kwargs)

Remove all elements of another set from this set.

forbidden(*args, **kwargs)[source]
intersection_update(*args, **kwargs)

Update a set with the intersection of itself and another.

pop(*args, **kwargs)

Remove and return an arbitrary set element. Raises KeyError if the set is empty.

remove(*args, **kwargs)

Remove an element from a set; it must be a member.

If the element is not a member, raise a KeyError.

symmetric_difference_update(*args, **kwargs)

Update a set with the symmetric difference of itself and another.

update(*args, **kwargs)

Update a set with the union of itself and others.

class glance.api.authorization.ImmutableTaskProxy(base)[source]

Bases: object

begin_processing()[source]
property created_at
property expires_at
fail(message)[source]
property input
property message
property owner
property result
run(executor)[source]
property status
succeed(result)[source]
property task_id
property type
property updated_at
class glance.api.authorization.ImmutableTaskStubProxy(base)[source]

Bases: object

property created_at
property expires_at
property owner
property status
property task_id
property type
property updated_at
class glance.api.authorization.MetadefNamespaceFactoryProxy(meta_namespace_factory, context)[source]

Bases: glance.domain.proxy.MetadefNamespaceFactory

new_namespace(**kwargs)[source]
class glance.api.authorization.MetadefNamespaceProxy(namespace)[source]

Bases: glance.domain.proxy.MetadefNamespace

class glance.api.authorization.MetadefNamespaceRepoProxy(namespace_repo, context)[source]

Bases: glance.domain.proxy.MetadefNamespaceRepo

get(namespace)[source]
list(*args, **kwargs)[source]
class glance.api.authorization.MetadefObjectFactoryProxy(meta_object_factory, context)[source]

Bases: glance.domain.proxy.MetadefObjectFactory

new_object(**kwargs)[source]
class glance.api.authorization.MetadefObjectProxy(meta_object)[source]

Bases: glance.domain.proxy.MetadefObject

class glance.api.authorization.MetadefObjectRepoProxy(object_repo, context)[source]

Bases: glance.domain.proxy.MetadefObjectRepo

get(namespace, object_name)[source]
list(*args, **kwargs)[source]
class glance.api.authorization.MetadefPropertyFactoryProxy(namespace_property_factory, context)[source]

Bases: glance.domain.proxy.MetadefPropertyFactory

new_namespace_property(**kwargs)[source]
class glance.api.authorization.MetadefPropertyProxy(namespace_property)[source]

Bases: glance.domain.proxy.MetadefProperty

class glance.api.authorization.MetadefPropertyRepoProxy(namespace_property_repo, context)[source]

Bases: glance.domain.proxy.MetadefPropertyRepo

get(namespace, object_name)[source]
list(*args, **kwargs)[source]
class glance.api.authorization.MetadefResourceTypeFactoryProxy(resource_type_factory, context)[source]

Bases: glance.domain.proxy.MetadefResourceTypeFactory

new_resource_type(**kwargs)[source]
class glance.api.authorization.MetadefResourceTypeProxy(meta_resource_type)[source]

Bases: glance.domain.proxy.MetadefResourceType

class glance.api.authorization.MetadefResourceTypeRepoProxy(meta_resource_type_repo, context)[source]

Bases: glance.domain.proxy.MetadefResourceTypeRepo

get(*args, **kwargs)[source]
list(*args, **kwargs)[source]
class glance.api.authorization.MetadefTagFactoryProxy(meta_tag_factory, context)[source]

Bases: glance.domain.proxy.MetadefTagFactory

new_tag(**kwargs)[source]
class glance.api.authorization.MetadefTagProxy(base)[source]

Bases: glance.domain.proxy.MetadefTag

class glance.api.authorization.MetadefTagRepoProxy(tag_repo, context)[source]

Bases: glance.domain.proxy.MetadefTagRepo

get(namespace, tag_name)[source]
list(*args, **kwargs)[source]
class glance.api.authorization.TaskFactoryProxy(task_factory, context)[source]

Bases: glance.domain.proxy.TaskFactory

new_task(**kwargs)[source]
class glance.api.authorization.TaskProxy(task)[source]

Bases: glance.domain.proxy.Task

class glance.api.authorization.TaskRepoProxy(task_repo, context)[source]

Bases: glance.domain.proxy.TaskRepo

get(task_id)[source]
class glance.api.authorization.TaskStubRepoProxy(task_stub_repo, context)[source]

Bases: glance.domain.proxy.TaskStubRepo

list(*args, **kwargs)[source]
glance.api.authorization.is_image_mutable(context, image)[source]

Return True if the image is mutable in this context.

glance.api.authorization.is_member_mutable(context, member)[source]

Return True if the image is mutable in this context.

glance.api.authorization.is_meta_resource_type_mutable(context, meta_resource_type)[source]

Return True if the meta_resource_type is mutable in this context.

glance.api.authorization.is_namespace_mutable(context, namespace)[source]

Return True if the namespace is mutable in this context.

glance.api.authorization.is_namespace_property_mutable(context, namespace_property)[source]

Return True if the object is mutable in this context.

glance.api.authorization.is_object_mutable(context, object)[source]

Return True if the object is mutable in this context.

glance.api.authorization.is_tag_mutable(context, tag)[source]

Return True if the tag is mutable in this context.

glance.api.authorization.is_task_mutable(context, task)[source]

Return True if the task is mutable in this context.

glance.api.authorization.is_task_stub_mutable(context, task_stub)[source]

Return True if the task stub is mutable in this context.

glance.api.authorization.lazy_update_store_info(func)[source]

Update store information in location metadata

glance.api.authorization.proxy_image(context, image)[source]
glance.api.authorization.proxy_member(context, member)[source]
glance.api.authorization.proxy_meta_resource_type(context, meta_resource_type)[source]
glance.api.authorization.proxy_namespace(context, namespace)[source]
glance.api.authorization.proxy_namespace_property(context, namespace_property)[source]
glance.api.authorization.proxy_object(context, object)[source]
glance.api.authorization.proxy_tag(context, tag)[source]
glance.api.authorization.proxy_task(context, task)[source]
glance.api.authorization.proxy_task_stub(context, task_stub)[source]