public final class DockerClientConfigHandler extends Object
FileSystem.Token and Credentials objects.ContainerLaunchContext as a
   ByteBuffer, extract the Credentials.| Modifier and Type | Method and Description | 
|---|---|
| static org.apache.hadoop.security.Credentials | getCredentialsFromTokensByteBuffer(ByteBuffer tokens)Convert the Token ByteBuffer to the appropriate Credentials object. | 
| static org.apache.hadoop.security.Credentials | readCredentialsFromConfigFile(org.apache.hadoop.fs.Path configFile,
                             org.apache.hadoop.conf.Configuration conf,
                             String applicationId)Read the Docker client configuration and extract the auth tokens into
 Credentials. | 
| static boolean | writeDockerCredentialsToPath(File outConfigFile,
                            org.apache.hadoop.security.Credentials credentials)Extract the Docker related tokens from the Credentials and write the Docker
 client configuration to the supplied File. | 
public static org.apache.hadoop.security.Credentials readCredentialsFromConfigFile(org.apache.hadoop.fs.Path configFile,
                                                                                   org.apache.hadoop.conf.Configuration conf,
                                                                                   String applicationId)
                                                                            throws IOException
configFile - the Path to the Docker client configuration.conf - the Configuration object, needed by the FileSystem.applicationId - the application ID to associate the Credentials with.IOException - if the file can not be read.public static org.apache.hadoop.security.Credentials getCredentialsFromTokensByteBuffer(ByteBuffer tokens) throws IOException
tokens - the Tokens from the ContainerLaunchContext.IOExceptionpublic static boolean writeDockerCredentialsToPath(File outConfigFile, org.apache.hadoop.security.Credentials credentials) throws IOException
outConfigFile - the File to write the Docker client configuration to.credentials - the populated Credentials object.IOException - if the write fails.Copyright © 2008–2023 Apache Software Foundation. All rights reserved.