@twick/cloud-export-video 0.14.16 → 0.14.17

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.
@@ -12,12 +12,22 @@ function copyTemplate(destDir) {
12
12
  const templateDir = join(pkgRoot, 'platform', 'aws');
13
13
  if (!fs.existsSync(destDir)) fs.mkdirSync(destDir, { recursive: true });
14
14
 
15
- for (const name of ['Dockerfile', 'handler.js']) {
16
- const src = join(templateDir, name);
17
- const dest = join(destDir, name);
18
- fs.copyFileSync(src, dest);
15
+ // Create platform/aws directory structure to maintain consistency with CMD ["platform/aws/handler.handler"]
16
+ const platformAwsDir = join(destDir, 'platform', 'aws');
17
+ if (!fs.existsSync(platformAwsDir)) {
18
+ fs.mkdirSync(platformAwsDir, { recursive: true });
19
19
  }
20
20
 
21
+ // Copy Dockerfile to root (it references platform/aws/handler.handler)
22
+ const dockerfileSrc = join(templateDir, 'Dockerfile');
23
+ const dockerfileDest = join(destDir, 'Dockerfile');
24
+ fs.copyFileSync(dockerfileSrc, dockerfileDest);
25
+
26
+ // Copy handler.js to platform/aws/ to match the CMD path
27
+ const handlerSrc = join(templateDir, 'handler.js');
28
+ const handlerDest = join(platformAwsDir, 'handler.js');
29
+ fs.copyFileSync(handlerSrc, handlerDest);
30
+
21
31
  // Minimal package.json to enable docker layer caching (npm ci)
22
32
  const pkgJsonPath = join(destDir, 'package.json');
23
33
  if (!fs.existsSync(pkgJsonPath)) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@twick/cloud-export-video",
3
- "version": "0.14.16",
3
+ "version": "0.14.17",
4
4
  "description": "Twick cloud function for exporting video with platform-specific templates (AWS Lambda container)",
5
5
  "type": "module",
6
6
  "main": "core/renderer.js",
@@ -23,6 +23,7 @@
23
23
  "verify:aws": "node -e \"require('fs').accessSync('platform/aws/Dockerfile'); require('fs').accessSync('platform/aws/handler.js'); console.log('AWS platform assets present')\"",
24
24
  "pack:aws": "npm run verify:aws && npm pack",
25
25
  "release:aws": "npm run verify:aws && npm publish --access public --tag aws",
26
+ "deploy:aws": "node scripts/deploy-aws.js",
26
27
  "prepublishOnly": "npm run verify:aws"
27
28
  },
28
29
  "publishConfig": {
@@ -44,13 +45,13 @@
44
45
  },
45
46
  "dependencies": {
46
47
  "@sparticuz/chromium": "^129.0.0",
47
- "@twick/2d": "0.14.16",
48
- "@twick/core": "0.14.16",
49
- "@twick/ffmpeg": "0.14.16",
50
- "@twick/renderer": "0.14.16",
51
- "@twick/ui": "0.14.16",
52
- "@twick/vite-plugin": "0.14.16",
53
- "@twick/visualizer": "0.14.16",
48
+ "@twick/2d": "0.14.17",
49
+ "@twick/core": "0.14.17",
50
+ "@twick/ffmpeg": "0.14.17",
51
+ "@twick/renderer": "0.14.17",
52
+ "@twick/ui": "0.14.17",
53
+ "@twick/vite-plugin": "0.14.17",
54
+ "@twick/visualizer": "0.14.17",
54
55
  "@aws-sdk/client-s3": "^3.620.0",
55
56
  "ffmpeg-static": "^5.2.0",
56
57
  "fluent-ffmpeg": "^2.1.3"
@@ -33,4 +33,4 @@ ENV HOME=/tmp
33
33
 
34
34
  ENV DONT_WRITE_TO_META_FILES=true
35
35
 
36
- CMD ["handler.handler"]
36
+ CMD ["platform/aws/handler.handler"]