I'm trying to create a custom demo to illustrate the whole fabric8 build/deploy/run process to OSEv3 with 2 plugins docker-maven-plugins (org.jolokia) & fabric8-maven-plugin (io.fabric8)
The build was complete successfully with below command
# mvn clean install docker:build
where I can see the .zip created at /target/seminar-rest-1.0.0-image.zip
But I'm quite puzzled on the next step which is supposed to push the build to OSEv3's docker repository.
The 'mvn docker:push' doesn't seem to work for me ... it always shows me 403 error in regardless of docker.username & docker.password given. (log attached)
Caused by: org.apache.maven.plugin.MojoExecutionException: Error: Status 403 trying to push repository demo/seminar-rest: "{\n \"kind\": \"Status\",\n \"apiVersion\": \"v1\",\n \"metadata\": {},\n \"status\": \"Failure\",\n \"message\": \"User \\\"system:anonymous\\\" cannot \\\"put\\\" on \\\"/v1/repositories/demo/seminar-rest/\\\"\",\n \"reason\": \"Forbidden\",\n \"details\": {},\n \"code\": 403\n}"
at org.jolokia.docker.maven.AbstractDockerMojo.execute(AbstractDockerMojo.java:137)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
... 20 more
Caused by: org.jolokia.docker.maven.access.DockerAccessException: Error: Status 403 trying to push repository demo/seminar-rest: "{\n \"kind\": \"Status\",\n \"apiVersion\": \"v1\",\n \"metadata\": {},\n \"status\": \"Failure\",\n \"message\": \"User \\\"system:anonymous\\\" cannot \\\"put\\\" on \\\"/v1/repositories/demo/seminar-rest/\\\"\",\n \"reason\": \"Forbidden\",\n \"details\": {},\n \"code\": 403\n}"
at org.jolokia.docker.maven.access.chunked.PullOrPushResponseHandler.process(PullOrPushResponseHandler.java:39)
at org.jolokia.docker.maven.access.chunked.PullOrPushResponseHandler.process(PullOrPushResponseHandler.java:7)
at org.jolokia.docker.maven.access.chunked.TextToJsonBridgeCallback.process(TextToJsonBridgeCallback.java:23)
at org.jolokia.docker.maven.access.chunked.TextToJsonBridgeCallback.process(TextToJsonBridgeCallback.java:9)
at org.jolokia.docker.maven.access.chunked.ChunkedResponseReader.process(ChunkedResponseReader.java:25)
at org.jolokia.docker.maven.access.hc.DockerAccessWithHcClient.processChunkedResponse(DockerAccessWithHcClient.java:472)
at org.jolokia.docker.maven.access.hc.DockerAccessWithHcClient.pushImage(DockerAccessWithHcClient.java:243)
at org.jolokia.docker.maven.PushMojo.executeInternal(PushMojo.java:30)
at org.jolokia.docker.maven.AbstractDockerMojo.execute(AbstractDockerMojo.java:135)
... 22 more
** Due to this, the 'mvn fabric8:json fabric8:apply' couldn't start the application properly with error
Failed to pull image "demo/seminar-rest:1.0.0": Error: image demo/seminar-rest:1.0.0 not found
I'm pretty sure that I'm missing some things, but perhaps I'm not experienced enough with the 2 plugins.
Much appreciate if someone can shed some lights on this.
Thank you in advance.
Regards,
-An