db: Set name for FK constraint

The name is present on the migrations. Set it on the models.

Change-Id: I9766dd02d3c97c419234b35cb4c45c21d6aab449
Signed-off-by: Stephen Finucane <stephenfin@redhat.com>
This commit is contained in:
Stephen Finucane 2023-09-25 15:28:29 +01:00
parent 4230fbc823
commit 6e30355d57
1 changed files with 4 additions and 1 deletions

View File

@ -643,7 +643,10 @@ class VolumeTypeExtraSpecs(BASE, CinderBase):
value = sa.Column(sa.String(255))
volume_type_id = sa.Column(
sa.String(36),
sa.ForeignKey('volume_types.id'),
sa.ForeignKey(
'volume_types.id',
name='volume_type_extra_specs_ibfk_1',
),
nullable=False,
index=True,
)