@just-be/deploy 0.9.0 → 0.10.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/index.ts +1 -0
  2. package/package.json +1 -1
  3. package/schema.json +52 -0
package/index.ts CHANGED
@@ -383,6 +383,7 @@ async function deployRedirectRule(
383
383
  type: "redirect",
384
384
  url: rule.url,
385
385
  ...(rule.permanent !== undefined && { permanent: rule.permanent }),
386
+ ...(rule.preservePath !== undefined && { preservePath: rule.preservePath }),
386
387
  };
387
388
 
388
389
  s.start(`Creating KV routing entry`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@just-be/deploy",
3
- "version": "0.9.0",
3
+ "version": "0.10.0",
4
4
  "description": "Deploy static sites to Cloudflare R2 with subdomain routing",
5
5
  "type": "module",
6
6
  "bin": {
package/schema.json CHANGED
@@ -20,6 +20,55 @@
20
20
  "fallback": {
21
21
  "type": "string"
22
22
  },
23
+ "redirects": {
24
+ "type": "array",
25
+ "items": {
26
+ "type": "object",
27
+ "properties": {
28
+ "path": {
29
+ "type": "string",
30
+ "minLength": 1,
31
+ "pattern": "^\\/.*"
32
+ },
33
+ "url": {
34
+ "type": "string",
35
+ "format": "uri"
36
+ },
37
+ "permanent": {
38
+ "type": "boolean"
39
+ }
40
+ },
41
+ "required": ["path", "url"],
42
+ "additionalProperties": false
43
+ }
44
+ },
45
+ "rewrites": {
46
+ "type": "array",
47
+ "items": {
48
+ "type": "object",
49
+ "properties": {
50
+ "path": {
51
+ "type": "string",
52
+ "minLength": 1,
53
+ "pattern": "^\\/.*"
54
+ },
55
+ "url": {
56
+ "type": "string",
57
+ "format": "uri"
58
+ },
59
+ "allowedMethods": {
60
+ "default": ["GET", "HEAD", "OPTIONS"],
61
+ "type": "array",
62
+ "items": {
63
+ "type": "string",
64
+ "enum": ["GET", "POST", "PUT", "DELETE", "PATCH", "HEAD", "OPTIONS"]
65
+ }
66
+ }
67
+ },
68
+ "required": ["path", "url", "allowedMethods"],
69
+ "additionalProperties": false
70
+ }
71
+ },
23
72
  "subdomain": {
24
73
  "type": "string"
25
74
  },
@@ -45,6 +94,9 @@
45
94
  "permanent": {
46
95
  "type": "boolean"
47
96
  },
97
+ "preservePath": {
98
+ "type": "boolean"
99
+ },
48
100
  "subdomain": {
49
101
  "type": "string"
50
102
  }