From 07cfde8c15568c185a1bb49333095442db8913e2 Mon Sep 17 00:00:00 2001 From: nguyentrungthat <80239428+nguentrungthat@users.noreply.github.com> Date: Tue, 6 Jan 2026 16:46:29 +0700 Subject: [PATCH] Update line_connection.ts --- BACKEND/app/services/line_connection.ts | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/BACKEND/app/services/line_connection.ts b/BACKEND/app/services/line_connection.ts index 75e17fe..219d473 100644 --- a/BACKEND/app/services/line_connection.ts +++ b/BACKEND/app/services/line_connection.ts @@ -1065,6 +1065,7 @@ export default class LineConnection { const station = await Station.find(this.config.stationId) if (!station) return const network = station?.gateway || '172.25.1.1' + const tftpIp = station?.tftp_ip || '172.16.7.69' const [a, b] = network.split('.').map(Number) const timeZone = process.env.TIME_ZONE || 'Australia/Sydney' const startTime = momentTZ().tz(timeZone).format('YYYY/MM/DD, HH:mm:ss') @@ -1092,7 +1093,7 @@ export default class LineConnection { }, { expect: 'rommon', - send: `TFTP_SERVER=${station?.tftp_ip || '172.16.7.69'}`, + send: `TFTP_SERVER=${tftpIp}`, delay: '1', repeat: '1', note: '', @@ -1199,7 +1200,7 @@ export default class LineConnection { timeout: 1000, body: JSON.stringify(body), } - + await sleep(5000) await this.runScript(script as any, userName) await this.endEmailLoadIos(nameIos, startTime) } @@ -1208,6 +1209,7 @@ export default class LineConnection { const station = await Station.find(this.config.stationId) if (!station) return const network = station?.gateway || '172.25.1.1' + const tftpIp = station?.tftp_ip || '172.16.7.69' const [a, b] = network.split('.').map(Number) const timeZone = process.env.TIME_ZONE || 'Australia/Sydney' const startTime = momentTZ().tz(timeZone).format('YYYY/MM/DD, HH:mm:ss') @@ -1291,7 +1293,7 @@ export default class LineConnection { }, { expect: '', - send: `${station?.tftp_ip || '172.16.7.69'}`, + send: `${tftpIp}`, delay: '1', repeat: '1', note: '',