change nodejs base image..

This commit is contained in:
zizifn
2023-05-08 03:22:06 +08:00
committed by zizifn
parent 18ed3a64cf
commit bb6f7d7648
4 changed files with 621 additions and 617 deletions

View File

@@ -1,4 +1,4 @@
FROM node:18-alpine FROM node:slim
ENV NODE_ENV=production ENV NODE_ENV=production
ENV PORT=4100 ENV PORT=4100

View File

@@ -338,6 +338,7 @@ function makeUDPSocketStream(portRemote, address) {
start(controller) { start(controller) {
/* … */ /* … */
udpClient.on('message', (message, info) => { udpClient.on('message', (message, info) => {
console.log('udp package received', message);
controller.enqueue( controller.enqueue(
Buffer.concat([new Uint8Array([0, info.size]), message]) Buffer.concat([new Uint8Array([0, info.size]), message])
); );
@@ -365,6 +366,7 @@ function makeUDPSocketStream(portRemote, address) {
controller.error(`Failed to send UDP packet !! ${err}`); controller.error(`Failed to send UDP packet !! ${err}`);
safeCloseUDP(udpClient); safeCloseUDP(udpClient);
} }
console.log('udp package sent', udpData);
resolve(true); resolve(true);
}); });
}); });

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long