Skip to content

Commit

Permalink
fix: prevent labels ending with - in resource id
Browse files Browse the repository at this point in the history
Signed-off-by: Ben Meier <ben.meier@humanitec.com>
  • Loading branch information
astromechza committed Sep 11, 2024
1 parent a2356d0 commit 1569fc3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions score-v1b1.json
Original file line number Diff line number Diff line change
Expand Up @@ -144,11 +144,11 @@
"pattern": "^[A-Za-z0-9][A-Za-z0-9-]{0,61}[A-Za-z0-9]$"
},
"id": {
"description": "An optional Resource identifier. When two resources share the same type, class, and id, they are considered the same resource when used across related Workloads. The id may be up to 63 characters, including a-z, 0-9, '-' or '.' but may not start or end with '-' or '.'.",
"description": "An optional Resource identifier. The id may be up to 63 characters, including one or more labels of a-z, 0-9, '-' not starting or ending with '-' separated by '.'. When two resources share the same type, class, and id, they are considered the same resource when used across related Workloads.",
"type": "string",
"minLength": 2,
"maxLength": 63,
"pattern": "^[a-z0-9][a-z0-9-.]{0,61}[a-z0-9]$"
"pattern": "^[a-z0-9]+(?:-+[a-z0-9]+)*(?:\\.[a-z0-9]+(?:-+[a-z0-9]+)*)*$"
},
"metadata": {
"description": "The metadata for the Resource.",
Expand Down

0 comments on commit 1569fc3

Please sign in to comment.