Class Auth
- java.lang.Object
-
- com.google.cloud.tools.appengine.operations.Auth
-
public class Auth extends Object
Run various gcloud auth commands.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
activateServiceAccount(Path jsonFile)
Activates a service account based on a configured json key file.void
login()
Launches the gcloud auth login flow.void
login(String user)
Logs into the Cloud SDK with a specific user (does not retrigger auth flow if user is already configured for the system).
-
-
-
Method Detail
-
login
public void login(String user) throws AppEngineException
Logs into the Cloud SDK with a specific user (does not retrigger auth flow if user is already configured for the system).- Parameters:
user
- a user email- Throws:
AppEngineException
- when there is an issue with the auth flow
-
login
public void login() throws AppEngineException
Launches the gcloud auth login flow.- Throws:
AppEngineException
-
activateServiceAccount
public void activateServiceAccount(Path jsonFile) throws AppEngineException
Activates a service account based on a configured json key file.- Parameters:
jsonFile
- a service account json key file- Throws:
AppEngineException
- when there is an issue with the auth flow
-
-