I have a personal account, on Docker Hub, linked to my GitHub account, where I can build an image of my repository normally.
Now I've created an organization on GitHub where I've forked my code. I've also created an organization on Docker Hub using my personal account, and created a repository in this organization. But I can't seem to figure out how to trigger a build in this repository!
I don't have access to the same menus, I don't know what I'm missing here. Any clue? Thanks.
I think you have to create an 'Automated build', not a simple repository.
In the top left of the UI, go to 'Create' > 'Create Automated Build', then select Github or Bitbucket, select the source repository, then for the 'Repository Namespace & Name' I guess that you should be able to choose your organization for the namespace.
Of course you have to deleted the simple repository you created if you want to use the same repository name.
Related
I'm trying to build my Docker image with GitHub action using the official docker/build-push-action action. The action provides secret GIT_AUTH_TOKEN for the build by default but I seem not to be able to use the token to read another private repository from the same organization (install pip package). The same Dockerfile builds fine locally when I provide a working token for the build.
Am I supposed to be able to use the default GIT_AUTH_TOKEN or do I need to retrieve a token from Secrets Manager as we do on Jenkins that I'm trying to get rid of. Thanks for your help!
You have to generate a different PAT to clone the other repo. Bring that token in as a secret and use it in your workflow to checkout
I also must conclude after further testing and research that the github provided workflow token gives privileges to the current repository only.
Since two days, i don't know why, i cannot build a docker image from Docker Hub Registry with linked github projects (it's working previously)
Many answers were about a github submodule
It was not my case.
Here are the logs
Building in Docker Cloud's infrastructure...
Cloning into '.'...
Warning: Permanently added the RSA host key for IP address '192.30.253.113' to the list of known hosts.
Permission denied (publickey).
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
please ensure the correct public key is added to the list of trusted keys for this repository (128)
I tried searching, I did not fall on the answers that not concerned me.
After many hours of searching, I think found the answer.
I put here the answer, for those who would fall on the same problem.
It looks like Docker have changed is the name of his app. Rename from Docker Hub Registry to Docker Hub Builder
For repair it, so I cut the application link between Docker and Github. And re-create the link.
It added me an application for authorization in Github, the proof in image width Docker Hub Builder
May someone need this. For me, clicking the re-link button for the GitHub account on the Docker-Hub solved the problem.
You can re-link in this page: https://hub.docker.com/settings/linked-accounts
First, try re-linking your GitHub account to Docker Hub and checking your GitHub org's 'Third party application access policy', as suggested by the previous answers.
If your Docker Hub repository is owned by an organisation, visit the organisation's Linked Accounts settings and try re-linking the provider:
If that doesn't solve the issue, visit your Docker Hub repository > Builds > Configure Automated Builds, then look at the Source repository list:
This will show you which repositories Docker Hub has access to.
In my case, some repositories were missing from the list because Docker Hub could only see repositories that the linked GitHub account had admin access to.
Conclusion: the GitHub account linked with Docker Hub needs admin access to the relevant GitHub repository.
Giving the GitHub account admin access to the relevant repository fixed my Docker Hub builds.
So I have an application called SongKong, I wanted to build a Docker image for it. Within hub.docker.com you can link to a repository containing Dockerfile and build from it, I do not want to call this repos songkong because I already have a songkong repo for the actual application code. So I called the repo songkongdocker but now my hub.docker.com repo is called songkongdocker, it would seem that hub.docker repos are usually named after the application so ideally should just be songkong
So, what is the correct way to name and can my Bitbucket code repository have a different name then the hub.docker.com repository ?
You can change build/repo name when you are creating an Automated build on hub.docker.com. Bitbucket/Github repo name is used as a default name, but you can still edit it.
I am having trouble creating a new automated build in Dockerhub, using the Github link.
I cannot create an automated build from my Github account link that is already building against another repo. It is currently linking to the same account in Github that one of my Dockerhub builds is already using, but when I try to create a new automated build it does not display any linked accounts. I then go through the process of linking, which then tells me its already linked.
No idea whats up with this but its super annoying.
I ended up solving this by un-linking then re-linking my github account. It is now working fine.
I pushed a container onto my project in docker registry hub,
there are two tabs Information and Tags,
how could I add the Information for my container ?
The information tab is filled when you set up an auto build that builds a Dockerfile that is hosted on your github account. It simply takes the README.md contents of your github project.
The tags tab is filled when you configure your auto build to assign tags to different branches of your github project.
As an example please have a look at this docker hub page and this github project.