Add an index to the docker_image_id for faster lookup
This commit is contained in:
parent
d73747ce1d
commit
178c5a7ac0
2 changed files with 27 additions and 1 deletions
|
@ -386,7 +386,7 @@ class Image(BaseModel):
|
|||
# to be globally unique we can't treat them as such for permissions and
|
||||
# security reasons. So rather than Repository <-> Image being many to many
|
||||
# each image now belongs to exactly one repository.
|
||||
docker_image_id = CharField()
|
||||
docker_image_id = CharField(index=True)
|
||||
repository = ForeignKeyField(Repository)
|
||||
|
||||
# '/' separated list of ancestory ids, e.g. /1/2/6/7/10/
|
||||
|
|
Reference in a new issue