Commit Graph

231 Commits

Author SHA1 Message Date
6d44ed4263 Merge pull request #15175 from MHBauer/cliconfig-lint
additional lint fix and enable linter for cliconfig package
Upstream-commit: b48d744b07c5894a7c958f99320ea8a8b608308a
Component: engine
2015-07-30 23:07:19 -04:00
58be23597e lint fix and enable linter for cliconfig package
Signed-off-by: Morgan Bauer <mbauer@us.ibm.com>
Upstream-commit: e809919e2645bc21f7b42fa97134065707f2d15f
Component: engine
2015-07-30 14:37:37 -07:00
c7e78a7a31 Merge pull request #14844 from WeiZhang555/golint-api
fix golint errors/warnings of pkg api/
Upstream-commit: 2f1a7c903f163b3d85c96683971aaad4a24585d7
Component: engine
2015-07-30 16:02:06 -04:00
cebd8dac4d fix golint errors/warnings of pkg api/
Signed-off-by: Zhang Wei <zhangwei555@huawei.com>
Upstream-commit: cfeab585c0e831ef073c689c065a52b84ae08761
Component: engine
2015-07-30 09:46:25 +08:00
639fd1d44b Add back golint for daemon/execdriver/native
It's broken by #15099 Fix it.

Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
Upstream-commit: e34f562a77276516b81756e9ea620a1625c49093
Component: engine
2015-07-30 08:58:54 +08:00
c5fec26f40 Merge pull request #15138 from ewindisch/apparmor-fix-test-plus-unconfined
Fix the proc integration test & include missing AA profile
Upstream-commit: 2ae174e491a366c4663b4f6ecee83cd6f64bcc3f
Component: engine
2015-07-29 15:32:13 -07:00
22c6edd13b Merge pull request #14843 from MHBauer/demonlogger-lint
golint fixes for daemon/logger/*
Upstream-commit: 6a274e48dc645f0ea02ae8bf59ce08ff22cfd663
Component: engine
2015-07-29 18:09:46 -04:00
c5f3d6fd5b Remove container AA profile from packaging
Signed-off-by: Eric Windisch <eric@windisch.us>
Upstream-commit: 0f4e5f71491abc0e7c4f4effe1f3c59aa9bf6a33
Component: engine
2015-07-29 17:47:38 -04:00
e1b2148585 /graph fix lin errors/warnings
Addresses #14756
Signed-off-by: Srini Brahmaroutu <srbrahma@us.ibm.com>
Upstream-commit: 1d6e44311916b26e1cd128e96ea9f0e5ede5f9df
Component: engine
2015-07-29 20:59:36 +00:00
90287c6171 golint fixes for daemon/logger/*
- downcase and privatize exported variables that were unused
 - make accurate an error message
 - added package comments
 - remove unused var ReadLogsNotSupported
 - enable linter
 - some spelling corrections

Signed-off-by: Morgan Bauer <mbauer@us.ibm.com>
Upstream-commit: ccbe539e86dfbb8749c09763ddfd73bf10ac57cc
Component: engine
2015-07-29 13:09:39 -07:00
36ee6380c9 api/client fix golint errors/warnings
Addresses #14756

Signed-off-by: Srini Brahmaroutu <srbrahma@us.ibm.com>
Upstream-commit: 929f2c2f4074e66bb1e942a338e4d2a815096d45
Component: engine
2015-07-29 17:20:54 +00:00
307e5a8a1e Merge pull request #14930 from brahmaroutu/lint_daemon_graphdriver_devmapper
daemon/graphdriver/devmapper/ fix lint errors/warnings
Upstream-commit: dfcdde4d9832adb5bbee146cdf5fac2cc5926b4f
Component: engine
2015-07-29 13:29:57 -04:00
4c4cfdbd2e Merge pull request #14785 from brahmaroutu/lint_api_server
fix golint errors/warnings
Upstream-commit: 2cd058ce4f022f98be22c780a703d93b51722d19
Component: engine
2015-07-29 13:09:31 -04:00
ec5ef287b8 fix linnt
Signed-off-by: Jessica Frazelle <acidburn@docker.com>
Upstream-commit: c2c9e99d845a412717513d91c1886b2da5c4f9a9
Component: engine
2015-07-29 10:05:30 -07:00
581a7026d5 daemon/graphdriver/devmapper/ fix lint errors/warnings
Addresses #14756
Signed-off-by: Srini Brahmaroutu <srbrahma@us.ibm.com>
Upstream-commit: 972a94b449ea6a68f041c47fe7bda35b5ac765a2
Component: engine
2015-07-29 01:43:34 +00:00
7b767eb632 Merge pull request #15063 from jfrazelle/only-write-distributions-file-if-dne
only write distributions file if dne
Upstream-commit: cc6138d94620a89702cfae6cffb1683b1585fa2c
Component: engine
2015-07-28 20:45:04 -04:00
dcda9483a8 api/server fix golint errors/warnings.
Addresses #14756
Signed-off-by: Srini Brahmaroutu <srbrahma@us.ibm.com>
Upstream-commit: 351f6b8ec011983d894951769c2116c9feaf81d2
Component: engine
2015-07-28 22:44:39 +00:00
a011b8f810 Merge pull request #14848 from hqhq/hq_golint_execdriver
Fix golint warnings for daemon/execdriver/*
Upstream-commit: f8090371280a23c430342a43ca99bb777c5f2318
Component: engine
2015-07-28 14:23:22 -07:00
427bfbd915 Merge pull request #14824 from fcantournet/lint_pkg_mflag
Fix golint for pkg/mflag
Upstream-commit: 2c162292b7f6bbbcf392795c8fd1baf302dbc5ab
Component: engine
2015-07-28 13:51:09 -07:00
a9c5ed7c39 Merge pull request #14818 from MHBauer/volume-lint
lint for volume/*
Upstream-commit: 9cfc223cc06142376e6d94e7f0554f539a68ee68
Component: engine
2015-07-28 13:42:18 -07:00
cdd8f67046 lint fixes for volume/*
- comments on exported values
 - constant string replaced by constant reference
 - unexport implementation details of VolumeDriver 'local'
 - add fixed packages to linter list

Signed-off-by: Morgan Bauer <mbauer@us.ibm.com>
Upstream-commit: 9af963aba032d65bb37eafbbe7cafedfc234edf6
Component: engine
2015-07-28 10:40:44 -07:00
3f76e1b38f Fix golint for pkg/mflag
Signed-off-by: Félix Cantournet <felix.cantournet@cloudwatt.com>
Upstream-commit: 8e6ad2171a2fbf51d127326c215608475c031b41
Component: engine
2015-07-28 15:32:42 +02:00
7f7157de05 daemon/graphdriver/aufs fix lint errors/warnings
Addresses #14756
Signed-off-by: Srini Brahmaroutu <srbrahma@us.ibm.com>
Upstream-commit: 55885daa56a0278ed5b412497b3bf99f52d6c52e
Component: engine
2015-07-28 06:17:05 +00:00
1322d4be91 Add daemon/execdriver/* to validate-lint
Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
Upstream-commit: 4862d723a445fd647a7e4a8ac0697043bc23fab4
Component: engine
2015-07-28 08:44:12 +08:00
a6fad1702d only write distributions file if dne
Signed-off-by: Jessica Frazelle <princess@docker.com>
Upstream-commit: 2eee19236650c5146274172e08751cfce52c2fbe
Component: engine
2015-07-27 16:26:35 -07:00
3d5c90498b Merge pull request #14759 from vdemeester/pkg-golint
golint on some pkg/* packages
Upstream-commit: 25c42cc0d0a83325817e5fdb8fa654c9e5ab54d5
Component: engine
2015-07-27 15:19:46 -07:00
2db54e3ac2 Lint on pkg/* packages
- pkg/useragent
- pkg/units
- pkg/ulimit
- pkg/truncindex
- pkg/timeoutconn
- pkg/term
- pkg/tarsum
- pkg/tailfile
- pkg/systemd
- pkg/stringutils
- pkg/stringid
- pkg/streamformatter
- pkg/sockets
- pkg/signal
- pkg/proxy
- pkg/progressreader
- pkg/pools
- pkg/plugins
- pkg/pidfile
- pkg/parsers
- pkg/parsers/filters
- pkg/parsers/kernel
- pkg/parsers/operatingsystem

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: 18c7c67308bd4a24a41028e63c2603bb74eac85e
Component: engine
2015-07-27 21:26:21 +02:00
b61648e148 Lint fixes on runconfig
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: 5170a2c096ff64d4bfbe0fab296ec6777c412bc3
Component: engine
2015-07-27 21:23:15 +02:00
d3974d0227 /image - fix lint errors/warnings
Addresses #14756
Signed-off-by: Srini Brahmaroutu <srbrahma@us.ibm.com>
Upstream-commit: b061572916c5bb959a24f8382b21429c9d81620c
Component: engine
2015-07-27 05:40:57 +00:00
b1920b91e3 fix deb packaging systemd files
Signed-off-by: Jessica Frazelle <princess@docker.com>
Upstream-commit: a2ea8f2ad8b93c53253b9c86537dad95e14bd599
Component: engine
2015-07-25 14:04:39 -07:00
4d9279a3fb Improve documentation and golint compliance of registry package
* Add godoc documentation where it was missing

* Change identifier names that don't match Go style, such as INDEX_NAME

* Rename RegistryInfo to PingResult, which more accurately describes
  what this structure is for. It also has the benefit of making the name
  not stutter if used outside the package.

Updates #14756

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: 4fcb9ac40ce33c4d6e08d5669af6be5e076e2574
Component: engine
2015-07-24 11:55:07 -07:00
c4ddbfd5f9 Merge pull request #14545 from Djelibeybi/oraclelinux6-rpm
Updated docker-engine.spec to build on Oracle Linux 6.
Upstream-commit: c6f4c192fe33bd04fb2b624c115d176f17de7a06
Component: engine
2015-07-23 13:29:48 -07:00
81c6019b8c pass DOCKER_EXPERIMENTAL into build images
Signed-off-by: Jessica Frazelle <princess@docker.com>
Upstream-commit: 76d6751600fe91424171b886fdd87fb3eb3a1380
Component: engine
2015-07-23 09:42:22 -07:00
e804755952 Merge pull request #14862 from vdemeester/validate-lint-all-files
Update validate-lint to lint all go files
Upstream-commit: 3198e76b7758ece76600562d960cb17ad735c7ca
Component: engine
2015-07-22 15:18:02 -07:00
bdf2ee5403 Update validate-lint to lint all go files
By default, using go with package will only validate the go file for the
current platform (or at last misses file_windows.go for example). This
tries to fix that.

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: fa34f07ec04e22b2e0631cc0656ba569b453d21c
Component: engine
2015-07-22 23:21:18 +02:00
76ec388f40 Merge pull request #14864 from ewindisch/apparmor-engine-policy
Add AppArmor policy for the docker binary
Upstream-commit: a7d84503128720612022d46f5c9c04602cb19f05
Component: engine
2015-07-22 13:56:33 -07:00
792828f992 Merge pull request #14628 from estesp/update-docker-py
Update docker-py commit to current master (~1.3.1 release)
Upstream-commit: c328e0c8274ab7b988e8c279f447a1074e3b0631
Component: engine
2015-07-22 12:41:41 -07:00
ae18180fac Add AppArmor policy for the engine
Wraps the engine itself with an AppArmor policy.

This restricts what may be done by applications
we call out to, such as 'xz'.

Significantly, this policy also restricts the policies
to which a container may be spawned into. By default,
users will be able to transition to an unconfined
policy or any policy prefaced with 'docker-'.

Local operators may add new local policies prefaced
with 'docker-' without needing to modify this policy.
Operators choosing to disable privileged containers
will need to modify this policy to remove access
to change_policy to unconfined.

Signed-off-by: Eric Windisch <eric@windisch.us>
Upstream-commit: 39dae54a3f40035b1b7e5ca86c53d05dec832ed2
Component: engine
2015-07-22 14:20:50 -04:00
1ec6bf08bd Update docker-py to current master (~docker-py 1.3.1)
The docker-py commit used in the standard `Dockerfile` is from Feb. 2015
and is out of date with the current API level and has fixes for things
like the new docker cli config location and registry v2 changes/API
responses as well.

Also pass "NOT_ON_HOST=true" to docker-py test suite so that tests
relying on direct HOST interaction (versus running in a container) are
skipped.

Docker-DCO-1.1-Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com> (github: estesp)
Upstream-commit: 65fb04228eba7c6d8640bc8de8800ade05efe2f1
Component: engine
2015-07-22 13:17:59 -04:00
596da1de67 Update linted package list
Signed-off-by: Arnaud Porterie <arnaud.porterie@docker.com>
Upstream-commit: b7184f857489bee6b547eb10a3dfefcd3e420767
Component: engine
2015-07-22 08:46:42 -07:00
50e8a78638 Merge pull request #14851 from bfirsh/golint-integration-cli
Golint integration-cli
Upstream-commit: 875fffdff886205d096ab348d94b5079885f17fb
Component: engine
2015-07-22 11:28:19 -04:00
6aa4de764e Fix golint warnings for integration-cli
Signed-off-by: Ben Firshman <ben@firshman.co.uk>
Upstream-commit: 6b3c928140193f911b73f87bb8b07f54bba5a63a
Component: engine
2015-07-22 14:03:50 +01:00
e1e5cbd789 pkg: mount: golint
Fix the following warnings:

pkg/mount/mountinfo.go:5:6: type name will be used as mount.MountInfo by other packages, and that stutters; consider calling this Info
pkg/mount/mountinfo.go:7:2: struct field Id should be ID

Signed-off-by: Antonio Murdaca <runcom@linux.com>
Upstream-commit: 0f5c9d301b9b1cca66b3ea0f9dec3b5317d3686d
Component: engine
2015-07-22 10:26:10 +02:00
3abbd3cbb1 Update validate-lint script
Add a set of newly linted packages, and fix the script.

Signed-off-by: Arnaud Porterie <arnaud.porterie@docker.com>
Upstream-commit: 7f02cc420ab068f129ec24f3c7514a838bddb1ce
Component: engine
2015-07-21 15:02:46 -07:00
8f6577a7cd Merge pull request #14780 from icecrime/14756_add_golint
Add golint to the development toolbox
Upstream-commit: e4f1cf787c50e0f4e97ea5d0aee5a7b4c5b40ff5
Component: engine
2015-07-21 09:50:58 -07:00
5bcf01ef67 Add golint to the development toolbox
Add golint to the Dockerfile, and a `validate-lint` task to the
Makefile. Currently, the linter will process a harcoded list of packages
that will expand as we fix more warnings. Eventually, the linter should
process all subpackages of the repo (excluding vendored code).

Signed-off-by: Arnaud Porterie <arnaud.porterie@docker.com>
Upstream-commit: 6cce8d18384a5ae1212e7b0f7b7ac9662a89c8c1
Component: engine
2015-07-21 09:00:36 -07:00
74cf202b4f Move AppArmor policy to contrib & deb packaging
The automatic installation of AppArmor policies prevents the
management of custom, site-specific apparmor policies for the
default container profile. Furthermore, this change will allow
a future policy for the engine itself to be written without demanding
the engine be able to arbitrarily create and manage AppArmor policies.

- Add deb package suggests for apparmor.
- Ubuntu postinst use aa-status & fix policy path
- Add the policies to the debian packages.
- Add apparmor tests for writing proc files
Additional restrictions against modifying files in proc
are enforced by AppArmor. Ensure that AppArmor is preventing
access to these files, not simply Docker's configuration of proc.
- Remove /proc/k?mem from AA policy
The path to mem and kmem are in /dev, not /proc
and cannot be restricted successfully through AppArmor.
The device cgroup will need to be sufficient here.
- Load contrib/apparmor during integration tests
Note that this is somewhat dirty because we
cannot restore the host to its original configuration.
However, it should be noted that prior to this patch
series, the Docker daemon itself was loading apparmor
policy from within the tests, so this is no dirtier or
uglier than the status-quo.

Signed-off-by: Eric Windisch <eric@windisch.us>
Upstream-commit: 80d99236c1ef9d389dbaca73c1a949da16b56b42
Component: engine
2015-07-21 11:05:53 -04:00
4ee32ba904 Add release-deb & release-rpm scripts.
These will create the apt & yum repos for the deb/rpms generated by build-deb
and build-rpm.

Adds sign-repo script which signs the repo metadata with a gpg key.

Signed-off-by: Jessica Frazelle <princess@docker.com>
Upstream-commit: c850e97c84abffc71509692ab1accd38408fa51b
Component: engine
2015-07-15 15:54:00 -07:00
13a7ed0799 Updated docker-engine.spec to build on Oracle Linux 6.
Signed-off-by: Avi Miller <avi.miller@oracle.com>
Upstream-commit: 865d3a148875485a3749be83b67ea7449830e6b6
Component: engine
2015-07-11 09:53:00 +10:00
fe10418da9 Remove specific dependencies and let RPM auto-generate the dependencies on libraries during build.
Signed-off-by: Avi Miller <avi.miller@oracle.com>
Upstream-commit: e3b5889783d5e83a9cecc0867e7af73d5fd023f0
Component: engine
2015-07-08 15:30:42 +10:00