diff --git a/docs/sources/docker-hub/builds.md b/docs/sources/docker-hub/builds.md index 164018e82..ac62e4f98 100644 --- a/docs/sources/docker-hub/builds.md +++ b/docs/sources/docker-hub/builds.md @@ -63,13 +63,15 @@ public or private GitHub repositories with a `Dockerfile`. ### GitHub Submodules -If your GitHub repository contains links to private submodules, you'll -need to add a deploy key from your Docker Hub repository. +If your GitHub repository contains links to private submodules, you'll get an +error message in your build. -Your Docker Hub deploy key is located under the "Build Details" -menu on the Automated Build's main page in the Hub. Add this key -to your GitHub submodule by visiting the Settings page for the -repository on GitHub and selecting "Deploy keys". +Normally, the Docker Hub sets up a deploy key in your GitHub repository. +Unfortunately, GitHub only allows a deploy key to access one single repository. + +To work around this, we will be creating a dedicated user account in GitHub to +attach this key to. A key on a GitHub user account can be given read-only +access to all your repositories. @@ -82,15 +84,33 @@ repository on GitHub and selecting "Deploy keys". - - + + - - + + + + + + + + + + + + + + + + +
1.Your automated build's deploy key is in the "Build Details" menu -under "Deploy keys".First, create the new account in GitHub. It should be given read-only + access to the main repository and all submodules that are needed.
2.In your GitHub submodule's repository Settings page, add the -deploy key from your Docker Hub Automated Build.This can be accomplished by adding the account to a read-only team on + the organization(s) where the main GitHub repository and all submodule + repositories are kept.
3.Next, remove the deploy key from the main GitHub repository. This can be done in the GitHub repository's "Deploy keys" Settings section.
4.Your automated build's deploy key is in the "Build Details" menu + under "Deploy keys".
5.In your dedicated GitHub User account, add the deploy key from your + Docker Hub Automated Build.
diff --git a/docs/sources/docker-hub/hub-images/gh_add_ssh_user_key.png b/docs/sources/docker-hub/hub-images/gh_add_ssh_user_key.png new file mode 100644 index 000000000..d3754d826 Binary files /dev/null and b/docs/sources/docker-hub/hub-images/gh_add_ssh_user_key.png differ diff --git a/docs/sources/docker-hub/hub-images/gh_org_members.png b/docs/sources/docker-hub/hub-images/gh_org_members.png new file mode 100644 index 000000000..c04ed7222 Binary files /dev/null and b/docs/sources/docker-hub/hub-images/gh_org_members.png differ diff --git a/docs/sources/docker-hub/hub-images/gh_repo_deploy_key.png b/docs/sources/docker-hub/hub-images/gh_repo_deploy_key.png new file mode 100644 index 000000000..935201284 Binary files /dev/null and b/docs/sources/docker-hub/hub-images/gh_repo_deploy_key.png differ diff --git a/docs/sources/docker-hub/hub-images/gh_team_members.png b/docs/sources/docker-hub/hub-images/gh_team_members.png new file mode 100644 index 000000000..67430fc62 Binary files /dev/null and b/docs/sources/docker-hub/hub-images/gh_team_members.png differ diff --git a/docs/sources/docker-hub/hub-images/github_deploy_key.png b/docs/sources/docker-hub/hub-images/github_deploy_key.png deleted file mode 100644 index a0ec6a918..000000000 Binary files a/docs/sources/docker-hub/hub-images/github_deploy_key.png and /dev/null differ