Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot pull from private repo #567

Closed
iNikem opened this issue Jan 30, 2018 · 10 comments
Closed

Cannot pull from private repo #567

iNikem opened this issue Jan 30, 2018 · 10 comments

Comments

@iNikem
Copy link
Contributor

iNikem commented Jan 30, 2018

I use an image from private repository: new FixedHostPortGenericContainer('plumbr-dockerv2-local.jfrog.io/kafka:latest'). And it fails:

Caused by: org.testcontainers.containers.ContainerFetchException: Can't get Docker image name from org.testcontainers.images.RemoteDockerImage@24ce9f81
	at org.testcontainers.containers.GenericContainer.getDockerImageName(GenericContainer.java:856)
	at org.testcontainers.containers.GenericContainer.setDockerImageName(GenericContainer.java:844)
	at org.testcontainers.containers.GenericContainer.<init>(GenericContainer.java:170)
	at org.testcontainers.containers.FixedHostPortGenericContainer.<init>(FixedHostPortGenericContainer.java:16)
	at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
	at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
	at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
	at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
	at org.codehaus.groovy.reflection.CachedConstructor.invoke(CachedConstructor.java:83)
	at org.codehaus.groovy.runtime.callsite.ConstructorSite$ConstructorSiteNoUnwrapNoCoerce.callConstructor(ConstructorSite.java:105)
	at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallConstructor(CallSiteArray.java:60)
	at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callConstructor(AbstractCallSite.java:235)
	at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callConstructor(AbstractCallSite.java:247)
	at eu.plumbr.archive.archivist.kafka.KafkaArchivistIntegrationTest.<clinit>(KafkaArchivistIntegrationTest.groovy:34)
	... 37 more
Caused by: com.github.dockerjava.api.exception.InternalServerErrorException: {"message":"unauthorized: The client does not have permission for manifest"}

	at com.github.dockerjava.netty.handler.HttpResponseHandler.channelRead0(HttpResponseHandler.java:109)
	at com.github.dockerjava.netty.handler.HttpResponseHandler.channelRead0(HttpResponseHandler.java:33)
	at org.testcontainers.shaded.io.netty.channel.SimpleChannelInboundHandler.channelRead(SimpleChannelInboundHandler.java:105)
	at org.testcontainers.shaded.io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:362)
	at org.testcontainers.shaded.io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:348)
	at org.testcontainers.shaded.io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:340)
	at org.testcontainers.shaded.io.netty.handler.logging.LoggingHandler.channelRead(LoggingHandler.java:241)
	at org.testcontainers.shaded.io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:362)
	at org.testcontainers.shaded.io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:348)
	at org.testcontainers.shaded.io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:340)
	at org.testcontainers.shaded.io.netty.channel.CombinedChannelDuplexHandler$DelegatingChannelHandlerContext.fireChannelRead(CombinedChannelDuplexHandler.java:438)
	at org.testcontainers.shaded.io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:310)
	at org.testcontainers.shaded.io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:284)
	at org.testcontainers.shaded.io.netty.channel.CombinedChannelDuplexHandler.channelRead(CombinedChannelDuplexHandler.java:253)
	at org.testcontainers.shaded.io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:362)
	at org.testcontainers.shaded.io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:348)
	at org.testcontainers.shaded.io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:340)
	at org.testcontainers.shaded.io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1334)
	at org.testcontainers.shaded.io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:362)
	at org.testcontainers.shaded.io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:348)
	at org.testcontainers.shaded.io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:926)
	at org.testcontainers.shaded.io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:134)
	at org.testcontainers.shaded.io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:644)
	at org.testcontainers.shaded.io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:579)
	at org.testcontainers.shaded.io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:496)
	at org.testcontainers.shaded.io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:458)
	at org.testcontainers.shaded.io.netty.util.concurrent.SingleThreadEventExecutor$5.run(SingleThreadEventExecutor.java:858)
	at org.testcontainers.shaded.io.netty.util.concurrent.DefaultThreadFactory$DefaultRunnableDecorator.run(DefaultThreadFactory.java:138)
	... 1 more
@iNikem
Copy link
Contributor Author

iNikem commented Jan 30, 2018

With new 1.6.0 release

@iNikem
Copy link
Contributor Author

iNikem commented Jan 30, 2018

Same problem with 1.5.1

@kiview
Copy link
Member

kiview commented Jan 30, 2018

Is this happening on OSX?

@iNikem
Copy link
Contributor Author

iNikem commented Jan 30, 2018

Yes, OS X El Capitan, 10.11.6

@rnorth
Copy link
Member

rnorth commented Feb 3, 2018

@iNikem without revealing any secrets, please could you share the rough content of your ~/docker/config.json file? I'm curious as to which credsStore implementation you have active.

FWIW I've not had any trouble with the AWS ECR registry at work, and I think my work machine has the osxkeychain set as its credsStore type.

@iNikem
Copy link
Contributor Author

iNikem commented Feb 5, 2018

Here it is.

{
  "auths" : {
    "https://plumbr-dockerv2-local.jfrog.io" : {

    },
    "plumbr-dockerv2-local.jfrog.io" : {

    }
  },
  "HttpHeaders" : {
    "User-Agent" : "Docker-Client/17.12.0-ce (darwin)"
  },
  "credsStore" : "osxkeychain"
}

I think it did work. Will try to investigate what broke :)

@rnorth
Copy link
Member

rnorth commented Feb 8, 2018

Hi @iNikem, did you get to the bottom of this?

@iNikem
Copy link
Contributor Author

iNikem commented Feb 8, 2018

Nope. Have not found any workarounds (apart from doing docker pull by hand prior the test) nor any actual root causes.

@rnorth
Copy link
Member

rnorth commented Jun 15, 2018

We should have this fixed shortly in #729!

@rnorth
Copy link
Member

rnorth commented Jul 12, 2018

We released support for docker credential helpers/store in 1.8.1! 🎉

Please could you give this a try @iNikem?

@rnorth rnorth closed this as completed Jul 12, 2018
rnorth pushed a commit that referenced this issue Mar 10, 2019
Bumps [neo4j-java-driver](https://github.com/neo4j/neo4j-java-driver) from 1.7.2 to 1.7.3.
<details>
<summary>Commits</summary>

- [`742d280`](neo4j/neo4j-java-driver@742d280) Merge pull request [#567](https://github-redirect.dependabot.com/neo4j/neo4j-java-driver/issues/567) from ali-ince/1.7-pass-access-mode
- [`49ef4db`](neo4j/neo4j-java-driver@49ef4db) Fixing wrong file header
- [`f66e194`](neo4j/neo4j-java-driver@f66e194) Merge pull request [#570](https://github-redirect.dependabot.com/neo4j/neo4j-java-driver/issues/570) from zhenlineo/1.7-flaky-test
- [`5b58956`](neo4j/neo4j-java-driver@5b58956) Fixing the flaky test that is caused by certificate file changes.
- [`f9a6fca`](neo4j/neo4j-java-driver@f9a6fca) Merge pull request [#569](https://github-redirect.dependabot.com/neo4j/neo4j-java-driver/issues/569) from michael-simons/fix-java-doc-trust-strategy
- [`bc68f0f`](neo4j/neo4j-java-driver@bc68f0f) Merge pull request [#566](https://github-redirect.dependabot.com/neo4j/neo4j-java-driver/issues/566) from zhenlineo/1.7-hostname-for-sni
- [`41949fc`](neo4j/neo4j-java-driver@41949fc) Fix JavaDoc of withTrustStrategy.
- [`227c0fc`](neo4j/neo4j-java-driver@227c0fc) Fix test failure
- [`11345c1`](neo4j/neo4j-java-driver@11345c1) Pass access mode as part of statement metadata
- [`e9e5a93`](neo4j/neo4j-java-driver@e9e5a93) Fix some test failures due to changes to routing table procedure on read-repl...
- Additional commits viewable in [compare view](neo4j/neo4j-java-driver@1.7.2...1.7.3)
</details>
<br />

[![Dependabot compatibility score](https://api.dependabot.com/badges/compatibility_score?dependency-name=org.neo4j.driver:neo4j-java-driver&package-manager=gradle&previous-version=1.7.2&new-version=1.7.3)](https://dependabot.com/compatibility-score.html?dependency-name=org.neo4j.driver:neo4j-java-driver&package-manager=gradle&previous-version=1.7.2&new-version=1.7.3)

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`.

[//]: # (dependabot-automerge-start)
If all status checks pass Dependabot will automatically merge this pull request.

[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot ignore this [patch|minor|major] version` will close this PR and stop Dependabot creating any more for this minor/major version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
- `@dependabot badge me` will comment on this PR with code to add a "Dependabot enabled" badge to your readme

Additionally, you can set the following in the `.dependabot/config.yml` file in this repo:
- Update frequency (including time of day and day of week)
- Automerge options (never/patch/minor, and dev/runtime dependencies)
- Pull request limits (per update run and/or open at any time)
- Out-of-range updates (receive only lockfile updates, if desired)
- Security updates (receive only security updates, if desired)

Finally, you can contact us by mentioning @dependabot.

</details>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants