Skip to content

Commit 4cff2dd

Browse files
authored
Remove leading double slash in shutdown script (#40)
1 parent 32a0ac9 commit 4cff2dd

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

dist/index.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -781,6 +781,7 @@ class UserData {
781781
"#!/bin/bash",
782782
`shutdown -P +${this.config.ec2InstanceTtl}`,
783783
"CURRENT_PATH=$(pwd)",
784+
'CURRENT_PATH="${CURRENT_PATH%/}"',
784785
`echo "./config.sh remove --token ${runnerRegistrationToken.token} || true" > $CURRENT_PATH/shutdown_script.sh`,
785786
`echo "shutdown -P +1" > $CURRENT_PATH/shutdown_script.sh`,
786787
"chmod +x $CURRENT_PATH/shutdown_script.sh",

src/ec2/userdata.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ export class UserData {
3838
"#!/bin/bash",
3939
`shutdown -P +${this.config.ec2InstanceTtl}`,
4040
"CURRENT_PATH=$(pwd)",
41+
'CURRENT_PATH="${CURRENT_PATH%/}"',
4142
`echo "./config.sh remove --token ${runnerRegistrationToken.token} || true" > $CURRENT_PATH/shutdown_script.sh`,
4243
`echo "shutdown -P +1" > $CURRENT_PATH/shutdown_script.sh`,
4344
"chmod +x $CURRENT_PATH/shutdown_script.sh",

0 commit comments

Comments
 (0)