Class JibSystemProperties
- java.lang.Object
-
- com.google.cloud.tools.jib.global.JibSystemProperties
-
public class JibSystemProperties extends java.lang.Object
Names of system properties defined/used by Jib.
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
HTTP_TIMEOUT
static java.lang.String
SEND_CREDENTIALS_OVER_HTTP
static java.lang.String
SERIALIZE
static java.lang.String
SKIP_EXISTING_IMAGES
static java.lang.String
UPSTREAM_CLIENT
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static void
checkHttpTimeoutProperty()
Checks thejib.httpTimeout
system property for invalid (non-integer or negative) values.static void
checkProxyPortProperty()
Checks ifhttp.proxyPort
andhttps.proxyPort
system properties are in the [0..65535] range when set.static int
getHttpTimeout()
Gets the HTTP connection/read timeouts for registry interactions in milliseconds.static boolean
isUserAgentEnabled()
Gets whether or not to enable the User-Agent header.static boolean
sendCredentialsOverHttp()
Gets whether or not to allow sending authentication information over insecure HTTP connections.static boolean
serializeExecution()
Gets whether or not to serialize Jib's execution.static boolean
skipExistingImages()
Gets whether or not to skip pushing tags to existing images.static boolean
useCrossRepositoryBlobMounts()
Gets whether or not to use cross-repository blob mounts when uploading image layers (mount/from
).
-
-
-
Field Detail
-
UPSTREAM_CLIENT
public static final java.lang.String UPSTREAM_CLIENT
- See Also:
- Constant Field Values
-
HTTP_TIMEOUT
public static final java.lang.String HTTP_TIMEOUT
- See Also:
- Constant Field Values
-
SEND_CREDENTIALS_OVER_HTTP
public static final java.lang.String SEND_CREDENTIALS_OVER_HTTP
- See Also:
- Constant Field Values
-
SERIALIZE
public static final java.lang.String SERIALIZE
- See Also:
- Constant Field Values
-
SKIP_EXISTING_IMAGES
public static final java.lang.String SKIP_EXISTING_IMAGES
- See Also:
- Constant Field Values
-
-
Method Detail
-
getHttpTimeout
public static int getHttpTimeout()
Gets the HTTP connection/read timeouts for registry interactions in milliseconds. This is defined by thejib.httpTimeout
system property. The default value is 20000 if the system property is not set, and 0 indicates an infinite timeout.- Returns:
- the HTTP connection/read timeouts for registry interactions in milliseconds
-
useCrossRepositoryBlobMounts
public static boolean useCrossRepositoryBlobMounts()
Gets whether or not to use cross-repository blob mounts when uploading image layers (mount/from
). This is defined by thejib.blobMounts
system property.- Returns:
true
ifmount/from
should be used,false
if not, defaulting totrue
-
serializeExecution
public static boolean serializeExecution()
Gets whether or not to serialize Jib's execution. This is defined by thejib.serialize
system property.- Returns:
true
if Jib's execution should be serialized,false
if not
-
sendCredentialsOverHttp
public static boolean sendCredentialsOverHttp()
Gets whether or not to allow sending authentication information over insecure HTTP connections. This is defined by thesendCredentialsOverHttp
system property.- Returns:
true
if authentication information is allowed to be sent over insecure connections,false
if not
-
isUserAgentEnabled
public static boolean isUserAgentEnabled()
Gets whether or not to enable the User-Agent header. This is defined by the_JIB_DISABLE_USER_AGENT
system property.- Returns:
true
if the User-Agent header is enabled,false
if not
-
checkHttpTimeoutProperty
public static void checkHttpTimeoutProperty() throws java.lang.NumberFormatException
Checks thejib.httpTimeout
system property for invalid (non-integer or negative) values.- Throws:
java.lang.NumberFormatException
- if invalid values
-
checkProxyPortProperty
public static void checkProxyPortProperty() throws java.lang.NumberFormatException
Checks ifhttp.proxyPort
andhttps.proxyPort
system properties are in the [0..65535] range when set.- Throws:
java.lang.NumberFormatException
- if invalid values
-
skipExistingImages
public static boolean skipExistingImages()
Gets whether or not to skip pushing tags to existing images. This is defined by thejib.skipExistingImages
system property.- Returns:
true
if Jib should skip pushing tags to existing images,false
if not
-
-