Codota Logo
Config.isTrustCerts
Code IndexAdd Codota to your IDE (free)

How to use
isTrustCerts
method
in
io.fabric8.kubernetes.client.Config

Best Java code snippets using io.fabric8.kubernetes.client.Config.isTrustCerts (Showing top 16 results out of 315)

  • Common ways to obtain Config
private void myMethod () {
Config c =
  • Codota IconString str;new ConfigBuilder().withMasterUrl(str).build()
  • Codota Iconnew Config()
  • Codota Iconnew ConfigBuilder().build()
  • Smart code suggestions by Codota
}
origin: fabric8io/kubernetes-client

public static SSLContext sslContext(Config config) throws CertificateException, UnrecoverableKeyException, NoSuchAlgorithmException, KeyStoreException, IOException, InvalidKeySpecException, KeyManagementException {
  return sslContext(keyManagers(config), trustManagers(config), config.isTrustCerts());
}
origin: spring-cloud/spring-cloud-kubernetes

    base.getRollingTimeout()))
.withTrustCerts(or(kubernetesClientProperties.isTrustCerts(),
    base.isTrustCerts()))
.withHttpProxy(or(kubernetesClientProperties.getHttpProxy(),
  base.getHttpProxy()))
origin: fabric8io/kubernetes-client

public static TrustManager[] trustManagers(Config config) throws CertificateException, NoSuchAlgorithmException, KeyStoreException, IOException {
  return trustManagers(config.getCaCertData(), config.getCaCertFile(), config.isTrustCerts(), config.getTrustStoreFile(), config.getTrustStorePassphrase());
}
origin: fabric8io/kubernetes-client

httpClientBuilder.followSslRedirects(true);
if (config.isTrustCerts() || config.isDisableHostnameVerification()) {
  httpClientBuilder.hostnameVerifier(new HostnameVerifier() {
    @Override
KeyManager[] keyManagers = SSLUtils.keyManagers(config);
if (keyManagers != null || trustManagers != null || config.isTrustCerts()) {
  X509TrustManager trustManager = null;
  if (trustManagers != null && trustManagers.length == 1) {
    SSLContext sslContext = SSLUtils.sslContext(keyManagers, trustManagers, config.isTrustCerts());
    httpClientBuilder.sslSocketFactory(sslContext.getSocketFactory(), trustManager);
  } catch (GeneralSecurityException e) {
origin: fabric8io/kubernetes-client

public static void configFromSysPropsOrEnvVars(Config config) {
 config.setTrustCerts(Utils.getSystemPropertyOrEnvVar(KUBERNETES_TRUST_CERT_SYSTEM_PROPERTY, config.isTrustCerts()));
 config.setDisableHostnameVerification(Utils.getSystemPropertyOrEnvVar(KUBERNETES_DISABLE_HOSTNAME_VERIFICATION_SYSTEM_PROPERTY, config.isDisableHostnameVerification()));
 config.setMasterUrl(Utils.getSystemPropertyOrEnvVar(KUBERNETES_MASTER_SYSTEM_PROPERTY, config.getMasterUrl()));
origin: fabric8io/spring-cloud-kubernetes

@Bean
@ConditionalOnMissingBean(Config.class)
public Config kubernetesClientConfig(KubernetesClientProperties kubernetesClientProperties) {
  Config base = new Config();
  Config properties = new ConfigBuilder(base)
      //Only set values that have been explicitly specified
      .withMasterUrl(or(kubernetesClientProperties.getMasterUrl(), base.getMasterUrl()))
      .withApiVersion(or(kubernetesClientProperties.getApiVersion(), base.getApiVersion()))
      .withNamespace(or(kubernetesClientProperties.getNamespace(), base.getNamespace()))
      .withUsername(or(kubernetesClientProperties.getUsername(), base.getUsername()))
      .withPassword(or(kubernetesClientProperties.getPassword(), base.getPassword()))
      .withCaCertFile(or(kubernetesClientProperties.getCaCertFile(), base.getCaCertFile()))
      .withCaCertData(or(kubernetesClientProperties.getCaCertData(), base.getCaCertData()))
      .withClientKeyFile(or(kubernetesClientProperties.getClientKeyFile(), base.getClientKeyFile()))
      .withClientKeyData(or(kubernetesClientProperties.getClientKeyData(), base.getClientKeyData()))
      .withClientCertFile(or(kubernetesClientProperties.getClientCertFile(), base.getClientCertFile()))
      .withClientCertData(or(kubernetesClientProperties.getClientCertData(), base.getClientCertData()))
      //No magic is done for the properties below so we leave them as is.
      .withClientKeyAlgo(or(kubernetesClientProperties.getClientKeyAlgo(), base.getClientKeyAlgo()))
      .withClientKeyPassphrase(or(kubernetesClientProperties.getClientKeyPassphrase(), base.getClientKeyPassphrase()))
      .withConnectionTimeout(or(kubernetesClientProperties.getConnectionTimeout(), base.getConnectionTimeout()))
      .withRequestTimeout(or(kubernetesClientProperties.getRequestTimeout(), base.getRequestTimeout()))
      .withRollingTimeout(or(kubernetesClientProperties.getRollingTimeout(), base.getRollingTimeout()))
      .withTrustCerts(or(kubernetesClientProperties.isTrustCerts(), base.isTrustCerts()))
      .build();
  if (properties.getNamespace() == null || properties.getNamespace().isEmpty()) {
    LOG.warn("No namespace has been detected. Please specify KUBERNETES_NAMESPACE env var, or use a later kubernetes version (1.3 or later)");
  }
  return properties;
}
origin: org.domeos/kubernetes-client

public static TrustManager[] trustManagers(Config config) throws CertificateException, NoSuchAlgorithmException, KeyStoreException, IOException {
  return trustManagers(config.getCaCertData(), config.getCaCertFile(), config.isTrustCerts());
}
origin: org.domeos/kubernetes-client

public static SSLContext sslContext(Config config) throws CertificateException, UnrecoverableKeyException, NoSuchAlgorithmException, KeyStoreException, IOException, InvalidKeySpecException, KeyManagementException {
  return sslContext(keyManagers(config), trustManagers(config), config.isTrustCerts());
}
origin: fabric8io/kubernetes-client

public OpenShiftConfig(Config kubernetesConfig, String openShiftUrl, String oapiVersion, long buildTimeout) {
 this(openShiftUrl, oapiVersion, kubernetesConfig.getMasterUrl(), kubernetesConfig.getApiVersion(), kubernetesConfig.getNamespace(), kubernetesConfig.isTrustCerts(), kubernetesConfig.isDisableHostnameVerification(),
  kubernetesConfig.getCaCertFile(), kubernetesConfig.getCaCertData(),
  kubernetesConfig.getClientCertFile(), kubernetesConfig.getClientCertData(),
origin: org.domeos/kubernetes-client

httpClientBuilder.followSslRedirects(true);
if (config.isTrustCerts()) {
  httpClientBuilder.hostnameVerifier(new HostnameVerifier() {
    @Override
KeyManager[] keyManagers = SSLUtils.keyManagers(config);
if (keyManagers != null || trustManagers != null || config.isTrustCerts()) {
  X509TrustManager trustManager = null;
  if (trustManagers != null && trustManagers.length == 1) {
    SSLContext sslContext = SSLUtils.sslContext(keyManagers, trustManagers, config.isTrustCerts());
    httpClientBuilder.sslSocketFactory(sslContext.getSocketFactory(), trustManager);
  } catch (GeneralSecurityException e) {
origin: fabric8io/kubernetes-client

private void assertConfig(Config config) {
 assertNotNull(config);
 assertTrue(config.isTrustCerts());
 assertTrue(config.isDisableHostnameVerification());
 assertEquals("http://somehost:80/", config.getMasterUrl());
origin: org.domeos/kubernetes-client

public void configFromSysPropsOrEnvVars(Config config) {
 config.setTrustCerts(Utils.getSystemPropertyOrEnvVar(KUBERNETES_TRUST_CERT_SYSTEM_PROPERTY, config.isTrustCerts()));
 config.setMasterUrl(Utils.getSystemPropertyOrEnvVar(KUBERNETES_MASTER_SYSTEM_PROPERTY, config.getMasterUrl()));
 config.setApiVersion(Utils.getSystemPropertyOrEnvVar(KUBERNETES_API_VERSION_SYSTEM_PROPERTY, config.getApiVersion()));
origin: io.fabric8/sping-cloud-kubernetes-core

@Bean
@ConditionalOnMissingBean(Config.class)
public Config kubernetesClientConfig() {
  Config base = new Config();
  Config properites = new ConfigBuilder(base)
      //Only set values that have been explicitly specified
      .withMasterUrl(or(properties.getMasterUrl(), base.getMasterUrl()))
      .withMasterUrl(or(properties.getApiVersion(), base.getApiVersion()))
      .withMasterUrl(or(properties.getApiVersion(), base.getMasterUrl()))
      .withUsername(or(properties.getUsername(), base.getUsername()))
      .withPassword(or(properties.getPassword(), base.getPassword()))
      .withCaCertFile(or(properties.getCaCertFile(), base.getCaCertFile()))
      .withCaCertData(or(properties.getCaCertData(), base.getCaCertData()))
      .withClientKeyFile(or(properties.getClientKeyFile(), base.getClientKeyFile()))
      .withClientKeyData(or(properties.getClientKeyData(), base.getClientKeyData()))
      .withClientCertFile(or(properties.getClientCertFile(), base.getClientCertFile()))
      .withClientCertData(or(properties.getClientCertData(), base.getClientCertData()))
      //No magic is done for the properties below so we leave them as is.
      .withClientKeyAlgo(or(properties.getClientKeyAlgo(), base.getClientKeyAlgo()))
      .withClientKeyPassphrase(or(properties.getClientKeyPassphrase(), base.getClientKeyPassphrase()))
      .withConnectionTimeout(or(properties.getConnectionTimeout(), base.getConnectionTimeout()))
      .withRequestTimeout(or(properties.getRequestTimeout(), base.getRequestTimeout()))
      .withRollingTimeout(or(properties.getRollingTimeout(), base.getRollingTimeout()))
      .withTrustCerts(or(properties.isTrustCerts(), base.isTrustCerts()))
      .build();
  if (!base.equals(properites)) {
    System.out.println("Objects different");
  }
  return properites;
}
origin: io.fabric8/spring-cloud-kubernetes-core

@Bean
@ConditionalOnMissingBean(Config.class)
public Config kubernetesClientConfig(KubernetesClientProperties kubernetesClientProperties) {
  Config base = new Config();
  Config properties = new ConfigBuilder(base)
      //Only set values that have been explicitly specified
      .withMasterUrl(or(kubernetesClientProperties.getMasterUrl(), base.getMasterUrl()))
      .withApiVersion(or(kubernetesClientProperties.getApiVersion(), base.getApiVersion()))
      .withNamespace(or(kubernetesClientProperties.getNamespace(), base.getNamespace()))
      .withUsername(or(kubernetesClientProperties.getUsername(), base.getUsername()))
      .withPassword(or(kubernetesClientProperties.getPassword(), base.getPassword()))
      .withCaCertFile(or(kubernetesClientProperties.getCaCertFile(), base.getCaCertFile()))
      .withCaCertData(or(kubernetesClientProperties.getCaCertData(), base.getCaCertData()))
      .withClientKeyFile(or(kubernetesClientProperties.getClientKeyFile(), base.getClientKeyFile()))
      .withClientKeyData(or(kubernetesClientProperties.getClientKeyData(), base.getClientKeyData()))
      .withClientCertFile(or(kubernetesClientProperties.getClientCertFile(), base.getClientCertFile()))
      .withClientCertData(or(kubernetesClientProperties.getClientCertData(), base.getClientCertData()))
      //No magic is done for the properties below so we leave them as is.
      .withClientKeyAlgo(or(kubernetesClientProperties.getClientKeyAlgo(), base.getClientKeyAlgo()))
      .withClientKeyPassphrase(or(kubernetesClientProperties.getClientKeyPassphrase(), base.getClientKeyPassphrase()))
      .withConnectionTimeout(or(kubernetesClientProperties.getConnectionTimeout(), base.getConnectionTimeout()))
      .withRequestTimeout(or(kubernetesClientProperties.getRequestTimeout(), base.getRequestTimeout()))
      .withRollingTimeout(or(kubernetesClientProperties.getRollingTimeout(), base.getRollingTimeout()))
      .withTrustCerts(or(kubernetesClientProperties.isTrustCerts(), base.isTrustCerts()))
      .build();
  if (properties.getNamespace() == null || properties.getNamespace().isEmpty()) {
    LOG.warn("No namespace has been detected. Please specify KUBERNETES_NAMESPACE env var, or use a later kubernetes version (1.3 or later)");
  }
  return properties;
}
origin: org.springframework.cloud/spring-cloud-kubernetes-core

    base.getRollingTimeout()))
.withTrustCerts(or(kubernetesClientProperties.isTrustCerts(),
    base.isTrustCerts()))
.withHttpProxy(or(kubernetesClientProperties.getHttpProxy(),
  base.getHttpProxy()))
origin: io.fabric8/openshift-client

public OpenShiftConfig(Config kubernetesConfig, String openShiftUrl, String oapiVersion, long buildTimeout) {
 this(openShiftUrl, oapiVersion, kubernetesConfig.getMasterUrl(), kubernetesConfig.getApiVersion(), kubernetesConfig.getNamespace(), kubernetesConfig.isTrustCerts(), kubernetesConfig.isDisableHostnameVerification(),
  kubernetesConfig.getCaCertFile(), kubernetesConfig.getCaCertData(),
  kubernetesConfig.getClientCertFile(), kubernetesConfig.getClientCertData(),
io.fabric8.kubernetes.clientConfigisTrustCerts

Popular methods of Config

  • getMasterUrl
  • getOauthToken
  • getNamespace
  • getPassword
  • getUsername
  • getCaCertData
  • getClientCertData
  • getClientKeyData
  • getClientKeyPassphrase
  • getCaCertFile
  • getClientCertFile
  • getClientKeyAlgo
  • getClientCertFile,
  • getClientKeyAlgo,
  • getClientKeyFile,
  • getRequestTimeout,
  • autoConfigure,
  • getApiVersion,
  • getConnectionTimeout,
  • getRollingTimeout,
  • <init>

Popular in Java

  • Finding current android device location
  • getApplicationContext (Context)
  • setScale (BigDecimal)
    Returns a BigDecimal whose scale is the specified value, and whose value is numerically equal to thi
  • getSystemService (Context)
  • BufferedInputStream (java.io)
    Wraps an existing InputStream and buffers the input. Expensive interaction with the underlying input
  • Runnable (java.lang)
    Represents a command that can be executed. Often used to run code in a different Thread.
  • Permission (java.security)
    Abstract class for representing access to a system resource. All permissions have a name (whose inte
  • List (java.util)
    A List is a collection which maintains an ordering for its elements. Every element in the List has a
  • DataSource (javax.sql)
    A factory for connections to the physical data source that this DataSource object represents. An alt
  • JFrame (javax.swing)
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now