Skip to content

Commit 4044e7e

Browse files
author
lijianguo
committed
2 parents 54f414a + 6328b3f commit 4044e7e

3 files changed

Lines changed: 6 additions & 5 deletions

File tree

rootfs/api/migrations/0001_initial.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -260,8 +260,8 @@ class Migration(migrations.Migration):
260260
('name', models.CharField(max_length=63, validators=[api.models.validate_label])),
261261
('plan', models.CharField(max_length=128)),
262262
('data', jsonfield.fields.JSONField(blank=True, default={})),
263-
('status', models.CharField(max_length=32, null=True)),
264-
('binding', models.CharField(max_length=32, null=True)),
263+
('status', models.TextField(blank=True, null=True)),
264+
('binding', models.TextField(blank=True, null=True)),
265265
('options', jsonfield.fields.JSONField(blank=True, default={})),
266266
('app', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='api.App')),
267267
('owner', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to=settings.AUTH_USER_MODEL)),

rootfs/api/models/resource.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@ class Resource(UuidAuditedModel):
2020
name = models.CharField(max_length=63, validators=[validate_label])
2121
plan = models.CharField(max_length=128)
2222
data = JSONField(default={}, blank=True)
23-
status = models.CharField(max_length=32, null=True)
24-
binding = models.CharField(max_length=32, null=True)
23+
status = models.TextField(blank=True, null=True)
24+
binding = models.TextField(blank=True, null=True)
2525
options = JSONField(default={}, blank=True)
2626

2727
class Meta:

rootfs/api/views.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -665,7 +665,8 @@ def path(self, request, *args, **kwargs):
665665
raise DryccException("path is a required field")
666666
obj = self.get_object()
667667
container_types = [_ for _ in new_path.keys()
668-
if _ not in obj.app.procfile_structure.keys()]
668+
if _ not in obj.app.procfile_structure.keys() or
669+
_ not in obj.app.structure.keys()]
669670
if container_types:
670671
raise DryccException("process type {} is not included in profile".
671672
format(','.join(container_types)))

0 commit comments

Comments
 (0)