Skip to content

Instantly share code, notes, and snippets.

View alesj's full-sized avatar
🎯
Focusing

Aleš Justin alesj

🎯
Focusing
View GitHub Profile
com.openshift.restclient.authorization.UnauthorizedException: Unauthorized to access resource. You can access the server using Basic authentication.
at com.openshift.internal.restclient.authorization.OpenShiftAuthorizationRedirectStrategy.isRedirected(OpenShiftAuthorizationRedirectStrategy.java:62)
at org.apache.http.impl.execchain.RedirectExec.execute(RedirectExec.java:111)
at org.apache.http.impl.client.InternalHttpClient.doExecute(InternalHttpClient.java:184)
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:82)
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:106)
at com.openshift.internal.restclient.authorization.AuthorizationClient.getContextUsingCredentials(AuthorizationClient.java:134)
at com.openshift.internal.restclient.authorization.AuthorizationClient.getContext(AuthorizationClient.java:99)
at org.jboss.arquillian.ce.openshift.NativeOpenShiftAdapter.<init>(NativeOpenShiftAdapter.java:91)
WARNING: Exception while deleting pod [{deploymentArchiveName=runinpod.war}]: io.fabric8.kubernetes.client.KubernetesClientException: An error has occurred.
io.fabric8.kubernetes.client.KubernetesClientException: An error has occurred.
at io.fabric8.kubernetes.client.KubernetesClientException.launderThrowable(KubernetesClientException.java:53)
at io.fabric8.kubernetes.client.dsl.base.BaseOperation.cascading(BaseOperation.java:179)
at io.fabric8.kubernetes.client.dsl.base.BaseOperation.cascading(BaseOperation.java:55)
at org.jboss.arquillian.ce.fabric8.F8OpenShiftAdapter.cleanPods(F8OpenShiftAdapter.java:361)
at org.jboss.arquillian.ce.utils.AbstractCEContainer.cleanup(AbstractCEContainer.java:316)
at org.jboss.arquillian.ce.utils.AbstractCEContainer.undeploy(AbstractCEContainer.java:328)
at org.jboss.arquillian.ce.runinpod.RunInPodContainer.undeploy(RunInPodContainer.java:91)
at org.jboss.arquillian.ce.runinpod.RunInPodContainer.undeploy(RunInPodContainer.java:67)
docker version
Client:
Version: 1.9.0
API version: 1.21
Go version: go1.5.1
Git commit: 76d6bc9
Built: Tue Nov 3 21:18:00 UTC 2015
OS/Arch: darwin/amd64
Cannot connect to the Docker daemon. Is the docker daemon running on this host?
Skywalker:maven-code-coverage-plugin alesj$ mvn release:prepare --batch-mode -Drelease -DdevelopmentVersion=1.0.1-SNAPSHOT -DreleaseVersion=1.0.0.Final -Dtag=1.0.0.Final -Dresume=false -Dmaven.javadoc.skip=true
Java HotSpot(TM) 64-Bit Server VM warning: ignoring option MaxPermSize=512M; support was removed in 8.0
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Code Coverage Plugin 1.0.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- maven-release-plugin:2.5:prepare (default-cli) @ code-coverage-maven-plugin ---
[INFO] Verifying that there are no local modifications...
Skywalker:openshift alesj$ oc describe pod eap-app-1-dl6g7 -n vonqzfhm932
Name: eap-app-1-dl6g7
Namespace: vonqzfhm932
Image(s): 172.30.212.5:5000/vonqzfhm932/eap-app@sha256:c17ecbbf531f6571520429da04fe45b4061e7f06537220f825a3b2d6d0900801
Node: ce-os2-rhel-minion-4.usersys.redhat.com/10.34.124.253
Labels: application=eap-app,deployment=eap-app-1,deploymentConfig=eap-app,deploymentconfig=eap-app
Status: Running
Reason:
Message:
IP: 10.1.3.23
com.openshift.restclient.OpenShiftException: Could not create ProjectRequest resource masntozt946 in namespace for subresource null: {
"kind": "Status",
"apiVersion": "v1",
"metadata": {},
"status": "Failure",
"message": "the server could not find the requested resource",
"reason": "NotFound",
"details": {},
"code": 404
}
/Library/Java/JavaVirtualMachines/jdk1.8.0_11.jdk/Contents/Home/bin/java -ea -Djava.io.tmpdir=/Users/alesj/projects/xPaaS/ce-testsuite/wildfly/target -Ddocker.test.namespace=cetesting -Ddocker.username=admin -Ddocker.password=XMwcFzzxU_4fDPritk0-evMbh1AfrKfeSxfqLbjofBs -Dkubernetes.namespace=cetesting -Dkubernetes.ignore.cleanup=true -Dkubernetes.container.pre-stop-ignore=true -Darquillian.startup.timeout=180 -Dzarquillian.debug=true -Didea.launcher.port=7535 "-Didea.launcher.bin.path=/Applications/IntelliJ IDEA 14.app/Contents/bin" -Dfile.encoding=UTF-8 -classpath "/Applications/IntelliJ IDEA 14.app/Contents/lib/idea_rt.jar:/Applications/IntelliJ IDEA 14.app/Contents/plugins/junit/lib/junit-rt.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_11.jdk/Contents/Home/lib/ant-javafx.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_11.jdk/Contents/Home/lib/dt.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_11.jdk/Contents/Home/lib/javafx-mx.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_11.jdk/Contents/Home/lib/jconsole
public String deployReplicationController(String name, Map<String, String> deploymentLabels, String imageName, List<Port> ports, int replicas, HookType hookType, String preStopPath, boolean ignorePreStop) throws Exception {
String apiVersion = configuration.getApiVersion();
List<ContainerPort> cps = new ArrayList<>();
for (Port port : ports) {
ContainerPort cp = new ContainerPort();
cp.setName(port.getName());
cp.setContainerPort(port.getContainerPort());
cps.add(cp);
}
public Object processTemplateAndCreateResources(String name, String templateURL, String namespace, List<ParamValue> values) throws Exception {
final IProject project = client.get(ResourceKind.PROJECT, configuration.getNamespace(), "default");
final ITemplate template;
try (InputStream stream = new URL(templateURL).openStream()) {
template = client.getResourceFactory().create(stream);
}
Collection<IParameter> parameters = new HashSet<>();
for (ParamValue pv : values) {
Skywalker:openshift alesj$ oc new-project qq1 --v=8
I1021 15:57:52.219485 13581 debugging.go:98] GET https://ce-os2-rhel-master.usersys.redhat.com:8443/api
I1021 15:57:52.219577 13581 debugging.go:105] Request Headers:
I1021 15:57:52.219582 13581 debugging.go:108] User-Agent: oc/v1.1.0 (darwin/amd64) kubernetes/44c91b1
I1021 15:57:52.219595 13581 debugging.go:108] Authorization: Bearer FL0oZfKou9FJGKVz4Vzd8HrmoPcariwWlFR2p50ZqXQ
I1021 15:57:52.829039 13581 debugging.go:123] Response Status: 200 OK in 609 milliseconds
I1021 15:57:52.829081 13581 debugging.go:126] Response Headers:
I1021 15:57:52.829090 13581 debugging.go:129] Content-Length: 47
I1021 15:57:52.829097 13581 debugging.go:129] Cache-Control: no-store
I1021 15:57:52.829104 13581 debugging.go:129] Content-Type: application/json