File tree Expand file tree Collapse file tree 6 files changed +31
-15
lines changed
src/cloud/router-layer/nodejs Expand file tree Collapse file tree 6 files changed +31
-15
lines changed Original file line number Diff line number Diff line change @@ -8,10 +8,11 @@ export default new Action({
8
8
handle ( ) {
9
9
return {
10
10
status : 'ok' ,
11
- uptime : process . uptime ( ) ,
11
+ uptime : Bun . nanoseconds ( ) , // similar to process.uptime()
12
12
memory : process . memoryUsage ( ) ,
13
13
pid : process . pid ,
14
- version : process . version , // TODO: display Bun version instead
14
+ version : Bun . version ,
15
+ revision : Bun . revision ,
15
16
}
16
17
} ,
17
18
} )
Original file line number Diff line number Diff line change 7
7
"build" : " bun build.ts"
8
8
},
9
9
"dependencies" : {
10
- "@stacksjs/logging" : " ^0.58.67 " ,
11
- "@stacksjs/queue" : " ^0.58.67 " ,
12
- "@stacksjs/router" : " ^0.58.67 " ,
13
- "@stacksjs/storage" : " ^0.58.67 " ,
14
- "@stacksjs/utils" : " ^0.58.67 " ,
10
+ "@stacksjs/logging" : " ^0.58.69 " ,
11
+ "@stacksjs/queue" : " ^0.58.69 " ,
12
+ "@stacksjs/router" : " ^0.58.69 " ,
13
+ "@stacksjs/storage" : " ^0.58.69 " ,
14
+ "@stacksjs/utils" : " ^0.58.69 " ,
15
15
"aws4fetch" : " ^1.0.17"
16
16
}
17
17
}
Original file line number Diff line number Diff line change 10
10
"test" : " echo \" Error: no test specified\" && exit 1"
11
11
},
12
12
"dependencies" : {
13
- "@stacksjs/router" : " ^0.58.67 "
13
+ "@stacksjs/router" : " ^0.58.69 "
14
14
}
15
15
}
Original file line number Diff line number Diff line change 1
1
import { log , runCommand } from '@stacksjs/cli'
2
2
3
- const result = await runCommand ( 'zip -r ../../cloud /dist.zip dist/origin-request.js package.json' , {
3
+ const result = await runCommand ( 'zip -r ./dist.zip dist/origin-request.js package.json' , {
4
4
cwd : import . meta. dir ,
5
5
} )
6
6
7
- if ( result . isErr ( ) )
7
+ if ( result . isErr ( ) ) {
8
8
log . error ( result . error )
9
+ }
10
+ else {
11
+ // need to move the file to ../../cloud/dist.zip
12
+ await runCommand ( 'mv -f dist.zip ../../cloud/dist.zip' , {
13
+ cwd : import . meta. dir ,
14
+ } )
15
+
16
+ log . success ( 'Created & moved dist.zip' )
17
+ }
Original file line number Diff line number Diff line change @@ -4,6 +4,12 @@ import { serverResponse } from '@stacksjs/router'
4
4
import { log } from '@stacksjs/logging'
5
5
import { retry } from '@stacksjs/utils'
6
6
7
+ process . on ( 'SIGINT' , ( ) => {
8
+ // eslint-disable-next-line no-console
9
+ console . log ( 'Exited using Ctrl-C' )
10
+ process . exit ( )
11
+ } )
12
+
7
13
if ( process . env . QUEUE_WORKER ) {
8
14
if ( ! process . env . JOB )
9
15
throw new Error ( 'Missing JOB environment variable' )
Original file line number Diff line number Diff line change 7
7
"build" : " bun build.ts"
8
8
},
9
9
"dependencies" : {
10
- "@stacksjs/logging" : " ^0.58.67 " ,
11
- "@stacksjs/queue" : " ^0.58.67 " ,
12
- "@stacksjs/router" : " ^0.58.67 " ,
13
- "@stacksjs/storage" : " ^0.58.67 " ,
14
- "@stacksjs/utils" : " ^0.58.67 " ,
10
+ "@stacksjs/logging" : " ^0.58.69 " ,
11
+ "@stacksjs/queue" : " ^0.58.69 " ,
12
+ "@stacksjs/router" : " ^0.58.69 " ,
13
+ "@stacksjs/storage" : " ^0.58.69 " ,
14
+ "@stacksjs/utils" : " ^0.58.69 " ,
15
15
"aws4fetch" : " ^1.0.17"
16
16
}
17
17
}
You can’t perform that action at this time.
0 commit comments