Alexander Larsson
946f83d348
Add support for client certificates for registries
...
This lets you specify custom client TLS certificates and CA root for a
specific registry hostname. Docker will then verify the registry
against the CA and present the client cert when talking to that
registry. This allows the registry to verify that the client has a
proper key, indicating that the client is allowed to access the
images.
A custom cert is configured by creating a directory in
/etc/docker/certs.d with the same name as the registry hostname. Inside
this directory all *.crt files are added as CA Roots (if none exists,
the system default is used) and pair of files <filename>.key and
<filename>.cert indicate a custom certificate to present to the registry.
If there are multiple certificates each one will be tried in
alphabetical order, proceeding to the next if we get a 403 of 5xx
response.
So, an example setup would be:
/etc/docker/certs.d/
└── localhost
├── client.cert
├── client.key
└── localhost.crt
A simple way to test this setup is to use an apache server to host a
registry. Just copy a registry tree into the apache root, here is an
example one containing the busybox image:
http://people.gnome.org/~alexl/v1.tar.gz
Then add this conf file as /etc/httpd/conf.d/registry.conf:
# This must be in the root context, otherwise it causes a re-negotiation
# which is not supported by the tls implementation in go
SSLVerifyClient optional_no_ca
<Location /v1>
Action cert-protected /cgi-bin/cert.cgi
SetHandler cert-protected
Header set x-docker-registry-version "0.6.2"
SetEnvIf Host (.*) custom_host=$1
Header set X-Docker-Endpoints "%{custom_host}e"
</Location>
And this as /var/www/cgi-bin/cert.cgi
#!/bin/bash
if [ "$HTTPS" != "on" ]; then
echo "Status: 403 Not using SSL"
echo "x-docker-registry-version: 0.6.2"
echo
exit 0
fi
if [ "$SSL_CLIENT_VERIFY" == "NONE" ]; then
echo "Status: 403 Client certificate invalid"
echo "x-docker-registry-version: 0.6.2"
echo
exit 0
fi
echo "Content-length: $(stat --printf='%s' $PATH_TRANSLATED)"
echo "x-docker-registry-version: 0.6.2"
echo "X-Docker-Endpoints: $SERVER_NAME"
echo "X-Docker-Size: 0"
echo
cat $PATH_TRANSLATED
This will return 403 for all accessed to /v1 unless *any* client cert
is presented. Obviously a real implementation would verify more details
about the certificate.
Example client certs can be generated with:
openssl genrsa -out client.key 1024
openssl req -new -x509 -text -key client.key -out client.cert
Docker-DCO-1.1-Signed-off-by: Alexander Larsson <alexl@redhat.com > (github: alexlarsson)
Upstream-commit: 05243104fc0a0ef9537766cf5bd920824665eb78
Component: engine
2014-06-13 11:13:18 +02:00
Michael Crosby
5a4d61b92a
Merge pull request #6214 from LK4D4/fix_some_more_race_conditions
...
Fix some more race conditions
Upstream-commit: 51b188c5102e86ad453c933077bcaf9594070c28
Component: engine
2014-06-12 15:17:10 -07:00
Tibor Vass
28b97cf916
Merge pull request #6391 from vieux/fix_hostname_file_net_host
...
fix hostname generation with --net=host
Upstream-commit: 8091157038fe582d5d674cc743c87b808036d80d
Component: engine
2014-06-12 14:11:26 -07:00
Michael Crosby
4c7bb47c22
Merge pull request #6381 from glyn/prod-ready
...
Remove "production ready" from the roadmap
Upstream-commit: d871725cf267e986e29fed4360b3a46a964b9bd4
Component: engine
2014-06-12 14:02:51 -07:00
Victor Vieux
dab360c397
Merge pull request #6360 from vieux/remove_beam
...
remove unused beam, will be back later as libchan
Upstream-commit: f9f6379a533adefddef367b9310e91c8c21c2727
Component: engine
2014-06-12 13:55:53 -07:00
Victor Vieux
e3ce3684c5
Merge pull request #6365 from vieux/allow_net_none_h
...
Allow --net=none and -h
Upstream-commit: 15243cdbde92018b7dc59e5d17edebe895fb0b4b
Component: engine
2014-06-12 12:26:54 -07:00
Victor Vieux
c99ab31438
add hostname generation with --net=host
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <vieux@docker.com > (github: vieux)
Upstream-commit: f5979b9d0dd993a00e064114218ccdbfdaab9fe0
Component: engine
2014-06-12 19:20:57 +00:00
Victor Vieux
13764748a8
add test
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <vieux@docker.com > (github: vieux)
Upstream-commit: 9494643bf1fcd38974266555e59e1b2d2573c418
Component: engine
2014-06-12 19:11:51 +00:00
Michael Crosby
5591b84fff
Merge pull request #6307 from W4RH4WK/master
...
restore logo for README.md
Upstream-commit: a8d6d28be4d1a9a5393ee7a268c964c555fc93c5
Component: engine
2014-06-12 10:21:10 -07:00
Glyn Normington
f612478eca
Remove "production ready" from the roadmap
...
It's done as of v1.0.0.
Docker-DCO-1.1-Signed-off-by: Glyn Normington <gnormington@gopivotal.com > (github: glyn)
Upstream-commit: 784a008346e9d0e3829bd08b6fc07cdcfc09bd82
Component: engine
2014-06-12 14:21:20 +01:00
O.S. Tezer
f2a648f243
Merge pull request #6372 from ostezer/docs-fix-logged-in-hdr
...
Docs: Fixed logged-in header username label target
Upstream-commit: dbee7dd69eeee8d740de4ded34c3cf4c422329ca
Component: engine
2014-06-12 01:17:38 -07:00
Tianon Gravi
842778e1c8
Merge pull request #6361 from asbjornenge/tmlang_copy
...
Add contribute/syntax highlight for the COPY instruction
Upstream-commit: 3b9e8679db5c312ab28048a10050ef085445bb67
Component: engine
2014-06-12 00:06:51 -07:00
Asbjørn Enge
3174a5ef95
Added highlight for the COPY instruction
...
Docker-DCO-1.1-Signed-off-by: Asbjorn Enge <asbjorn@hanafjedle.net > (github: asbjornenge)
Upstream-commit: cb47ddd968747091fd1b3d408dd36c4c2086e69f
Component: engine
2014-06-12 08:25:09 +02:00
O.S. Tezer
67655304d5
Docs: Fixed logged-in header username label target
...
Docker-DCO-1.1-Signed-off-by: O.S. Tezer <ostezer@gmail.com > (github: ostezer)
Upstream-commit: 4ccd91f0d8052ada203e2551b11121613d54f44a
Component: engine
2014-06-11 18:09:43 -07:00
Michael Crosby
455e8c968c
Merge pull request #6060 from dineshs-altiscale/maintainers
...
Add Dinesh Subhraveti to MAINTAINERS
Upstream-commit: c99ee556d4e9a028fa68b40816b75200be690534
Component: engine
2014-06-11 14:37:01 -07:00
Victor Vieux
1a7abd252b
add tests
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <vieux@docker.com > (github: vieux)
Upstream-commit: 6cb16f1c316c55e3b6108d178ffcde2e705cbe47
Component: engine
2014-06-11 21:15:48 +00:00
Victor Vieux
62d142653c
Allow --net=none & -h
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <vieux@docker.com > (github: vieux)
Upstream-commit: f411f8bfc5d04aed6499dfc90e357c58713bc84d
Component: engine
2014-06-11 21:07:50 +00:00
Victor Vieux
99dc4301cc
remove unused beam, will be back later as libchan
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <vieux@docker.com > (github: vieux)
Upstream-commit: 384b60b940e07d37c1ff544168a2407513114d80
Component: engine
2014-06-11 19:09:55 +00:00
Michael Crosby
95ca86414e
Merge pull request #6335 from levigross/master
...
Fixed up if statement
Upstream-commit: 9ac293e1a8e1463f3fac1713213c9d250642ace8
Component: engine
2014-06-11 11:51:57 -07:00
Michael Crosby
1ddec5f792
Merge pull request #6357 from crosbymichael/vendor-libcontainer
...
Vendor libcontainer
Upstream-commit: 6c953a305976c8270d8d5f2b14a169bc21703abb
Component: engine
2014-06-11 10:57:39 -07:00
unclejack
5cc0b3dff6
Merge pull request #6277 from philips/remove-unneeded-time-duration
...
registry: remove unneeded time.Duration()
Upstream-commit: 8f909221f51a4b1d23f5829b68debd0782293cc7
Component: engine
2014-06-11 20:33:22 +03:00
James Turnbull
89cd4745de
Merge pull request #6351 from lenw/patch-1
...
minor spelling fix
Upstream-commit: 96c03d6d920c87305bdb8abfd188de71aaaf8bb5
Component: engine
2014-06-11 06:55:33 -07:00
James Turnbull
3b1b01d0f2
Merge pull request #6349 from chrismckinnel/master
...
Fix some bullet points so they render correctly.
Upstream-commit: a092f979d44163692e98d67f65063b9ee35abbeb
Component: engine
2014-06-11 06:54:44 -07:00
Alexandr Morozov
f9497861c8
Fix race in LogEvent
...
Docker-DCO-1.1-Signed-off-by: Alexandr Morozov <lk4d4math@gmail.com > (github: LK4D4)
Upstream-commit: a1b7a35c90f05b113b7c3aa474b74d1d2afbf7b6
Component: engine
2014-06-11 15:23:33 +04:00
Alexandr Morozov
5c1bb534bb
Fix race in get/set HostConfig
...
Docker-DCO-1.1-Signed-off-by: Alexandr Morozov <lk4d4math@gmail.com > (github: LK4D4)
Upstream-commit: fa7c8d523e8d899ade547fcaacc34a739ab5044f
Component: engine
2014-06-11 15:23:33 +04:00
Alexandr Morozov
ab194686ba
Fix race in contStore.List
...
Docker-DCO-1.1-Signed-off-by: Alexandr Morozov <lk4d4math@gmail.com > (github: LK4D4)
Upstream-commit: 0b3fe5544266b6f9657ecd87989b85b535cc63e1
Component: engine
2014-06-11 15:23:33 +04:00
Len Weincier
f73a57c5b6
minor spelling fix
...
Upstream-commit: db00e224c2ae76096490c29357ef041ded7fadfc
Component: engine
2014-06-11 13:16:53 +02:00
chrismckinnel
30903b9316
Fix some bullet points so they render correctly.
...
Upstream-commit: a247af9c97be92f91242db51f4a9545db1bda702
Component: engine
2014-06-11 11:44:30 +01:00
Michael Crosby
6c66f51853
Use libcontainer version tag for vendor script
...
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com > (github: crosbymichael)
Upstream-commit: d1757c005f05c76b31615d1d4d27722faee8012e
Component: engine
2014-06-10 20:23:05 -07:00
Michael Crosby
52b8a282c3
Update libcontainer imports
...
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com > (github: crosbymichael)
Upstream-commit: 8194556337b65dda71a3d4d7f6ae9653ad5a19a0
Component: engine
2014-06-10 19:58:15 -07:00
Michael Crosby
b8d91613b1
Remove and vendor libcontainer
...
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com > (github: crosbymichael)
Upstream-commit: 8a8b6d79649f666dd00f2efd60f773bb3eed898d
Component: engine
2014-06-10 19:49:57 -07:00
James Turnbull
b71d34e96b
Merge pull request #6339 from ostezer/docs-fix-css-title-conflict
...
docs: Fix docs' styling conflict with common names
Upstream-commit: 4cf40c968f072d51272217b30ef2b8f5cba55ffe
Component: engine
2014-06-10 13:40:22 -07:00
O.S. Tezer
0e782ce982
docs: Fix docs' styling conflict with common names
...
Docker-DCO-1.1-Signed-off-by: O.S. Tezer <ostezer@gmail.com > (github: ostezer)
Closes issue #6329
Upstream-commit: cb40e3302e41c62d17a4d7c1935dd28e64ee2748
Component: engine
2014-06-10 11:18:20 -07:00
James Turnbull
84ab25456a
Merge pull request #6322 from crucerucalin/master
...
Repaired broken links in docs/sources/faq.md
Upstream-commit: 9a7bd6d95b42d89db4c005e6fcbc0535f4031bfb
Component: engine
2014-06-10 08:46:42 -07:00
Sven Dowideit
5e91e03e8e
Merge pull request #6315 from erikh/ubuntu-latest-install-docs
...
Improve documentation on Ubuntu for getting the latest release of docker.
Upstream-commit: 9254a62cd612f2d1383c249f5a3c72354cf22b08
Component: engine
2014-06-11 00:54:52 +10:00
Sven Dowideit
f41579c1d4
Merge pull request #6300 from whatthejeff/patch-1
...
Avoid history expansion.
Upstream-commit: b83a171f9e4851040724ae44d39ba371a80310c4
Component: engine
2014-06-11 00:49:29 +10:00
Tianon Gravi
4e8352c6cd
Merge pull request #6252 from tianon/update-check-config
...
Update contrib/check-config.sh to check for CGROUP_FREEZER and to use /proc/mounts
Upstream-commit: 5ff3a28cb4955b5d933c17d0d9c6f8f0b6267d7d
Component: engine
2014-06-10 08:09:34 -06:00
Levi Gross
bef7d7d621
Fixed up if statement
...
Signed-off-by: Levi Gross <levi@levigross.com >
Docker-DCO-1.1-Signed-off-by: Levi Gross <levi@levigross.com > (github: levigross)
Upstream-commit: a7b60b21deaf7dbc3b5741be036bfb2a6679f1c8
Component: engine
2014-06-10 10:02:00 -04:00
Cruceru Calin-Cristian
9b5969a515
Repaired broken links
...
Docker-DCO-1.1-Signed-off-by: Calin Cruceru <crucerucalincristian@gmail.com > (github: crucerucalin)
Upstream-commit: 53802d54d6e2d322f4cd13e2cc6c294e73ef8b4e
Component: engine
2014-06-10 08:21:12 +03:00
Erik Hollensbe
3ad02e9ae6
Improve documentation on Ubuntu for getting the latest release of
...
docker.
Docker-DCO-1.1-Signed-off-by: Erik Hollensbe <github@hollensbe.org > (github: erikh)
Upstream-commit: 7ab1a90e59b34abda1d2ffa1dd6683302927d9ec
Component: engine
2014-06-09 18:31:46 -07:00
unclejack
70824b0aaa
Merge pull request #6317 from crosbymichael/libcontainerdep
...
Move libcontainer deps into libcontainer
Upstream-commit: fb2ac5bedb4e3e3d624dd8f4a4c595e066138a51
Component: engine
2014-06-10 03:16:15 +03:00
Michael Crosby
b00f7d0626
Gofmt imports
...
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com > (github: crosbymichael)
Upstream-commit: bae6a5a616cfc382f45a25af13633681875ddff0
Component: engine
2014-06-09 16:01:57 -07:00
Michael Crosby
3c7670e68c
Move libcontainer deps into libcontainer
...
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com > (github: crosbymichael)
Upstream-commit: 6158ccad97db51e756aafefb096d1163aa4d6439
Component: engine
2014-06-09 15:52:12 -07:00
Jeff Welch
5c1c8409ec
Avoid history expansion.
...
Docker-DCO-1.1-Signed-off-by: Jeff Welch <whatthejeff@gmail.com > (github: whatthejeff)
Upstream-commit: 052ad32a7b0dc93dafe7a27034b6911d6a71e849
Component: engine
2014-06-09 17:30:34 -04:00
Alex Warhawk
a504b7f947
restore logo for README.md
...
Docker-DCO-1.1-Signed-off-by: Alex Hirsch <ax.warhawk@gmail.com > (github: W4RH4WK)
Upstream-commit: cacb5c0ddeb75a26c7687d3c4887d3eb998b104e
Component: engine
2014-06-09 22:15:13 +02:00
Michael Crosby
2cf64a9662
Merge pull request #6305 from crosbymichael/merge_release_v1.0.0
...
Merge release v1.0.0
Upstream-commit: fd32fc80625c8e608332f48d69c1801c23a6ffa4
Component: engine
2014-06-09 07:17:43 -07:00
Michael Crosby
5b45d1841a
Change version to v1.0.0-dev
...
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com > (github: crosbymichael)
Upstream-commit: faf5ef6f80632db948e112fcb1e29a53562ad0c8
Component: engine
2014-06-09 07:14:51 -07:00
Michael Crosby
8845816a75
Merge branch 'release' into merge_release_v1.0.0
...
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com > (github: crosbymichael)
Upstream-commit: 07e9ac9ffedc07b92ac446fc6a9e7ad1f21e3301
Component: engine
2014-06-09 07:14:40 -07:00
Michael Crosby
76b1ae4677
Merge pull request #6303 from crosbymichael/bump_v1.0.0
...
Bump version to v1.0.0
Upstream-commit: d9939758e6a02cbd42e01635166fc168ef0470dd
Component: engine
2014-06-09 07:12:42 -07:00
James Turnbull
c87123a2be
Merge pull request #6302 from Costent/patch-1
...
Update windows.md
Upstream-commit: 5dc6339e33452ed071fe5f93d49d0f6068ff106d
Component: engine
2014-06-09 06:14:16 -07:00