Skip to content

Commit

Permalink
gcp auth
Browse files Browse the repository at this point in the history
  • Loading branch information
Aarsh2001 committed Oct 4, 2023
1 parent f8198b6 commit c705f5c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .github/auth/vm_auth.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
from google.oauth2.service_account import Credentials

def authenticate_vm(path):
credentials = Credentials.from_service_file(path)
credentials = Credentials.from_service_account_file(path)
return discovery.build('compute', 'v1', credentials=credentials)
def start_runner(creds, pkey, id = "gpu-insatnce", zone='us-central1-a', instance='demos-tests'):
compute = authenticate_vm(creds)
Expand Down Expand Up @@ -37,7 +37,7 @@ def start_runner(creds, pkey, id = "gpu-insatnce", zone='us-central1-a', instanc
if __name__ == "__main__":
key = sys.argv[1]
# Start the instance
start_runner('/gcp_auth.json', pkey=key)
start_runner('gcp_auth.json', pkey=key)



0 comments on commit c705f5c

Please sign in to comment.