Class GitContainer
- java.lang.Object
-
- org.jenkinsci.test.acceptance.docker.DockerContainer
-
- org.jenkinsci.test.acceptance.docker.fixtures.GitContainer
-
- All Implemented Interfaces:
Closeable
,AutoCloseable
- Direct Known Subclasses:
JavaGitContainer
public class GitContainer extends org.jenkinsci.test.acceptance.docker.DockerContainer
Runs gitserver container.
-
-
Constructor Summary
Constructors Constructor Description GitContainer()
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description void
addSSHCertificate(String pubKey)
Add an additional certificate to~/.ssh/authorized_keys
String
getRepoUrl()
URL visible from the host.String
getRepoUrlInsideDocker()
Deprecated.String
getRepoUrlInsideDocker(String alias)
URL visible from other Docker containers.URL
getUrl()
String
host()
int
port()
-
-
-
Field Detail
-
REPO_DIR
protected static final String REPO_DIR
- See Also:
- Constant Field Values
-
REPO_NAME
public static final String REPO_NAME
- See Also:
- Constant Field Values
-
-
Method Detail
-
host
public String host()
-
port
public int port()
-
getUrl
public URL getUrl() throws IOException
- Throws:
IOException
-
getRepoUrl
public String getRepoUrl()
URL visible from the host.
-
getRepoUrlInsideDocker
@Deprecated public String getRepoUrlInsideDocker() throws IOException
Deprecated.- Throws:
IOException
-
getRepoUrlInsideDocker
public String getRepoUrlInsideDocker(String alias) throws IOException
URL visible from other Docker containers.- Parameters:
alias
- an alias for this container’sDockerContainer.getCid()
passed to--link
- Throws:
IOException
-
addSSHCertificate
public void addSSHCertificate(String pubKey) throws IOException, InterruptedException
Add an additional certificate to~/.ssh/authorized_keys
- Parameters:
pubKey
- the certificate public key- Throws:
IOException
InterruptedException
-
-