Skip to content

Commit

Permalink
Merge pull request #33 from fosrl/hotfix
Browse files Browse the repository at this point in the history
fix regex for base_domain
  • Loading branch information
miloschwartz authored Jan 12, 2025
2 parents 5774e53 + fa39b70 commit 025c2c5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@fosrl/pangolin",
"version": "1.0.0-beta.3",
"version": "1.0.0-beta.4",
"private": true,
"type": "module",
"description": "Tunneled Reverse Proxy Management Server with Identity and Access Control and Dashboard UI",
Expand Down
6 changes: 3 additions & 3 deletions server/lib/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ const portSchema = z.number().positive().gt(0).lte(65535);
const hostnameSchema = z
.string()
.regex(
/^(?!-)[a-zA-Z0-9-]{1,63}(?<!-)(\.[a-zA-Z]{2,})*$/,
"Invalid hostname. Must be a valid hostname like 'localhost' or 'test.example.com'."
);
/^(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)$|^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\-]*[a-zA-Z0-9])\.)+([A-Za-z]|[A-Za-z][A-Za-z0-9\-]*[A-Za-z0-9])$/
)
.or(z.literal("localhost"));

const environmentSchema = z.object({
app: z.object({
Expand Down

0 comments on commit 025c2c5

Please sign in to comment.