Skip to content

Commit c436bdf

Browse files
committed
change model, add ssh keys
1 parent 6c007d6 commit c436bdf

File tree

2 files changed

+0
-14
lines changed

2 files changed

+0
-14
lines changed

.github/workflows/create_instance.yaml

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,6 @@ on:
1111
description: 'Instance name suffix'
1212
required: false
1313
default: ''
14-
sshAuthorizedKey:
15-
description: 'SSH authorized public key'
16-
required: false
17-
default: ''
1814

1915
jobs:
2016
create-instance:
@@ -54,5 +50,4 @@ jobs:
5450
S3_SECRET_ACCESS_KEY: ${{ secrets.S3_SECRET_ACCESS_KEY}}
5551

5652
MODEL: ${{ inputs.model }}
57-
SSH_AUTHORIZED_KEY: ${{ inputs.sshAuthorizedKey }}
5853
INSTANCE_NAME_SUFFIX: ${{ inputs.instanceNameSuffix }}

main.py

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,6 @@ def indentString(input_string, indent_level=4):
5454
model = os.getenv("MODEL", "")
5555
users = os.getenv("USERS", "")
5656

57-
ssh_authorized_keys = os.getenv("SSH_AUTHORIZED_KEY")
58-
5957
if users:
6058
users = f"""
6159
users:
@@ -72,20 +70,13 @@ def indentString(input_string, indent_level=4):
7270
user['groups'].append(user['primary_group'])
7371
if 'docker' not in user['groups']:
7472
user['groups'].append('docker')
75-
if 'sudo' not in user['groups']:
76-
user['groups'].append('sudo')
77-
if ssh_authorized_keys:
78-
user['ssh_authorized_keys'] = [
79-
ssh_authorized_keys
80-
]
8173
users = yaml.dump(parsedUsers)
8274

8375

8476

8577
f = open("docker-compose.yaml", "r")
8678
dockerCompose = indentString(f.read(), 8)
8779

88-
8980
userData = f"""
9081
#cloud-config
9182

0 commit comments

Comments
 (0)