Commit graph

2535 commits

Author SHA1 Message Date
Andrey Kostov
da5510b55e Add an empty root directory s3 driver specific test 2015-02-19 16:28:32 -08:00
Stephen Day
4c2a490ff0 Merge pull request #177 from stevvooe/update-depenendencies
Godeps, Makefile, mailmap: add missing dependencies, dist binary build
2015-02-16 16:15:36 -08:00
Stephen J Day
8865a1ba3c Add dist binary target to Makefile
Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-02-16 14:25:17 -08:00
Stephen J Day
fd2179d52b Update mailmap file with some new aliases
Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-02-16 14:21:28 -08:00
Stephen J Day
c1acc0a168 Update dependencies missing in older PR
Some dependencies in a PR from an older branch broke the master build. The
change adds the missing dependencies and updates some others.

Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-02-16 14:19:00 -08:00
Stephen Day
61fb9ae16a Merge pull request #174 from stevvooe/registry-interface-improvements
Add error return to Repository method on Registry
2015-02-16 12:05:07 -08:00
Stephen Day
244c19b850 Merge pull request #45 from icecrime/dist_binary_skeleton
Basic skeleton for `dist` binary
2015-02-13 16:30:31 -08:00
Stephen J Day
5d029fb807 Add error return to Repository method on Registry
The method (Registry).Repository may now return an error. This is too allow
certain implementationt to validate the name or opt to not return a repository
under certain conditions.

In conjunction with this change, error declarations have been moved into a
single file in the distribution package. Several error declarations that had
remained in the storage package have been moved into distribution, as well. The
declarations for Layer and LayerUpload have also been moved into the main
registry file, as a result.

Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-02-13 16:27:33 -08:00
Arnaud Porterie
168b51d402 Basic skeleton for dist binary
Signed-off-by: Arnaud Porterie <arnaud.porterie@docker.com>
2015-02-13 15:25:20 -08:00
Stephen Day
b12d3c3bde Merge pull request #170 from stevvooe/move-layer-interfaces
Move registry interfaces into distribution package
2015-02-12 19:26:00 -08:00
Stephen J Day
d2d46fca41 Move notifications package to distribution
Since the notifications package is now decoupled from storage, we are moving it
to the root package.

Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-02-12 14:40:35 -08:00
Stephen Day
89f73a37e9 Merge pull request #169 from stevvooe/pem-out-gitignore
Add pem and out files to gitignore
2015-02-12 14:27:30 -08:00
Stephen J Day
286a644948 Remove Name from Layer and LayerUpload interface
A Layer or LayerUpload should not be coupled with the containing repository.
Remove the Name method and correctly reference from the repository where
appropriate.

Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-02-12 14:27:05 -08:00
Stephen J Day
27b03f2136 Move layer interface definitions to distribution package
After consideration, it has been decided that the interfaces defined in the
storage package provide a good base for interacting with various registry
instances. Whether interacting with a remote API or a local, on-disk registry,
these types have proved flexible. By moving them here, they can become the
central components of interacting with distribution components.

Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-02-12 14:26:46 -08:00
Stephen J Day
264f2ddbe2 Add pem and out files to gitignore
Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-02-11 15:45:03 -08:00
Stephen Day
c23ad2715f Merge pull request #168 from ahmetalpbalkan/azure-readme
registry/storage/driver/azure: add README
2015-02-11 15:02:15 -08:00
Ahmet Alp Balkan
76f1abfa07 storagedriver/azure: Add README
Signed-off-by: Ahmet Alp Balkan <ahmetalpbalkan@gmail.com>
2015-02-11 14:40:51 -08:00
Olivier Gambier
2000759d51 Merge pull request #167 from stevvooe/registry-handler-package
registry: reorganize package layout
2015-02-11 13:27:39 -08:00
Stephen J Day
f74b9852fe Run goimports/gofmt on previous changes
After all of the perl refactoring, some import orderings were left asunder.
This commit corrects that.

Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-02-11 12:43:04 -08:00
Stephen J Day
65b0d73cb7 Move storagedriver package to registry/storage/driver
This change is slightly more complex than previous package maves in that the
package name changed. To address this, we simply always reference the package
driver as storagedriver to avoid compatbility issues with existing code. While
unfortunate, this can be cleaned up over time.

Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-02-11 12:43:04 -08:00
Stephen J Day
3468fbd4a8 Move storage package under registry package
Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-02-11 12:43:04 -08:00
Stephen J Day
2832ec7f5c Move client package under registry package
Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-02-11 12:42:56 -08:00
Josh Hawn
89a0b6fa8b Merge pull request #110 from jlhawn/token_auth_spec
doc/spec: documentation for token based auth
2015-02-10 18:29:13 -08:00
Josh Hawn
a46af29783 Documentation for Token based Auth
Outlines the format of the tokens and how they are verified.

Outlines how clients should respond to bearer token authorization
challenges.

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)
2015-02-10 18:15:14 -08:00
Stephen Day
fe20d2c38f Merge pull request #166 from BrianBland/config-omitempty
configuration: Adds yaml omitempty tags to config fields
2015-02-10 17:42:24 -08:00
Stephen J Day
0371f648bf Move auth package under registry package
Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-02-10 17:34:04 -08:00
Stephen J Day
e4b811f489 Move registry api definitions under registry package
Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-02-10 17:32:22 -08:00
Stephen J Day
0f08b6961a Move registry package into handler package
The goal is to free up the distribution/registry package to include common
registry types. This moves the webapp definitions out of the way to allow for
this change in the future.

Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-02-10 17:25:40 -08:00
Olivier Gambier
90c2e4b460 Merge pull request #165 from stevvooe/project-management-labels
define meaning of project management labels for issues and PRs
2015-02-10 16:57:15 -08:00
Brian Bland
c69764a745 Adds yaml omitempty tags to config fields 2015-02-10 16:56:19 -08:00
Olivier Gambier
ecef2eb99e Merge pull request #163 from stevvooe/bug-return-non-authorized
Correctly return when repo name is not available
2015-02-10 16:11:17 -08:00
Stephen J Day
12b55bcba0 Define meaning of project management labels for issues and PRs
Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-02-10 15:55:36 -08:00
Stephen J Day
287de9f60a Correctly return when repo name is not available
The branch that executes after a failed request authorization due to a missing
repo name now correctly returns an error. This is somewhat superficial since
the response would have already been executed. Although, unintended repository
operations may have occurred.

Documentations and comments have also been updated to be in line with
surrounding changes.

Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-02-10 15:19:02 -08:00
Stephen Day
34c09cb56c Merge pull request #76 from ahmetalpbalkan/azure-fixes
storagedriver/azure: fix azure storage driver methods, implement Stat
2015-02-10 15:02:48 -08:00
Stephen Day
4be40d16eb Merge pull request #151 from stevvooe/context-aware-logging
context, registry, auth, auth/token, cmd/registry: context aware logging
2015-02-10 15:02:21 -08:00
Ahmet Alp Balkan
d606948fd7 Incorporate storagedriver base in azure, remove path checks
Signed-off-by: Ahmet Alp Balkan <ahmetalpbalkan@gmail.com>
2015-02-10 14:13:02 -08:00
Ahmet Alp Balkan
e7485c831f Support writes to random offsets in Azure storage driver
Signed-off-by: Ahmet Alp Balkan <ahmetalpbalkan@gmail.com>
2015-02-10 14:13:02 -08:00
Ahmet Alp Balkan
bc42f53ec8 Fix azure storagedriver methods, implement Stat, URLFor
Signed-off-by: Ahmet Alp Balkan <ahmetalpbalkan@gmail.com>
2015-02-10 11:17:41 -08:00
Ahmet Alp Balkan
bdc268bca3 Vendor azure-sdk-for-go with godep
Signed-off-by: Ahmet Alp Balkan <ahmetalpbalkan@gmail.com>
2015-02-10 11:17:41 -08:00
Stephen J Day
d9d84ae269 Integrate context with storage package
This changeset integrates context with the storage package. Debug messages have
been added to exported methods. Existing log messages will now include
contextual details through logger fields to aid in debugging. This integration
focuses on logging and may be followed up with a metric-oriented change in the
future.

Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-02-09 14:44:58 -08:00
Stephen Day
d224eda04c Merge pull request #154 from noxiouz/fix_deinitialization_deadlock
[IPC/Client] Get rid of an unnecessary stopChan sending
2015-02-09 14:41:20 -08:00
Olivier Gambier
cc91aeab00 Merge pull request #153 from stevvooe/move-spec-api
doc/spec: move API specification into correct position
2015-02-09 10:45:38 -08:00
Anton Tiurin
66eeadd754 [IPC/Client] There's no need to send struct{}{} to notify a
waiting goroutine with an infinite loop about the stop. It's enough
to close stopChan. Moreover it could lead to a deadlock if
driver.Stop is called before driver.handleSubprocessExit.

Signed-off-by: Anton Tiurin <noxiouz@yandex.ru>
2015-02-09 09:19:14 +03:00
Stephen J Day
b429176dd7 Move API specification into correct position
The goal is to maintain a specification heirarchy under doc/spec. This change
sets the example. The Makefile has also been changed update the AUTHORS file
and can now generate the specification.

Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-02-06 17:49:50 -08:00
Stephen J Day
d2bfb5825c Integrate contextual logging with regsitry app
This changeset integrates contextual logging into the registry web application.
Idiomatic context use is attempted within the current webapp layout. The
functionality is centered around making lifecycle objects (application and
request context) into contexts themselves. Relevant data has been moved into
the context where appropriate.  We still have some work to do to factor out the
registry.Context object and the dispatching functionality to remove some
awkward portions.

The api tests were slightly refactored to use a test environment to eliminate
common code.

Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-02-06 16:51:53 -08:00
Stephen J Day
9e33fb0f95 Update auth/token to use context package utils
Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-02-06 16:20:38 -08:00
Stephen J Day
4b14eef595 Context package to support context-aware logging
The new context package supports context-aware logging, integrating with
logrus. Several utilities are provided to associate http requests with a
context, ensuring that one can trace log messages all the way through a
context-aware call stack.

A full description of this functionality is available in doc.go.

Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-02-06 16:20:38 -08:00
Stephen J Day
13382e45ba Update logrus dependency
This dependency added a method to access the current standard logger. This is
required to properly configure the logger for context awareness. The plan is to
have all loggers descend from the standard logger.

Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-02-06 16:20:38 -08:00
Stephen J Day
29135602ec Update go-uuid dependency
There don't seem to be any major changes but we'll update this while we're at
it. This dependency is pretty important for coming changes.

Signed-off-by: Stephen J Day <stephen.day@docker.com>
2015-02-06 16:20:38 -08:00
Stephen Day
10a194c775 Merge pull request #152 from stevvooe/makefile-improvements
Add common targets to Makefile
2015-02-06 16:15:19 -08:00