docker: upgrade to 26.0.1; import docker-compose from el8 repo
This commit is contained in:
parent
e43b40afc1
commit
c772974094
423
base/docker-compose/docker-compose.spec
Normal file
423
base/docker-compose/docker-compose.spec
Normal file
@ -0,0 +1,423 @@
|
||||
Name: docker-compose
|
||||
Version: 1.29.2
|
||||
Release: 14%{?dist}
|
||||
Summary: Multi-container orchestration for Docker
|
||||
License: ASL 2.0
|
||||
URL: https://github.com/docker/compose
|
||||
Source0: %pypi_source
|
||||
BuildArch: noarch
|
||||
|
||||
Patch0: pytest-7.2-compatibility.patch
|
||||
Patch1: python3.11.patch
|
||||
|
||||
BuildRequires: python%{python3_pkgversion}-devel
|
||||
BuildRequires: python%{python3_pkgversion}-setuptools
|
||||
BuildRequires: python%{python3_pkgversion}-pytest
|
||||
BuildRequires: python%{python3_pkgversion}-distro
|
||||
BuildRequires: python%{python3_pkgversion}-dotenv
|
||||
BuildRequires: python%{python3_pkgversion}-ddt
|
||||
|
||||
BuildRequires: python%{python3_pkgversion}-cached_property >= 1.5.1
|
||||
BuildRequires: python%{python3_pkgversion}-chardet >= 3.0.4
|
||||
BuildRequires: python%{python3_pkgversion}-distro >= 1.5.0
|
||||
BuildRequires: python%{python3_pkgversion}-docker >= 5.0.0
|
||||
BuildRequires: python%{python3_pkgversion}-docker-pycreds >= 0.4.0
|
||||
BuildRequires: python%{python3_pkgversion}-dockerpty >= 0.4.1
|
||||
BuildRequires: python%{python3_pkgversion}-docopt >= 0.6.2
|
||||
BuildRequires: python%{python3_pkgversion}-idna >= 2.10
|
||||
BuildRequires: python%{python3_pkgversion}-jsonschema >= 3.2.0
|
||||
BuildRequires: python%{python3_pkgversion}-pysocks >= 1.7.1
|
||||
BuildRequires: python%{python3_pkgversion}-requests >= 2.24.0
|
||||
BuildRequires: python%{python3_pkgversion}-six >= 1.12.0
|
||||
BuildRequires: python%{python3_pkgversion}-texttable >= 1.6.2
|
||||
BuildRequires: python%{python3_pkgversion}-websocket-client >= 0.57.0
|
||||
BuildRequires: python%{python3_pkgversion}-yaml >= 5.4.1
|
||||
|
||||
Requires: python%{python3_pkgversion}-setuptools
|
||||
|
||||
Requires: python%{python3_pkgversion}-cached_property >= 1.5.1
|
||||
Requires: python%{python3_pkgversion}-chardet >= 3.0.4
|
||||
Requires: python%{python3_pkgversion}-distro >= 1.5.0
|
||||
Requires: python%{python3_pkgversion}-docker >= 5.0.0
|
||||
Requires: python%{python3_pkgversion}-docker-pycreds >= 0.4.0
|
||||
Requires: python%{python3_pkgversion}-dockerpty >= 0.4.1
|
||||
Requires: python%{python3_pkgversion}-docopt >= 0.6.2
|
||||
Requires: python%{python3_pkgversion}-idna >= 2.10
|
||||
Requires: python%{python3_pkgversion}-jsonschema >= 3.2.0
|
||||
Requires: python%{python3_pkgversion}-pysocks >= 1.7.1
|
||||
Requires: python%{python3_pkgversion}-requests >= 2.24.0
|
||||
Requires: python%{python3_pkgversion}-six >= 1.12.0
|
||||
Requires: python%{python3_pkgversion}-texttable >= 1.6.2
|
||||
Requires: python%{python3_pkgversion}-websocket-client >= 0.57.0
|
||||
Requires: python%{python3_pkgversion}-yaml >= 5.4.1
|
||||
|
||||
Requires: python%{python3_pkgversion}-attrs >= 20.3.0
|
||||
Requires: python%{python3_pkgversion}-certifi >= 2020.6.20
|
||||
|
||||
|
||||
%description
|
||||
Compose is a tool for defining and running multi-container Docker
|
||||
applications. With Compose, you use a Compose file to configure your
|
||||
application's services. Then, using a single command, you create and
|
||||
start all the services from your configuration.
|
||||
|
||||
Compose is great for development, testing, and staging environments,
|
||||
as well as CI workflows.
|
||||
|
||||
Using Compose is basically a three-step process.
|
||||
|
||||
1. Define your app's environment with a Dockerfile so it can be
|
||||
reproduced anywhere.
|
||||
2. Define the services that make up your app in docker-compose.yml so
|
||||
they can be run together in an isolated environment:
|
||||
3. Lastly, run docker-compose up and Compose will start and run your
|
||||
entire app.
|
||||
|
||||
|
||||
%prep
|
||||
%autosetup -p 1
|
||||
rm -rf docker_compose.egg-info
|
||||
|
||||
# Remove dependency version constraints not relevant in Fedora/EPEL
|
||||
sed -e 's/, < [0-9.]\+//' -i setup.py
|
||||
|
||||
|
||||
%build
|
||||
%py3_build
|
||||
|
||||
|
||||
%install
|
||||
%py3_install
|
||||
install -D -p -m 644 contrib/completion/bash/docker-compose %{buildroot}%{_datadir}/bash-completion/completions/docker-compose
|
||||
install -D -p -m 644 contrib/completion/zsh/_docker-compose %{buildroot}%{_datadir}/zsh/site-functions/_docker-compose
|
||||
install -D -p -m 644 contrib/completion/fish/docker-compose.fish %{buildroot}%{_datadir}/fish/vendor_completions.d/docker-compose.fish
|
||||
mv %{buildroot}%{_bindir}/%{name} %{buildroot}%{_bindir}/%{name}-%{python3_pkgversion}
|
||||
touch %{buildroot}%{_bindir}/%{name}
|
||||
|
||||
|
||||
%check
|
||||
PYTHONPATH=%{buildroot}%{python3_sitelib} pytest-%{python3_version} --verbose tests/unit
|
||||
|
||||
%post
|
||||
%{_sbindir}/update-alternatives --install %{_bindir}/docker-compose docker-compose %{_bindir}/docker-compose-%{python3_pkgversion} 1
|
||||
|
||||
%postun
|
||||
if [ $1 -eq 0 ] ; then
|
||||
%{_sbindir}/update-alternatives --remove docker-compose %{_bindir}/docker-compose-%{python3_pkgversion}
|
||||
fi
|
||||
|
||||
|
||||
|
||||
%files
|
||||
%license LICENSE
|
||||
%doc CHANGELOG.md README.md
|
||||
%ghost %{_bindir}/%{name}
|
||||
%{_bindir}/%{name}-%{python3_pkgversion}
|
||||
%{python3_sitelib}/compose
|
||||
%{python3_sitelib}/docker_compose-%{version}-py%{python3_version}.egg-info
|
||||
%{_datadir}/bash-completion
|
||||
%{_datadir}/zsh
|
||||
%{_datadir}/fish
|
||||
|
||||
|
||||
%changelog
|
||||
* Tue Apr 16 2024 Raven <raven@sysadmins.ws> - 1.29.2-14
|
||||
- rename binary to avoid conflicts with docker-compose2
|
||||
|
||||
* Wed Jan 24 2024 Fedora Release Engineering <releng@fedoraproject.org> - 1.29.2-12
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
|
||||
|
||||
* Fri Jan 19 2024 Fedora Release Engineering <releng@fedoraproject.org> - 1.29.2-11
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
|
||||
|
||||
* Wed Jul 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 1.29.2-10
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
|
||||
|
||||
* Fri Jun 30 2023 Python Maint <python-maint@redhat.com> - 1.29.2-9
|
||||
- Rebuilt for Python 3.12
|
||||
|
||||
* Thu Jan 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 1.29.2-8
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
|
||||
|
||||
* Wed Nov 16 2022 Lumír Balhar <lbalhar@redhat.com> - 1.29.2-7
|
||||
- Fix compatibility with pytest 7.2
|
||||
|
||||
* Thu Jul 21 2022 Fedora Release Engineering <releng@fedoraproject.org> - 1.29.2-6
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
|
||||
|
||||
* Thu Jun 16 2022 Python Maint <python-maint@redhat.com> - 1.29.2-5
|
||||
- Rebuilt for Python 3.11
|
||||
|
||||
* Thu Jan 20 2022 Fedora Release Engineering <releng@fedoraproject.org> - 1.29.2-4
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
|
||||
|
||||
* Wed Jul 21 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.29.2-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
|
||||
|
||||
* Fri Jun 04 2021 Python Maint <python-maint@redhat.com> - 1.29.2-2
|
||||
- Rebuilt for Python 3.10
|
||||
|
||||
* Mon May 10 2021 Michael Hampton <error@ioerror.us> - 1.29.2-1
|
||||
- Update to 1.29.2
|
||||
|
||||
* Wed Apr 21 2021 Michael Hampton <error@ioerror.us> - 1.29.1-1
|
||||
- Rebase to 1.29.1
|
||||
|
||||
* Mon Mar 29 2021 Michael Hampton <error@ioerror.us> - 1.28.6-1
|
||||
- Rebase to 1.28.6
|
||||
|
||||
* Fri Feb 26 2021 Michael Hampton <error@ioerror.us> - 1.28.5-1
|
||||
- Rebase to 1.28.5
|
||||
|
||||
* Fri Feb 19 2021 Michael Hampton <error@ioerror.us> - 1.28.4-1
|
||||
- Rebase to 1.28.4
|
||||
|
||||
* Wed Jan 27 2021 Michael Hampton <error@ioerror.us> - 1.28.2-1
|
||||
- Rebase to 1.28.2
|
||||
|
||||
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.28.0-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
|
||||
|
||||
* Wed Jan 20 2021 Michael Hampton <error@ioerror.us> - 1.28.0-1
|
||||
- Rebase to 1.28.0
|
||||
|
||||
* Thu Sep 24 2020 Michael Hampton <error@ioerror.us> - 1.27.4-1
|
||||
- Rebase to 1.27.4
|
||||
|
||||
* Wed Sep 16 2020 Michael Hampton <error@ioerror.us> - 1.27.3-2
|
||||
- Requires python-docker 4.3.1
|
||||
|
||||
* Wed Sep 16 2020 Michael Hampton <error@ioerror.us> - 1.27.3-1
|
||||
- Rebase to 1.27.3
|
||||
|
||||
* Mon Jul 27 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.25.4-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
|
||||
|
||||
* Tue Jul 14 2020 Michael Hampton <error@ioerror.us> - 1.26.2-1
|
||||
- Rebase to 1.26.2
|
||||
- Add python-distro build dependency
|
||||
- Add python-dotenv build dependency
|
||||
|
||||
* Tue May 26 2020 Miro Hrončok <mhroncok@redhat.com> - 1.25.4-2
|
||||
- Rebuilt for Python 3.9
|
||||
|
||||
* Mon Mar 23 2020 Michael Hampton <error@ioerror.us> - 1.25.4-2
|
||||
- Remove patch for BZ#1705955 it is now in upstream source
|
||||
- Add python-ddt build dependency
|
||||
|
||||
* Sat Feb 29 2020 Michael Hampton <error@ioerror.us> - 1.25.4-1
|
||||
- Rebase to 1.25.4
|
||||
|
||||
* Tue Jan 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.24.1-4
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
|
||||
|
||||
* Mon Oct 7 2019 Michael Hampton <error@ioerror.us> - 1.24.1-3
|
||||
- Require python-docker 4.0.2-2 for ssh feature
|
||||
|
||||
* Thu Oct 03 2019 Miro Hrončok <mhroncok@redhat.com> - 1.24.1-2
|
||||
- Rebuilt for Python 3.8.0rc1 (#1748018)
|
||||
|
||||
* Tue Sep 17 2019 Michael Hampton <error@ioerror.us> - 1.24.1-2
|
||||
- Require python-docker 4.0.2 for ssh feature
|
||||
|
||||
* Wed Aug 28 2019 Michael Hampton <error@ioerror.us> - 1.24.1-1
|
||||
- Rebase to 1.24.1 (BZ#1691898)
|
||||
- Patch tests for pytest 5 compatibility (BZ#1705955)
|
||||
|
||||
* Mon Aug 19 2019 Miro Hrončok <mhroncok@redhat.com> - 1.22.0-6
|
||||
- Rebuilt for Python 3.8
|
||||
|
||||
* Wed Jul 24 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.22.0-5
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
|
||||
|
||||
* Wed Jul 10 2019 Michael Hampton <error@ioerror.us> - 1.22.0-4
|
||||
|
||||
* Thu Jan 31 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.22.0-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
|
||||
|
||||
* Mon Oct 08 2018 Carl George <carl@george.computer> - 1.22.0-2
|
||||
- Run upstream unit tests
|
||||
|
||||
* Wed Jul 18 2018 Michael Hampton <error@ioerror.us> - 1.22.0-1
|
||||
- Update to 1.22.0
|
||||
|
||||
* Thu Jul 12 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.20.1-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
|
||||
|
||||
* Tue Jun 19 2018 Miro Hrončok <mhroncok@redhat.com> - 1.20.1-2
|
||||
- Rebuilt for Python 3.7
|
||||
|
||||
* Tue Mar 27 2018 Michael Hampton <error@ioerror.us> - 1.20.1-1
|
||||
- Update to 1.20.1
|
||||
|
||||
* Wed Mar 21 2018 Michael Hampton <error@ioerror.us> - 1.20.0-1
|
||||
- Update to 1.20.0
|
||||
|
||||
* Fri Mar 02 2018 Adam Williamson <awilliam@redhat.com> - 1.19.0-2
|
||||
- Backport upstream patch for compatibility with python-docker 3.0.0
|
||||
|
||||
* Mon Feb 19 2018 Michael Hampton <error@ioerror.us> - 1.19.0-1
|
||||
- Update to 1.19.0
|
||||
|
||||
* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.18.0-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
|
||||
|
||||
* Tue Dec 26 2017 Carl George <carl@george.computer> - 1.18.0-1
|
||||
- Latest upstream
|
||||
- Drop patch0 and patch1, use sed on setup.py instead
|
||||
- Rebase patch2
|
||||
|
||||
* Thu Nov 9 2017 Michael Hampton <error@ioerror.us> - 1.17.1-1
|
||||
- Update to 1.17.1 (#1511455)
|
||||
|
||||
* Thu Nov 2 2017 Michael Hampton <error@ioerror.us> - 1.17.0-1
|
||||
- Update to 1.17.0 (#1504337)
|
||||
|
||||
* Sun Sep 10 2017 Carl George <carl@george.computer> - 1.16.1-2
|
||||
- Align dependencies with upstream
|
||||
- RHEL compatibility
|
||||
- Add bash, zsh, and fish completions
|
||||
|
||||
* Sat Sep 2 2017 Michael Hampton <error@ioerror.us> - 1.16.1-1
|
||||
- Update to 1.16.1 (#1483776)
|
||||
|
||||
* Fri Jul 28 2017 Michael Hampton <error@ioerror.us> - 1.15.0-1
|
||||
- Update to 1.15.0 (#1471093)
|
||||
- Explicit python3-docker requirement
|
||||
- New upstream requirements python3-pysocks, python3-certifi, python3-idna
|
||||
|
||||
* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.14.0-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
|
||||
|
||||
* Tue Jun 20 2017 Michael Hampton <error@ioerror.us> - 1.14.0-1
|
||||
- Update to upstream 1.14.0
|
||||
|
||||
* Mon May 8 2017 Michael Hampton <error@ioerror.us> - 1.13.0-1
|
||||
- Update to upstream 1.13.0
|
||||
|
||||
* Fri Apr 7 2017 Michael Hampton <error@ioerror.us> - 1.12.0-1
|
||||
- Update to upstream 1.12.0
|
||||
|
||||
* Thu Mar 2 2017 Michael Hampton <error@ioerror.us> - 1.11.2-1
|
||||
- Update to upstream 1.11.2
|
||||
|
||||
* Tue Feb 28 2017 Michael Hampton <error@ioerror.us> - 1.11.1-3
|
||||
- Remove requirements upper bound from setup.py; BZ#1426145
|
||||
- Added new dependency python3-colorama
|
||||
|
||||
* Fri Feb 17 2017 Michael Hampton <error@ioerror.us> - 1.11.1-2
|
||||
- python-docker-py package name changed to python-docker; BZ#1422198
|
||||
|
||||
* Fri Feb 10 2017 Michael Hampton <error@ioerror.us> - 1.11.1-1
|
||||
- Update to upstream 1.11.1
|
||||
|
||||
* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.10.1-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
|
||||
|
||||
* Fri Feb 3 2017 Michael Hampton <error@ioerror.us> - 1.10.1-1
|
||||
- Update to upstream 1.10.1
|
||||
|
||||
* Mon Dec 19 2016 Miro Hrončok <mhroncok@redhat.com> - 1.9.0-3
|
||||
- Rebuild for Python 3.6
|
||||
|
||||
* Mon Nov 21 2016 Michael Hampton <error@ioerror.us> - 1.9.0-2
|
||||
- BZ#1396852
|
||||
|
||||
* Sat Nov 19 2016 Michael Hampton <error@ioerror.us> - 1.9.0-1
|
||||
- Update to upstream 1.9.0
|
||||
|
||||
* Fri Sep 23 2016 Michael Hampton <error@ioerror.us> - 1.8.1-1
|
||||
- Update to upstream 1.8.1
|
||||
|
||||
* Sat Sep 10 2016 Michael Hampton <error@ioerror.us> - 1.8.0-2
|
||||
- Port to Python 3, BZ#1374656
|
||||
|
||||
* Thu Jul 28 2016 Michael Hampton <error@ioerror.us> - 1.8.0-1
|
||||
- Update to upstream 1.8.0
|
||||
|
||||
* Tue Jul 19 2016 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.7.1-2
|
||||
- https://fedoraproject.org/wiki/Changes/Automatic_Provides_for_Python_RPM_Packages
|
||||
|
||||
* Thu May 05 2016 Michael Hampton <error@ioerror.us> - 1.7.1-1
|
||||
- Update to upstream 1.7.1
|
||||
- Updated package description from upstream
|
||||
|
||||
* Thu Apr 14 2016 Michael Hampton <error@ioerror.us> - 1.7.0-1
|
||||
- Update to upstream 1.7.0
|
||||
|
||||
* Fri Feb 05 2016 Michael Hampton <error@ioerror.us> - 1.6.0-1
|
||||
- Update to upstream 1.6.0
|
||||
|
||||
* Wed Feb 03 2016 Fedora Release Engineering <releng@fedoraproject.org> - 1.5.2-5
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
|
||||
|
||||
* Tue Jan 12 2016 Michael Hampton <error@ioerror.us> - 1.5.2-4
|
||||
- Added missing dependency python-enum34
|
||||
|
||||
* Mon Jan 11 2016 Michael Hampton <error@ioerror.us> - 1.5.2-3
|
||||
- Added missing dependency python-jsonschema
|
||||
|
||||
* Wed Dec 30 2015 Michael Hampton <error@ioerror.us> - 1.5.2-2
|
||||
- Updated locations of docs
|
||||
|
||||
* Wed Dec 30 2015 Michael Hampton <error@ioerror.us> - 1.5.2-1
|
||||
- Update to upstream 1.5.2
|
||||
|
||||
* Wed Sep 23 2015 Michael Hampton <error@ioerror.us> - 1.4.2-1
|
||||
- Fixes a regression in the 1.4.1 release that would cause
|
||||
docker-compose up without the -d option to exit immediately.
|
||||
|
||||
* Wed Sep 16 2015 Michael Hampton <error@ioerror.us> - 1.4.1-1
|
||||
- Update to upstream 1.4.1
|
||||
|
||||
* Wed Aug 12 2015 Michael Hampton <error@ioerror.us> - 1.4.0-1
|
||||
- Update to upstream 1.4.0
|
||||
- Update Summary to match upstream summary
|
||||
|
||||
* Sat May 16 2015 Michael Hampton <error@ioerror.us> - 1.2.0-3
|
||||
- Update Obsoletes EVR per packaging guidelines BZ#1213111
|
||||
|
||||
* Sun Apr 19 2015 Michael Hampton <error@ioerror.us> - 1.2.0-2
|
||||
- Update location of LICENSE file
|
||||
|
||||
* Sat Apr 18 2015 Michael Hampton <error@ioerror.us> - 1.2.0-1
|
||||
- Update to 1.2.0
|
||||
- Added new doc SWARM.md
|
||||
- Removed docker package requires as it is not required to build or run the
|
||||
package, only to run tests, which we can't do anyway
|
||||
- Removed commented code relating to running tests, which we can't do anyway
|
||||
- Made package noarch as docker-io is no longer required
|
||||
|
||||
* Mon Mar 23 2015 Michael Hampton <error@ioerror.us> - 1.1.0-1
|
||||
- Update to 1.1.0 including upstream name change
|
||||
- Requires python-dockerpty
|
||||
- Requires python-docker-py >= 0.7.1-3 BZ#1197300
|
||||
|
||||
* Tue Mar 17 2015 Matej Stuchlik <mstuchli@redhat.com> - 1.0.1-2
|
||||
- Completely remove version specs from setup.py
|
||||
|
||||
* Tue Mar 17 2015 Matej Stuchlik <mstuchli@redhat.com> - 1.0.1-1
|
||||
- Update to 1.0.1
|
||||
|
||||
* Wed Dec 03 2014 Matej Stuchlik <mstuchli@redhat.com> - 1.0.0-5
|
||||
- Remove upper bound from setup.py requires
|
||||
|
||||
* Wed Nov 12 2014 Matej Stuchlik <mstuchli@redhat.com> - 1.0.0-4
|
||||
- Add python-setuptools to requires
|
||||
|
||||
* Thu Oct 23 2014 Matej Stuchlik <mstuchli@redhat.com> - 1.0.0-3
|
||||
- Relax strict version requirements on websocket-client (#1155510)
|
||||
|
||||
* Tue Oct 21 2014 Matej Stuchlik <mstuchli@redhat.com> - 1.0.0-2
|
||||
- Update Requires
|
||||
|
||||
* Tue Oct 21 2014 Matej Stuchlik <mstuchli@redhat.com> - 1.0.0-1
|
||||
- Update to 1.0.0
|
||||
- Droped the two patches
|
||||
|
||||
* Tue Oct 21 2014 Matej Stuchlik <mstuchli@redhat.com> - 0.5.2-2
|
||||
- Explicitly disable debuginfo subpackage (#1154780)
|
||||
- Add python-docker-py to Requires (#1154874)
|
||||
|
||||
* Thu Oct 09 2014 Matej Stuchlik <mstuchli@redhat.com> - 0.5.2-1
|
||||
- Initial spec based on rhbz#1129889
|
53
base/docker-compose/pytest-7.2-compatibility.patch
Normal file
53
base/docker-compose/pytest-7.2-compatibility.patch
Normal file
@ -0,0 +1,53 @@
|
||||
From a277e6101828afa58b4b602c4e402259889de81b Mon Sep 17 00:00:00 2001
|
||||
From: Lumir Balhar <lbalhar@redhat.com>
|
||||
Date: Wed, 16 Nov 2022 07:45:03 +0100
|
||||
Subject: [PATCH] pytest 7.2 compatibility
|
||||
|
||||
---
|
||||
tests/unit/cli_test.py | 17 ++++++++++++++---
|
||||
1 file changed, 14 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/tests/unit/cli_test.py b/tests/unit/cli_test.py
|
||||
index fa6e767..3d766e8 100644
|
||||
--- a/tests/unit/cli_test.py
|
||||
+++ b/tests/unit/cli_test.py
|
||||
@@ -1,10 +1,11 @@
|
||||
+import contextlib
|
||||
import os
|
||||
import shutil
|
||||
import tempfile
|
||||
from io import StringIO
|
||||
+from pathlib import Path
|
||||
|
||||
import docker
|
||||
-import py
|
||||
import pytest
|
||||
from docker.constants import DEFAULT_DOCKER_API_VERSION
|
||||
|
||||
@@ -23,11 +24,21 @@ from compose.container import Container
|
||||
from compose.project import Project
|
||||
|
||||
|
||||
+@contextlib.contextmanager
|
||||
+def working_directory(path):
|
||||
+ cwd = Path.cwd()
|
||||
+ os.chdir(path)
|
||||
+ try:
|
||||
+ yield
|
||||
+ finally:
|
||||
+ os.chdir(cwd)
|
||||
+
|
||||
+
|
||||
class CLITestCase(unittest.TestCase):
|
||||
|
||||
def test_default_project_name(self):
|
||||
- test_dir = py._path.local.LocalPath('tests/fixtures/simple-composefile')
|
||||
- with test_dir.as_cwd():
|
||||
+ test_dir = Path('tests/fixtures/simple-composefile')
|
||||
+ with working_directory(test_dir):
|
||||
project_name = get_project_name('.')
|
||||
assert 'simple-composefile' == project_name
|
||||
|
||||
--
|
||||
2.38.1
|
||||
|
11
base/docker-compose/python3.11.patch
Normal file
11
base/docker-compose/python3.11.patch
Normal file
@ -0,0 +1,11 @@
|
||||
--- a/setup.py 2021-05-10 17:21:57.000000000 +0600
|
||||
+++ b/setup.py 2024-02-07 14:16:55.319613995 +0600
|
||||
@@ -48,8 +48,6 @@
|
||||
tests_require.append('mock >= 1.0.1, < 4')
|
||||
|
||||
extras_require = {
|
||||
- ':python_version < "3.5"': ['backports.ssl_match_hostname >= 3.5, < 4'],
|
||||
- ':python_version < "3.8"': ['cached-property >= 1.2.0, < 2'],
|
||||
':sys_platform == "win32"': ['colorama >= 0.4, < 1'],
|
||||
'socks': ['PySocks >= 1.5.6, != 1.5.7, < 2'],
|
||||
'tests': tests_require,
|
106
base/docker-compose/setup.py
Normal file
106
base/docker-compose/setup.py
Normal file
@ -0,0 +1,106 @@
|
||||
#!/usr/bin/env python
|
||||
import codecs
|
||||
import os
|
||||
import re
|
||||
import sys
|
||||
|
||||
import pkg_resources
|
||||
from setuptools import find_packages
|
||||
from setuptools import setup
|
||||
|
||||
|
||||
def read(*parts):
|
||||
path = os.path.join(os.path.dirname(__file__), *parts)
|
||||
with codecs.open(path, encoding='utf-8') as fobj:
|
||||
return fobj.read()
|
||||
|
||||
|
||||
def find_version(*file_paths):
|
||||
version_file = read(*file_paths)
|
||||
version_match = re.search(r"^__version__ = ['\"]([^'\"]*)['\"]",
|
||||
version_file, re.M)
|
||||
if version_match:
|
||||
return version_match.group(1)
|
||||
raise RuntimeError("Unable to find version string.")
|
||||
|
||||
|
||||
install_requires = [
|
||||
'docopt >= 0.6.1, < 1',
|
||||
'PyYAML >= 3.10, < 6',
|
||||
'requests >= 2.20.0, < 3',
|
||||
'texttable >= 0.9.0, < 2',
|
||||
'websocket-client >= 0.32.0, < 1',
|
||||
'distro >= 1.5.0, < 2',
|
||||
'docker[ssh] >= 5',
|
||||
'dockerpty >= 0.4.1, < 1',
|
||||
'jsonschema >= 2.5.1, < 4',
|
||||
'python-dotenv >= 0.13.0, < 1',
|
||||
]
|
||||
|
||||
|
||||
tests_require = [
|
||||
'ddt >= 1.2.2, < 2',
|
||||
'pytest < 6',
|
||||
]
|
||||
|
||||
|
||||
if sys.version_info[:2] < (3, 4):
|
||||
tests_require.append('mock >= 1.0.1, < 4')
|
||||
|
||||
extras_require = {
|
||||
':sys_platform == "win32"': ['colorama >= 0.4, < 1'],
|
||||
'socks': ['PySocks >= 1.5.6, != 1.5.7, < 2'],
|
||||
'tests': tests_require,
|
||||
}
|
||||
|
||||
|
||||
try:
|
||||
if 'bdist_wheel' not in sys.argv:
|
||||
for key, value in extras_require.items():
|
||||
if key.startswith(':') and pkg_resources.evaluate_marker(key[1:]):
|
||||
install_requires.extend(value)
|
||||
except Exception as e:
|
||||
print("Failed to compute platform dependencies: {}. ".format(e) +
|
||||
"All dependencies will be installed as a result.", file=sys.stderr)
|
||||
for key, value in extras_require.items():
|
||||
if key.startswith(':'):
|
||||
install_requires.extend(value)
|
||||
|
||||
|
||||
setup(
|
||||
name='docker-compose',
|
||||
version=find_version("compose", "__init__.py"),
|
||||
description='Multi-container orchestration for Docker',
|
||||
long_description=read('README.md'),
|
||||
long_description_content_type='text/markdown',
|
||||
url='https://www.docker.com/',
|
||||
project_urls={
|
||||
'Documentation': 'https://docs.docker.com/compose/overview',
|
||||
'Changelog': 'https://github.com/docker/compose/blob/release/CHANGELOG.md',
|
||||
'Source': 'https://github.com/docker/compose',
|
||||
'Tracker': 'https://github.com/docker/compose/issues',
|
||||
},
|
||||
author='Docker, Inc.',
|
||||
license='Apache License 2.0',
|
||||
packages=find_packages(exclude=['tests.*', 'tests']),
|
||||
include_package_data=True,
|
||||
install_requires=install_requires,
|
||||
extras_require=extras_require,
|
||||
tests_require=tests_require,
|
||||
python_requires='>=3.4',
|
||||
entry_points={
|
||||
'console_scripts': ['docker-compose=compose.cli.main:main'],
|
||||
},
|
||||
classifiers=[
|
||||
'Development Status :: 5 - Production/Stable',
|
||||
'Environment :: Console',
|
||||
'Intended Audience :: Developers',
|
||||
'License :: OSI Approved :: Apache Software License',
|
||||
'Programming Language :: Python :: 3',
|
||||
'Programming Language :: Python :: 3.4',
|
||||
'Programming Language :: Python :: 3.6',
|
||||
'Programming Language :: Python :: 3.7',
|
||||
'Programming Language :: Python :: 3.8',
|
||||
'Programming Language :: Python :: 3.9',
|
||||
],
|
||||
)
|
57
base/docker-compose2/docker-compose.spec
Normal file
57
base/docker-compose2/docker-compose.spec
Normal file
@ -0,0 +1,57 @@
|
||||
Name: docker-compose2
|
||||
Version: 2.26.1
|
||||
Release: 1%{dist}
|
||||
Summary: Define and run multi-container applications with Docker
|
||||
License: Apache-2.0
|
||||
URL: https://github.com/docker/compose
|
||||
Source: compose-%{version}.tar.gz
|
||||
Source1: vendor.tar.gz
|
||||
BuildRequires: golang%{?_isa} >= 1.21
|
||||
Requires: docker
|
||||
|
||||
|
||||
%description
|
||||
Docker Compose is a tool for running multi-container applications on Docker defined using the Compose file format. A Compose file is used to define how the one or more containers that make up your application are configured. Once you have a Compose file, you can create and start your application with a single command: docker compose up.
|
||||
About update and backward compatibility
|
||||
|
||||
Docker Compose V2 is a major version bump release of Docker Compose. It has been completely rewritten from scratch in Golang (V1 was in Python). The installation instructions for Compose V2 differ from V1. V2 is not a standalone binary anymore, and installation scripts will have to be adjusted. Some commands are different.
|
||||
|
||||
For a smooth transition from legacy docker-compose 1.xx, please consider installing compose-switch to translate docker-compose ... commands into Compose V2's docker compose .... . Also check V2's --compatibility flag.
|
||||
|
||||
%prep
|
||||
%setup -q -a 1 -n compose-%{version}
|
||||
|
||||
%build
|
||||
export CGO_CFLAGS="-I%{_includedir}/openssl3 ${CFLAGS}"
|
||||
export CGO_CXXFLAGS="-I%{_includedir}/openssl3 ${CXXFLAGS}"
|
||||
|
||||
go build \
|
||||
-mod=vendor \
|
||||
-buildmode=pie \
|
||||
-trimpath \
|
||||
-ldflags="-s -w -X github.com/docker/compose/v2/internal.Version=%{version}" \
|
||||
-o bin/docker-compose ./cmd/
|
||||
|
||||
%install
|
||||
install -d -m 0755 "%{buildroot}/usr/lib/docker/cli-plugins/"
|
||||
install -D -m 0755 bin/docker-compose "%{buildroot}/usr/lib/docker/cli-plugins/docker-compose"
|
||||
install -d -m 0755 %{buildroot}%{_bindir}
|
||||
touch %{buildroot}%{_bindir}/docker-compose
|
||||
|
||||
%post
|
||||
%{_sbindir}/update-alternatives --install %{_bindir}/docker-compose docker-compose /usr/lib/docker/cli-plugins/docker-compose 2
|
||||
|
||||
%postun
|
||||
if [ $1 -eq 0 ] ; then
|
||||
%{_sbindir}/update-alternatives --remove docker-compose /usr/lib/docker/cli-plugins/docker-compose
|
||||
fi
|
||||
|
||||
|
||||
|
||||
%files
|
||||
%doc README.md
|
||||
%license LICENSE
|
||||
%dir /usr/lib/docker/
|
||||
%dir /usr/lib/docker/cli-plugins/
|
||||
/usr/lib/docker/cli-plugins/docker-compose
|
||||
%ghost %{_bindir}/docker-compose
|
@ -1,7 +0,0 @@
|
||||
Users can add runtimes (in addition to runc) to Docker by adding executable
|
||||
files in /etc/docker-runtimes.d.
|
||||
|
||||
The name of the file becomes the name of the runtime.
|
||||
|
||||
To disable an installed runtime file without RPM clobbering it and re-enabling
|
||||
it on an update, remove the executable bits (chmod a-x).
|
@ -1,54 +0,0 @@
|
||||
From 4c4d58519541008ef8982e1fcffe76c60e1389f5 Mon Sep 17 00:00:00 2001
|
||||
From: Sai Harsha <ssuryad@amazon.com>
|
||||
Date: Tue, 14 Jun 2022 06:39:31 +0000
|
||||
Subject: [PATCH 1/1] Skip TestSaveLoadContexts and TestExportKubeconfig
|
||||
|
||||
Skipping TestExportKubeconfig and TestSaveLoadContexts tests which require root access
|
||||
|
||||
---
|
||||
cli/command/context/export-import_test.go | 2 ++
|
||||
cli/context/kubernetes/endpoint_test.go | 2 ++
|
||||
2 files changed, 4 insertions(+)
|
||||
|
||||
diff --git a/cli/command/context/export-import_test.go b/cli/command/context/export-import_test.go
|
||||
index bf0cd88..6be9384 100644
|
||||
--- a/cli/command/context/export-import_test.go
|
||||
+++ b/cli/command/context/export-import_test.go
|
||||
@@ -8,6 +8,7 @@ import (
|
||||
"path/filepath"
|
||||
"testing"
|
||||
|
||||
+ "github.com/docker/docker/testutil"
|
||||
"github.com/docker/cli/cli/streams"
|
||||
"gotest.tools/v3/assert"
|
||||
)
|
||||
@@ -71,6 +72,7 @@ func TestExportImportPipe(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestExportKubeconfig(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
contextFile := filepath.Join(t.TempDir(), "exported")
|
||||
cli := makeFakeCli(t)
|
||||
createTestContextWithKube(t, cli)
|
||||
diff --git a/cli/context/kubernetes/endpoint_test.go b/cli/context/kubernetes/endpoint_test.go
|
||||
index 89eeb9d..700e21e 100644
|
||||
--- a/cli/context/kubernetes/endpoint_test.go
|
||||
+++ b/cli/context/kubernetes/endpoint_test.go
|
||||
@@ -5,6 +5,7 @@ import (
|
||||
"os"
|
||||
"testing"
|
||||
|
||||
+ "github.com/docker/docker/testutil"
|
||||
"github.com/docker/cli/cli/context"
|
||||
"github.com/docker/cli/cli/context/store"
|
||||
"gotest.tools/v3/assert"
|
||||
@@ -41,6 +42,7 @@ var testStoreCfg = store.NewConfig(
|
||||
)
|
||||
|
||||
func TestSaveLoadContexts(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
store := store.New(t.TempDir(), testStoreCfg)
|
||||
assert.NilError(t, save(store, testEndpoint("https://test", "test", nil, nil, nil, false), "raw-notls"))
|
||||
assert.NilError(t, save(store, testEndpoint("https://test", "test", nil, nil, nil, true), "raw-notls-skip"))
|
||||
--
|
||||
2.32.0
|
@ -1,112 +0,0 @@
|
||||
From fb5a9ec741c4a2246624b694d88db2e5fabc9118 Mon Sep 17 00:00:00 2001
|
||||
From: Angel Velazquez <angelcar@amazon.com>
|
||||
Date: Thu, 20 May 2021 16:59:30 -0700
|
||||
Subject: [PATCH] Limit the rate at which logger errors are logged into daemon
|
||||
logs
|
||||
|
||||
Logging to daemon logs every time there's an error with a log driver can be
|
||||
problematic since daemon logs can grow rapidly, potentially exhausting disk
|
||||
space.
|
||||
|
||||
Instead, it's preferable to limit the rate at which log driver errors are allowed
|
||||
to be written. By default, this limit is 333 entries per second max.
|
||||
|
||||
Signed-off-by: Angel Velazquez <angelcar@amazon.com>
|
||||
---
|
||||
daemon/logger/copier.go | 6 ++----
|
||||
daemon/logger/logger_error.go | 24 ++++++++++++++++++++++++
|
||||
daemon/logger/ring.go | 12 ++----------
|
||||
3 files changed, 28 insertions(+), 14 deletions(-)
|
||||
create mode 100644 daemon/logger/logger_error.go
|
||||
|
||||
diff --git a/daemon/logger/copier.go b/daemon/logger/copier.go
|
||||
index e2ee36c0987e..30c68ea364d2 100644
|
||||
--- a/daemon/logger/copier.go
|
||||
+++ b/daemon/logger/copier.go
|
||||
@@ -126,8 +126,7 @@ func (c *Copier) copySrc(name string, src io.Reader) {
|
||||
}
|
||||
|
||||
if logErr := c.dst.Log(msg); logErr != nil {
|
||||
- logWritesFailedCount.Inc(1)
|
||||
- logrus.Errorf("Failed to log msg %q for logger %s: %s", msg.Line, c.dst.Name(), logErr)
|
||||
+ logDriverError(c.dst.Name(), string(msg.Line), logErr)
|
||||
}
|
||||
}
|
||||
p += q + 1
|
||||
@@ -159,8 +158,7 @@ func (c *Copier) copySrc(name string, src io.Reader) {
|
||||
hasMorePartial = true
|
||||
|
||||
if logErr := c.dst.Log(msg); logErr != nil {
|
||||
- logWritesFailedCount.Inc(1)
|
||||
- logrus.Errorf("Failed to log msg %q for logger %s: %s", msg.Line, c.dst.Name(), logErr)
|
||||
+ logDriverError(c.dst.Name(), string(msg.Line), logErr)
|
||||
}
|
||||
p = 0
|
||||
n = 0
|
||||
diff --git a/daemon/logger/logger_error.go b/daemon/logger/logger_error.go
|
||||
new file mode 100644
|
||||
index 000000000000..70f4311979c4
|
||||
--- /dev/null
|
||||
+++ b/daemon/logger/logger_error.go
|
||||
@@ -0,0 +1,24 @@
|
||||
+package logger
|
||||
+
|
||||
+import (
|
||||
+ "github.com/sirupsen/logrus"
|
||||
+ "golang.org/x/time/rate"
|
||||
+)
|
||||
+
|
||||
+// Rates based on journald defaults of 10,000 messages in 30s.
|
||||
+// reference: https://www.freedesktop.org/software/systemd/man/journald.conf.html#RateLimitIntervalSec=
|
||||
+var logErrorLimiter = rate.NewLimiter(333, 333)
|
||||
+
|
||||
+// logDriverError logs errors produced by log drivers to the daemon logs. It also increments the logWritesFailedCount
|
||||
+// metric.
|
||||
+// Logging to the daemon logs is limited to 333 operations per second at most. If this limit is exceeded, the
|
||||
+// logWritesFailedCount is still counted, but logging to the daemon logs is omitted in order to prevent disk saturation.
|
||||
+func logDriverError(loggerName, msgLine string, logErr error) {
|
||||
+ logWritesFailedCount.Inc(1)
|
||||
+ if logErrorLimiter.Allow() {
|
||||
+ logrus.WithError(logErr).
|
||||
+ WithField("driver", loggerName).
|
||||
+ WithField("message", msgLine).
|
||||
+ Errorf("Error writing log message")
|
||||
+ }
|
||||
+}
|
||||
diff --git a/daemon/logger/ring.go b/daemon/logger/ring.go
|
||||
index b6432aed36f7..3b2652af63c1 100644
|
||||
--- a/daemon/logger/ring.go
|
||||
+++ b/daemon/logger/ring.go
|
||||
@@ -4,8 +4,6 @@ import (
|
||||
"errors"
|
||||
"sync"
|
||||
"sync/atomic"
|
||||
-
|
||||
- "github.com/sirupsen/logrus"
|
||||
)
|
||||
|
||||
const (
|
||||
@@ -104,10 +102,7 @@ func (r *RingLogger) Close() error {
|
||||
}
|
||||
|
||||
if err := r.l.Log(msg); err != nil {
|
||||
- logrus.WithField("driver", r.l.Name()).
|
||||
- WithField("container", r.logInfo.ContainerID).
|
||||
- WithError(err).
|
||||
- Errorf("Error writing log message")
|
||||
+ logDriverError(r.l.Name(), string(msg.Line), err)
|
||||
logErr = true
|
||||
}
|
||||
}
|
||||
@@ -128,10 +123,7 @@ func (r *RingLogger) run() {
|
||||
return
|
||||
}
|
||||
if err := r.l.Log(msg); err != nil {
|
||||
- logrus.WithField("driver", r.l.Name()).
|
||||
- WithField("container", r.logInfo.ContainerID).
|
||||
- WithError(err).
|
||||
- Errorf("Error writing log message")
|
||||
+ logDriverError(r.l.Name(), string(msg.Line), err)
|
||||
}
|
||||
}
|
||||
}
|
@ -1,47 +0,0 @@
|
||||
From e2d3dd827bcca6cba9e0f2b869d872af07ff2999 Mon Sep 17 00:00:00 2001
|
||||
From: Jamie Anderson <jamieand@amazon.com>
|
||||
Date: Mon, 22 Mar 2021 20:33:57 +0000
|
||||
Subject: [PATCH] Restore containerd dependency, restart policy, and nofile
|
||||
settings to service file
|
||||
|
||||
Signed-off-by: Jamie Anderson <jamieand@amazon.com>
|
||||
---
|
||||
contrib/init/systemd/docker.service | 8 +++++---
|
||||
1 file changed, 5 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/contrib/init/systemd/docker.service b/contrib/init/systemd/docker.service
|
||||
index 7e87245..1654f0b 100644
|
||||
--- a/contrib/init/systemd/docker.service
|
||||
+++ b/contrib/init/systemd/docker.service
|
||||
@@ -1,7 +1,8 @@
|
||||
[Unit]
|
||||
Description=Docker Application Container Engine
|
||||
Documentation=https://docs.docker.com
|
||||
-After=network-online.target docker.socket firewalld.service
|
||||
+BindsTo=containerd.service
|
||||
+After=network-online.target docker.socket firewalld.service containerd.service
|
||||
Wants=network-online.target
|
||||
Requires=docker.socket
|
||||
|
||||
@@ -17,7 +18,7 @@ ExecStartPre=/usr/libexec/docker/docker-setup-runtimes.sh
|
||||
# for containers run by docker
|
||||
ExecStart=/usr/bin/dockerd -H fd:// --containerd=/run/containerd/containerd.sock $OPTIONS $DOCKER_STORAGE_OPTIONS $DOCKER_ADD_RUNTIMES
|
||||
ExecReload=/bin/kill -s HUP $MAINPID
|
||||
-LimitNOFILE=1048576
|
||||
+LimitNOFILE=infinity
|
||||
# Having non-zero Limit*s causes performance problems due to accounting overhead
|
||||
# in the kernel. We recommend using cgroups to do container-local accounting.
|
||||
LimitNPROC=infinity
|
||||
@@ -31,7 +32,8 @@ Delegate=yes
|
||||
# kill only the docker process, not all processes in the cgroup
|
||||
KillMode=process
|
||||
# restart the docker process if it exits prematurely
|
||||
-Restart=on-failure
|
||||
+RestartSec=2
|
||||
+Restart=always
|
||||
StartLimitBurst=3
|
||||
StartLimitInterval=60s
|
||||
|
||||
--
|
||||
2.31.0.rc2
|
||||
|
@ -1,33 +0,0 @@
|
||||
From ff6ad03b4a9774b2a87c12445b31f54078c06b55 Mon Sep 17 00:00:00 2001
|
||||
From: Jamie Anderson <jamieand@amazon.com>
|
||||
Date: Thu, 4 Mar 2021 17:48:05 +0000
|
||||
Subject: [PATCH] Skip auth/middleware test that creates sockets
|
||||
|
||||
Signed-off-by: Jamie Anderson <jamieand@amazon.com>
|
||||
---
|
||||
pkg/authorization/middleware_unix_test.go | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/pkg/authorization/middleware_unix_test.go b/pkg/authorization/middleware_unix_test.go
|
||||
index 468cb59..b5e26ac 100644
|
||||
--- a/pkg/authorization/middleware_unix_test.go
|
||||
+++ b/pkg/authorization/middleware_unix_test.go
|
||||
@@ -7,6 +7,7 @@ import (
|
||||
"net/http"
|
||||
"net/http/httptest"
|
||||
"testing"
|
||||
+ "github.com/docker/docker/testutil"
|
||||
|
||||
"github.com/docker/docker/pkg/plugingetter"
|
||||
"gotest.tools/v3/assert"
|
||||
@@ -14,6 +15,7 @@ import (
|
||||
)
|
||||
|
||||
func TestMiddlewareWrapHandler(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
server := authZPluginTestServer{t: t}
|
||||
server.start()
|
||||
defer server.stop()
|
||||
--
|
||||
2.25.0.24.gbc7a3d4
|
||||
|
@ -1,53 +0,0 @@
|
||||
From 4d116f8caee01d47e344571c0fe4b805ae44e8d8 Mon Sep 17 00:00:00 2001
|
||||
From: Jamie Anderson <jamieand@amazon.com>
|
||||
Date: Fri, 19 Mar 2021 20:59:20 +0000
|
||||
Subject: [PATCH] Skip btrfs graphdriver tests if not root
|
||||
|
||||
Signed-off-by: Jamie Anderson <jamieand@amazon.com>
|
||||
---
|
||||
daemon/graphdriver/btrfs/btrfs_test.go | 6 ++++++
|
||||
1 file changed, 6 insertions(+)
|
||||
|
||||
diff --git a/daemon/graphdriver/btrfs/btrfs_test.go b/daemon/graphdriver/btrfs/btrfs_test.go
|
||||
index b70e93b..c75960b 100644
|
||||
--- a/daemon/graphdriver/btrfs/btrfs_test.go
|
||||
+++ b/daemon/graphdriver/btrfs/btrfs_test.go
|
||||
@@ -6,6 +6,7 @@ import (
|
||||
"os"
|
||||
"path"
|
||||
"testing"
|
||||
+ "github.com/docker/docker/testutil"
|
||||
|
||||
"github.com/docker/docker/daemon/graphdriver/graphtest"
|
||||
)
|
||||
@@ -13,22 +14,27 @@ import (
|
||||
// This avoids creating a new driver for each test if all tests are run
|
||||
// Make sure to put new tests between TestBtrfsSetup and TestBtrfsTeardown
|
||||
func TestBtrfsSetup(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
graphtest.GetDriver(t, "btrfs")
|
||||
}
|
||||
|
||||
func TestBtrfsCreateEmpty(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
graphtest.DriverTestCreateEmpty(t, "btrfs")
|
||||
}
|
||||
|
||||
func TestBtrfsCreateBase(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
graphtest.DriverTestCreateBase(t, "btrfs")
|
||||
}
|
||||
|
||||
func TestBtrfsCreateSnap(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
graphtest.DriverTestCreateSnap(t, "btrfs")
|
||||
}
|
||||
|
||||
func TestBtrfsSubvolDelete(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
d := graphtest.GetDriver(t, "btrfs")
|
||||
if err := d.CreateReadWrite("test", "", nil); err != nil {
|
||||
t.Fatal(err)
|
||||
--
|
||||
2.31.0.rc2
|
||||
|
@ -1,102 +0,0 @@
|
||||
From 1f8ac5f2a45ccbedb0904f6ac938f94ea655c49a Mon Sep 17 00:00:00 2001
|
||||
From: Jamie Anderson <jamieand@amazon.com>
|
||||
Date: Wed, 3 Mar 2021 22:00:57 +0000
|
||||
Subject: [PATCH] Skip builder tests that require root
|
||||
|
||||
Signed-off-by: Jamie Anderson <jamieand@amazon.com>
|
||||
---
|
||||
builder/dockerfile/internals_test.go | 5 +++++
|
||||
builder/remotecontext/tarsum_test.go | 5 +++++
|
||||
2 files changed, 10 insertions(+)
|
||||
|
||||
diff --git a/builder/dockerfile/internals_test.go b/builder/dockerfile/internals_test.go
|
||||
index 5353167..5a68a39 100644
|
||||
--- a/builder/dockerfile/internals_test.go
|
||||
+++ b/builder/dockerfile/internals_test.go
|
||||
@@ -5,6 +5,7 @@ import (
|
||||
"os"
|
||||
"runtime"
|
||||
"testing"
|
||||
+ "github.com/docker/docker/testutil"
|
||||
|
||||
"github.com/docker/docker/api/types"
|
||||
"github.com/docker/docker/api/types/backend"
|
||||
@@ -23,6 +24,7 @@ import (
|
||||
)
|
||||
|
||||
func TestEmptyDockerfile(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
contextDir, cleanup := createTestTempDir(t, "", "builder-dockerfile-test")
|
||||
defer cleanup()
|
||||
|
||||
@@ -32,6 +34,7 @@ func TestEmptyDockerfile(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestSymlinkDockerfile(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
contextDir, cleanup := createTestTempDir(t, "", "builder-dockerfile-test")
|
||||
defer cleanup()
|
||||
|
||||
@@ -47,6 +50,7 @@ func TestSymlinkDockerfile(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestDockerfileOutsideTheBuildContext(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
contextDir, cleanup := createTestTempDir(t, "", "builder-dockerfile-test")
|
||||
defer cleanup()
|
||||
|
||||
@@ -59,6 +63,7 @@ func TestDockerfileOutsideTheBuildContext(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestNonExistingDockerfile(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
contextDir, cleanup := createTestTempDir(t, "", "builder-dockerfile-test")
|
||||
defer cleanup()
|
||||
|
||||
diff --git a/builder/remotecontext/tarsum_test.go b/builder/remotecontext/tarsum_test.go
|
||||
index c6a417d..93643a5 100644
|
||||
--- a/builder/remotecontext/tarsum_test.go
|
||||
+++ b/builder/remotecontext/tarsum_test.go
|
||||
@@ -5,6 +5,7 @@ import (
|
||||
"os"
|
||||
"path/filepath"
|
||||
"testing"
|
||||
+ "github.com/docker/docker/testutil"
|
||||
|
||||
"github.com/docker/docker/builder"
|
||||
"github.com/docker/docker/pkg/archive"
|
||||
@@ -23,6 +24,7 @@ func init() {
|
||||
}
|
||||
|
||||
func TestCloseRootDirectory(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
contextDir, err := os.MkdirTemp("", "builder-tarsum-test")
|
||||
defer os.RemoveAll(contextDir)
|
||||
if err != nil {
|
||||
@@ -44,6 +46,7 @@ func TestCloseRootDirectory(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestHashFile(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
contextDir, cleanup := createTestTempDir(t, "", "builder-tarsum-test")
|
||||
defer cleanup()
|
||||
|
||||
@@ -69,6 +72,7 @@ func TestHashFile(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestHashSubdir(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
contextDir, cleanup := createTestTempDir(t, "", "builder-tarsum-test")
|
||||
defer cleanup()
|
||||
|
||||
@@ -106,6 +110,7 @@ func TestHashSubdir(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestRemoveDirectory(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
contextDir, cleanup := createTestTempDir(t, "", "builder-tarsum-test")
|
||||
defer cleanup()
|
||||
|
||||
--
|
||||
2.25.0.24.gbc7a3d4
|
||||
|
@ -1,54 +0,0 @@
|
||||
From 29cf333688cf38c615f6a2c4dfc8a1fddbbbb4aa Mon Sep 17 00:00:00 2001
|
||||
From: Jamie Anderson <jamieand@amazon.com>
|
||||
Date: Wed, 3 Mar 2021 23:02:57 +0000
|
||||
Subject: [PATCH] Skip cli tests that require network
|
||||
|
||||
Signed-off-by: Jamie Anderson <jamieand@amazon.com>
|
||||
---
|
||||
cli/command/image/pull_test.go | 2 ++
|
||||
cli/command/image/push_test.go | 2 ++
|
||||
2 files changed, 4 insertions(+)
|
||||
|
||||
diff --git a/cli/command/image/pull_test.go b/cli/command/image/pull_test.go
|
||||
index b9d4970..bb7ce0e 100644
|
||||
--- a/cli/command/image/pull_test.go
|
||||
+++ b/cli/command/image/pull_test.go
|
||||
@@ -6,6 +6,7 @@ import (
|
||||
"io"
|
||||
"strings"
|
||||
"testing"
|
||||
+ "github.com/docker/cli/testutil"
|
||||
|
||||
"github.com/docker/cli/internal/test"
|
||||
"github.com/docker/cli/internal/test/notary"
|
||||
@@ -16,6 +17,7 @@ import (
|
||||
)
|
||||
|
||||
func TestNewPullCommandErrors(t *testing.T) {
|
||||
+ testutil.SkipIfBuildroot(t)
|
||||
testCases := []struct {
|
||||
name string
|
||||
args []string
|
||||
diff --git a/cli/command/image/push_test.go b/cli/command/image/push_test.go
|
||||
index 9636369..14bfbd2 100644
|
||||
--- a/cli/command/image/push_test.go
|
||||
+++ b/cli/command/image/push_test.go
|
||||
@@ -5,6 +5,7 @@ import (
|
||||
"io"
|
||||
"strings"
|
||||
"testing"
|
||||
+ "github.com/docker/cli/testutil"
|
||||
|
||||
"github.com/docker/cli/internal/test"
|
||||
"github.com/docker/docker/api/types"
|
||||
@@ -13,6 +14,7 @@ import (
|
||||
)
|
||||
|
||||
func TestNewPushCommandErrors(t *testing.T) {
|
||||
+ testutil.SkipIfBuildroot(t)
|
||||
testCases := []struct {
|
||||
name string
|
||||
args []string
|
||||
--
|
||||
2.25.0.24.gbc7a3d4
|
||||
|
@ -1,46 +0,0 @@
|
||||
From 4622551eb4d29bee8fb30290368a4cce5af56737 Mon Sep 17 00:00:00 2001
|
||||
From: Jamie Anderson <jamieand@amazon.com>
|
||||
Date: Fri, 19 Mar 2021 20:10:01 +0000
|
||||
Subject: [PATCH] Skip compression tests that require root
|
||||
|
||||
Signed-off-by: Jamie Anderson <jamieand@amazon.com>
|
||||
---
|
||||
cli/command/image/build/context_test.go | 2 ++
|
||||
cli/command/image/build_test.go | 1 +
|
||||
2 files changed, 3 insertions(+)
|
||||
|
||||
diff --git a/cli/command/image/build/context_test.go b/cli/command/image/build/context_test.go
|
||||
index f216978..1dbea0b 100644
|
||||
--- a/cli/command/image/build/context_test.go
|
||||
+++ b/cli/command/image/build/context_test.go
|
||||
@@ -10,6 +10,7 @@ import (
|
||||
"runtime"
|
||||
"strings"
|
||||
"testing"
|
||||
+ "github.com/docker/cli/testutil"
|
||||
|
||||
"github.com/docker/docker/pkg/archive"
|
||||
"github.com/docker/docker/pkg/fileutils"
|
||||
@@ -173,6 +174,7 @@ func TestGetContextFromReaderString(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestGetContextFromReaderTar(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
contextDir := createTestTempDir(t)
|
||||
createTestTempFile(t, contextDir, DefaultDockerfileName, dockerfileContents)
|
||||
|
||||
diff --git a/cli/command/image/build_test.go b/cli/command/image/build_test.go
|
||||
index cef80a3..34014dd 100644
|
||||
--- a/cli/command/image/build_test.go
|
||||
+++ b/cli/command/image/build_test.go
|
||||
@@ -27,6 +27,7 @@ import (
|
||||
)
|
||||
|
||||
func TestRunBuildDockerfileFromStdinWithCompress(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
defer env.Patch(t, "DOCKER_BUILDKIT", "0")()
|
||||
buffer := new(bytes.Buffer)
|
||||
fakeBuild := newFakeBuild()
|
||||
--
|
||||
2.31.0.rc2
|
||||
|
@ -1,85 +0,0 @@
|
||||
From 00faa3a1652a57c9f8f6ceeb930020680d3d5295 Mon Sep 17 00:00:00 2001
|
||||
From: Jamie Anderson <jamieand@amazon.com>
|
||||
Date: Tue, 2 Mar 2021 19:11:09 +0000
|
||||
Subject: [PATCH] Skip devmapper tests that don't work in a buildroot
|
||||
|
||||
Signed-off-by: Jamie Anderson <jamieand@amazon.com>
|
||||
---
|
||||
daemon/graphdriver/devmapper/devmapper_test.go | 13 +++++++++++++
|
||||
1 file changed, 13 insertions(+)
|
||||
|
||||
diff --git a/daemon/graphdriver/devmapper/devmapper_test.go b/daemon/graphdriver/devmapper/devmapper_test.go
|
||||
index afd6c5b..dc59dc5 100644
|
||||
--- a/daemon/graphdriver/devmapper/devmapper_test.go
|
||||
+++ b/daemon/graphdriver/devmapper/devmapper_test.go
|
||||
@@ -8,6 +8,7 @@ import (
|
||||
"os/exec"
|
||||
"syscall"
|
||||
"testing"
|
||||
+ "github.com/docker/docker/testutil"
|
||||
"time"
|
||||
|
||||
"github.com/docker/docker/daemon/graphdriver"
|
||||
@@ -17,6 +18,10 @@ import (
|
||||
)
|
||||
|
||||
func init() {
|
||||
+ if _, err := os.Stat("/.initialized"); err == nil {
|
||||
+ // Don't try to call initLoopbacks() in a buildroot
|
||||
+ return nil
|
||||
+ }
|
||||
// Reduce the size of the base fs and loopback for the tests
|
||||
defaultDataLoopbackSize = 300 * 1024 * 1024
|
||||
defaultMetaDataLoopbackSize = 200 * 1024 * 1024
|
||||
@@ -71,26 +76,32 @@ func getBaseLoopStats() (*syscall.Stat_t, error) {
|
||||
// This avoids creating a new driver for each test if all tests are run
|
||||
// Make sure to put new tests between TestDevmapperSetup and TestDevmapperTeardown
|
||||
func TestDevmapperSetup(t *testing.T) {
|
||||
+ testutil.SkipIfBuildroot(t)
|
||||
graphtest.GetDriver(t, "devicemapper")
|
||||
}
|
||||
|
||||
func TestDevmapperCreateEmpty(t *testing.T) {
|
||||
+ testutil.SkipIfBuildroot(t)
|
||||
graphtest.DriverTestCreateEmpty(t, "devicemapper")
|
||||
}
|
||||
|
||||
func TestDevmapperCreateBase(t *testing.T) {
|
||||
+ testutil.SkipIfBuildroot(t)
|
||||
graphtest.DriverTestCreateBase(t, "devicemapper")
|
||||
}
|
||||
|
||||
func TestDevmapperCreateSnap(t *testing.T) {
|
||||
+ testutil.SkipIfBuildroot(t)
|
||||
graphtest.DriverTestCreateSnap(t, "devicemapper")
|
||||
}
|
||||
|
||||
func TestDevmapperTeardown(t *testing.T) {
|
||||
+ testutil.SkipIfBuildroot(t)
|
||||
graphtest.PutDriver(t)
|
||||
}
|
||||
|
||||
func TestDevmapperReduceLoopBackSize(t *testing.T) {
|
||||
+ testutil.SkipIfBuildroot(t)
|
||||
tenMB := int64(10 * 1024 * 1024)
|
||||
testChangeLoopBackSize(t, -tenMB, defaultDataLoopbackSize, defaultMetaDataLoopbackSize)
|
||||
}
|
||||
@@ -101,6 +112,7 @@ func TestDevmapperIncreaseLoopBackSize(t *testing.T) {
|
||||
}
|
||||
|
||||
func testChangeLoopBackSize(t *testing.T, delta, expectDataSize, expectMetaDataSize int64) {
|
||||
+ testutil.SkipIfBuildroot(t)
|
||||
driver := graphtest.GetDriver(t, "devicemapper").(*graphtest.Driver).Driver.(*graphdriver.NaiveDiffDriver).ProtoDriver.(*Driver)
|
||||
defer graphtest.PutDriver(t)
|
||||
// make sure data or metadata loopback size are the default size
|
||||
@@ -129,6 +141,7 @@ func testChangeLoopBackSize(t *testing.T, delta, expectDataSize, expectMetaDataS
|
||||
|
||||
// Make sure devices.Lock() has been release upon return from cleanupDeletedDevices() function
|
||||
func TestDevmapperLockReleasedDeviceDeletion(t *testing.T) {
|
||||
+ testutil.SkipIfBuildroot(t)
|
||||
driver := graphtest.GetDriver(t, "devicemapper").(*graphtest.Driver).Driver.(*graphdriver.NaiveDiffDriver).ProtoDriver.(*Driver)
|
||||
defer graphtest.PutDriver(t)
|
||||
|
||||
--
|
||||
2.25.0.24.gbc7a3d4
|
||||
|
@ -1,32 +0,0 @@
|
||||
From e880fb184cc9147cc9dd3387752c1ef8b3d20be2 Mon Sep 17 00:00:00 2001
|
||||
From: Jamie Anderson <jamieand@amazon.com>
|
||||
Date: Wed, 3 Mar 2021 21:20:24 +0000
|
||||
Subject: [PATCH] Skip distribution tests that network
|
||||
|
||||
Signed-off-by: Jamie Anderson <jamieand@amazon.com>
|
||||
---
|
||||
distribution/xfer/transfer_test.go | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/distribution/xfer/transfer_test.go b/distribution/xfer/transfer_test.go
|
||||
index f8f8e96..6764f17 100644
|
||||
--- a/distribution/xfer/transfer_test.go
|
||||
+++ b/distribution/xfer/transfer_test.go
|
||||
@@ -3,12 +3,14 @@ package xfer // import "github.com/docker/docker/distribution/xfer"
|
||||
import (
|
||||
"sync/atomic"
|
||||
"testing"
|
||||
+ "github.com/docker/docker/testutil"
|
||||
"time"
|
||||
|
||||
"github.com/docker/docker/pkg/progress"
|
||||
)
|
||||
|
||||
func TestTransfer(t *testing.T) {
|
||||
+ testutil.SkipIfBuildroot(t)
|
||||
makeXferFunc := func(id string) DoFunc {
|
||||
return func(progressChan chan<- progress.Progress, start <-chan struct{}, _ chan<- struct{}) Transfer {
|
||||
select {
|
||||
--
|
||||
2.25.0.24.gbc7a3d4
|
||||
|
@ -1,160 +0,0 @@
|
||||
From bad779d02c86a9cf6bdd3b376920093da9441739 Mon Sep 17 00:00:00 2001
|
||||
From: Jamie Anderson <jamieand@amazon.com>
|
||||
Date: Mon, 8 Mar 2021 19:27:36 +0000
|
||||
Subject: [PATCH] Skip layer tests that require root
|
||||
|
||||
Signed-off-by: Jamie Anderson <jamieand@amazon.com>
|
||||
---
|
||||
layer/layer_test.go | 7 +++++++
|
||||
layer/layer_unix_test.go | 2 ++
|
||||
layer/migration_test.go | 3 +++
|
||||
layer/mount_test.go | 4 ++++
|
||||
4 files changed, 16 insertions(+)
|
||||
|
||||
diff --git a/layer/layer_test.go b/layer/layer_test.go
|
||||
index 9199b9c..abd6bde 100644
|
||||
--- a/layer/layer_test.go
|
||||
+++ b/layer/layer_test.go
|
||||
@@ -9,6 +9,7 @@ import (
|
||||
"runtime"
|
||||
"strings"
|
||||
"testing"
|
||||
+ "github.com/docker/docker/testutil"
|
||||
|
||||
"github.com/containerd/continuity/driver"
|
||||
"github.com/docker/docker/daemon/graphdriver"
|
||||
@@ -258,6 +259,7 @@ func assertLayerEqual(t *testing.T, l1, l2 Layer) {
|
||||
}
|
||||
|
||||
func TestMountAndRegister(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
ls, _, cleanup := newTestStore(t)
|
||||
defer cleanup()
|
||||
|
||||
@@ -299,6 +301,7 @@ func TestMountAndRegister(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestLayerRelease(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
// TODO Windows: Figure out why this is failing
|
||||
if runtime.GOOS == "windows" {
|
||||
t.Skip("Failing on Windows")
|
||||
@@ -348,6 +351,7 @@ func TestLayerRelease(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestStoreRestore(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
// TODO Windows: Figure out why this is failing
|
||||
if runtime.GOOS == "windows" {
|
||||
t.Skip("Failing on Windows")
|
||||
@@ -463,6 +467,7 @@ func TestStoreRestore(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestTarStreamStability(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
// TODO Windows: Figure out why this is failing
|
||||
if runtime.GOOS == "windows" {
|
||||
t.Skip("Failing on Windows")
|
||||
@@ -656,6 +661,7 @@ func assertReferences(t *testing.T, references ...Layer) {
|
||||
}
|
||||
|
||||
func TestRegisterExistingLayer(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
ls, _, cleanup := newTestStore(t)
|
||||
defer cleanup()
|
||||
|
||||
@@ -692,6 +698,7 @@ func TestRegisterExistingLayer(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestTarStreamVerification(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
// TODO Windows: Figure out why this is failing
|
||||
if runtime.GOOS == "windows" {
|
||||
t.Skip("Failing on Windows")
|
||||
diff --git a/layer/layer_unix_test.go b/layer/layer_unix_test.go
|
||||
index 6830158..fc12af7 100644
|
||||
--- a/layer/layer_unix_test.go
|
||||
+++ b/layer/layer_unix_test.go
|
||||
@@ -4,6 +4,7 @@ package layer // import "github.com/docker/docker/layer"
|
||||
|
||||
import (
|
||||
"testing"
|
||||
+ "github.com/docker/docker/testutil"
|
||||
)
|
||||
|
||||
func graphDiffSize(ls Store, l Layer) (int64, error) {
|
||||
@@ -18,6 +19,7 @@ func graphDiffSize(ls Store, l Layer) (int64, error) {
|
||||
// Unix as Windows graph driver does not support Changes which is indirectly
|
||||
// invoked by calling DiffSize on the driver
|
||||
func TestLayerSize(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
ls, _, cleanup := newTestStore(t)
|
||||
defer cleanup()
|
||||
|
||||
diff --git a/layer/migration_test.go b/layer/migration_test.go
|
||||
index 2b5c330..1cb6d0d 100644
|
||||
--- a/layer/migration_test.go
|
||||
+++ b/layer/migration_test.go
|
||||
@@ -9,6 +9,7 @@ import (
|
||||
"path/filepath"
|
||||
"runtime"
|
||||
"testing"
|
||||
+ "github.com/docker/docker/testutil"
|
||||
|
||||
"github.com/docker/docker/daemon/graphdriver"
|
||||
"github.com/docker/docker/pkg/stringid"
|
||||
@@ -41,6 +42,7 @@ func writeTarSplitFile(name string, tarContent []byte) error {
|
||||
}
|
||||
|
||||
func TestLayerMigration(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
// TODO Windows: Figure out why this is failing
|
||||
if runtime.GOOS == "windows" {
|
||||
t.Skip("Failing on Windows")
|
||||
@@ -177,6 +179,7 @@ func tarFromFilesInGraph(graph graphdriver.Driver, graphID, parentID string, fil
|
||||
}
|
||||
|
||||
func TestLayerMigrationNoTarsplit(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
// TODO Windows: Figure out why this is failing
|
||||
if runtime.GOOS == "windows" {
|
||||
t.Skip("Failing on Windows")
|
||||
diff --git a/layer/mount_test.go b/layer/mount_test.go
|
||||
index 3c868b2..c2ea782 100644
|
||||
--- a/layer/mount_test.go
|
||||
+++ b/layer/mount_test.go
|
||||
@@ -5,6 +5,7 @@ import (
|
||||
"runtime"
|
||||
"sort"
|
||||
"testing"
|
||||
+ "github.com/docker/docker/testutil"
|
||||
|
||||
"github.com/containerd/continuity/driver"
|
||||
"github.com/docker/docker/pkg/archive"
|
||||
@@ -12,6 +13,7 @@ import (
|
||||
)
|
||||
|
||||
func TestMountInit(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
// TODO Windows: Figure out why this is failing
|
||||
if runtime.GOOS == "windows" {
|
||||
t.Skip("Failing on Windows")
|
||||
@@ -71,6 +73,7 @@ func TestMountInit(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestMountSize(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
// TODO Windows: Figure out why this is failing
|
||||
if runtime.GOOS == "windows" {
|
||||
t.Skip("Failing on Windows")
|
||||
@@ -120,6 +123,7 @@ func TestMountSize(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestMountChanges(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
// TODO Windows: Figure out why this is failing
|
||||
if runtime.GOOS == "windows" {
|
||||
t.Skip("Failing on Windows")
|
||||
--
|
||||
2.25.0.24.gbc7a3d4
|
||||
|
@ -1,33 +0,0 @@
|
||||
From a7a12b2fcec36a5d60e60f87dc6808bdf012f4d8 Mon Sep 17 00:00:00 2001
|
||||
From: Jamie Anderson <jamieand@amazon.com>
|
||||
Date: Thu, 11 Mar 2021 21:40:57 +0000
|
||||
Subject: [PATCH] Skip daemon/TestGetSourceMount in buildroot
|
||||
|
||||
Signed-off-by: Jamie Anderson <jamieand@amazon.com>
|
||||
---
|
||||
daemon/oci_linux_test.go | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/daemon/oci_linux_test.go b/daemon/oci_linux_test.go
|
||||
index 890875a..f814dbc 100644
|
||||
--- a/daemon/oci_linux_test.go
|
||||
+++ b/daemon/oci_linux_test.go
|
||||
@@ -5,6 +5,7 @@ import (
|
||||
"os"
|
||||
"path/filepath"
|
||||
"testing"
|
||||
+ "github.com/docker/docker/testutil"
|
||||
|
||||
containertypes "github.com/docker/docker/api/types/container"
|
||||
"github.com/docker/docker/container"
|
||||
@@ -180,6 +181,7 @@ func TestSysctlOverrideHost(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestGetSourceMount(t *testing.T) {
|
||||
+ testutil.SkipIfBuildroot(t)
|
||||
// must be able to find source mount for /
|
||||
mnt, _, err := getSourceMount("/")
|
||||
assert.NilError(t, err)
|
||||
--
|
||||
2.31.0.rc2
|
||||
|
@ -1,35 +0,0 @@
|
||||
From 41d73e0b128e30ea17f5e319906846a9da2fcdd5 Mon Sep 17 00:00:00 2001
|
||||
From: Jamie Anderson <jamieand@amazon.com>
|
||||
Date: Fri, 19 Mar 2021 18:34:30 +0000
|
||||
Subject: [PATCH] Skip git tests
|
||||
|
||||
These tests fail in a buildroot because they try to talk to GitHub
|
||||
|
||||
Signed-off-by: Jamie Anderson <jamieand@amazon.com>
|
||||
---
|
||||
cli/command/image/build_test.go | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/cli/command/image/build_test.go b/cli/command/image/build_test.go
|
||||
index 4317a74..cef80a3 100644
|
||||
--- a/cli/command/image/build_test.go
|
||||
+++ b/cli/command/image/build_test.go
|
||||
@@ -12,6 +12,7 @@ import (
|
||||
"path/filepath"
|
||||
"sort"
|
||||
"testing"
|
||||
+ "github.com/docker/cli/testutil"
|
||||
|
||||
"github.com/docker/cli/cli/streams"
|
||||
"github.com/docker/cli/internal/test"
|
||||
@@ -126,6 +127,7 @@ COPY data /data
|
||||
// TODO: test "context selection" logic directly when runBuild is refactored
|
||||
// to support testing (ex: docker/cli#294)
|
||||
func TestRunBuildFromGitHubSpecialCase(t *testing.T) {
|
||||
+ testutil.SkipIfBuildroot(t)
|
||||
defer env.Patch(t, "DOCKER_BUILDKIT", "0")()
|
||||
cmd := NewBuildCommand(test.NewFakeCli(&fakeClient{}))
|
||||
// Clone a small repo that exists so git doesn't prompt for credentials
|
||||
--
|
||||
2.31.0.rc2
|
||||
|
@ -1,57 +0,0 @@
|
||||
From 29304ba81dd3a600454c017d7720a608143d87a0 Mon Sep 17 00:00:00 2001
|
||||
From: Jamie Anderson <jamieand@amazon.com>
|
||||
Date: Tue, 2 Mar 2021 19:26:37 +0000
|
||||
Subject: [PATCH] Skip mutating vfs tests
|
||||
|
||||
Signed-off-by: Jamie Anderson <jamieand@amazon.com>
|
||||
---
|
||||
daemon/graphdriver/vfs/vfs_test.go | 7 +++++++
|
||||
1 file changed, 7 insertions(+)
|
||||
|
||||
diff --git a/daemon/graphdriver/vfs/vfs_test.go b/daemon/graphdriver/vfs/vfs_test.go
|
||||
index 7c59ec3..9562959 100644
|
||||
--- a/daemon/graphdriver/vfs/vfs_test.go
|
||||
+++ b/daemon/graphdriver/vfs/vfs_test.go
|
||||
@@ -4,6 +4,7 @@ package vfs // import "github.com/docker/docker/daemon/graphdriver/vfs"
|
||||
|
||||
import (
|
||||
"testing"
|
||||
+ "github.com/docker/docker/testutil"
|
||||
|
||||
"github.com/docker/docker/daemon/graphdriver/graphtest"
|
||||
|
||||
@@ -17,25 +18,31 @@ func init() {
|
||||
// This avoids creating a new driver for each test if all tests are run
|
||||
// Make sure to put new tests between TestVfsSetup and TestVfsTeardown
|
||||
func TestVfsSetup(t *testing.T) {
|
||||
+ testutil.SkipIfBuildroot(t)
|
||||
graphtest.GetDriver(t, "vfs")
|
||||
}
|
||||
|
||||
func TestVfsCreateEmpty(t *testing.T) {
|
||||
+ testutil.SkipIfBuildroot(t)
|
||||
graphtest.DriverTestCreateEmpty(t, "vfs")
|
||||
}
|
||||
|
||||
func TestVfsCreateBase(t *testing.T) {
|
||||
+ testutil.SkipIfBuildroot(t)
|
||||
graphtest.DriverTestCreateBase(t, "vfs")
|
||||
}
|
||||
|
||||
func TestVfsCreateSnap(t *testing.T) {
|
||||
+ testutil.SkipIfBuildroot(t)
|
||||
graphtest.DriverTestCreateSnap(t, "vfs")
|
||||
}
|
||||
|
||||
func TestVfsSetQuota(t *testing.T) {
|
||||
+ testutil.SkipIfBuildroot(t)
|
||||
graphtest.DriverTestSetQuota(t, "vfs", false)
|
||||
}
|
||||
|
||||
func TestVfsTeardown(t *testing.T) {
|
||||
+ testutil.SkipIfBuildroot(t)
|
||||
graphtest.PutDriver(t)
|
||||
}
|
||||
--
|
||||
2.25.0.24.gbc7a3d4
|
||||
|
@ -1,57 +0,0 @@
|
||||
From cdaa60828f12a4e3f122e2120e57c6508456cb4d Mon Sep 17 00:00:00 2001
|
||||
From: Jamie Anderson <jamieand@amazon.com>
|
||||
Date: Wed, 3 Mar 2021 17:55:10 +0000
|
||||
Subject: [PATCH] Skip mutating volume/local tests
|
||||
|
||||
Signed-off-by: Jamie Anderson <jamieand@amazon.com>
|
||||
---
|
||||
volume/local/local_test.go | 5 +++++
|
||||
1 file changed, 5 insertions(+)
|
||||
|
||||
diff --git a/volume/local/local_test.go b/volume/local/local_test.go
|
||||
index 8045e87..12bc7d8 100644
|
||||
--- a/volume/local/local_test.go
|
||||
+++ b/volume/local/local_test.go
|
||||
@@ -8,6 +8,7 @@ import (
|
||||
"runtime"
|
||||
"strings"
|
||||
"testing"
|
||||
+ "github.com/docker/docker/testutil"
|
||||
|
||||
"github.com/docker/docker/pkg/idtools"
|
||||
"github.com/moby/sys/mountinfo"
|
||||
@@ -31,6 +32,7 @@ func TestGetAddress(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestRemove(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
skip.If(t, runtime.GOOS == "windows", "FIXME: investigate why this test fails on CI")
|
||||
rootDir, err := os.MkdirTemp("", "local-volume-test")
|
||||
if err != nil {
|
||||
@@ -74,6 +76,7 @@ func TestRemove(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestInitializeWithVolumes(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
rootDir, err := os.MkdirTemp("", "local-volume-test")
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
@@ -106,6 +109,7 @@ func TestInitializeWithVolumes(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestCreate(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
rootDir, err := os.MkdirTemp("", "local-volume-test")
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
@@ -277,6 +281,7 @@ func TestCreateWithOpts(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestRelaodNoOpts(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
rootDir, err := os.MkdirTemp("", "volume-test-reload-no-opts")
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
--
|
||||
2.25.0.24.gbc7a3d4
|
||||
|
@ -1,49 +0,0 @@
|
||||
From 56221d3508e4e82f4fc51c17836609eb031af670 Mon Sep 17 00:00:00 2001
|
||||
From: Jamie Anderson <jamieand@amazon.com>
|
||||
Date: Wed, 3 Mar 2021 18:19:29 +0000
|
||||
Subject: [PATCH] Skip pkg/authorization tests that create sockets
|
||||
|
||||
Signed-off-by: Jamie Anderson <jamieand@amazon.com>
|
||||
---
|
||||
pkg/authorization/authz_unix_test.go | 4 ++++
|
||||
1 file changed, 4 insertions(+)
|
||||
|
||||
diff --git a/pkg/authorization/authz_unix_test.go b/pkg/authorization/authz_unix_test.go
|
||||
index 9b48986..0ac5e92 100644
|
||||
--- a/pkg/authorization/authz_unix_test.go
|
||||
+++ b/pkg/authorization/authz_unix_test.go
|
||||
@@ -17,6 +17,7 @@ import (
|
||||
"reflect"
|
||||
"strings"
|
||||
"testing"
|
||||
+ "github.com/docker/docker/testutil"
|
||||
|
||||
"github.com/docker/docker/pkg/plugins"
|
||||
"github.com/docker/go-connections/tlsconfig"
|
||||
@@ -28,6 +29,7 @@ const (
|
||||
)
|
||||
|
||||
func TestAuthZRequestPluginError(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
server := authZPluginTestServer{t: t}
|
||||
server.start()
|
||||
defer server.stop()
|
||||
@@ -59,6 +61,7 @@ func TestAuthZRequestPluginError(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestAuthZRequestPlugin(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
server := authZPluginTestServer{t: t}
|
||||
server.start()
|
||||
defer server.stop()
|
||||
@@ -91,6 +94,7 @@ func TestAuthZRequestPlugin(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestAuthZResponsePlugin(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
server := authZPluginTestServer{t: t}
|
||||
server.start()
|
||||
defer server.stop()
|
||||
--
|
||||
2.25.0.24.gbc7a3d4
|
||||
|
@ -1,20 +0,0 @@
|
||||
Index: docker-ce-17.11.0-ce/pkg/idtools/idtools_unix_test.go
|
||||
===================================================================
|
||||
--- docker-ce-17.11.0-ce.orig/pkg/idtools/idtools_unix_test.go
|
||||
+++ docker-ce-17.11.0-ce/pkg/idtools/idtools_unix_test.go
|
||||
@@ -239,6 +239,7 @@ func delUser(t *testing.T, name string)
|
||||
}
|
||||
|
||||
func TestParseSubidFileWithNewlinesAndComments(t *testing.T) {
|
||||
+ RequiresRoot(t)
|
||||
tmpDir, err := os.MkdirTemp("", "parsesubid")
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
@@ -267,6 +268,7 @@ dockremap:231072:65536`
|
||||
}
|
||||
|
||||
func TestGetRootUIDGID(t *testing.T) {
|
||||
+ RequiresRoot(t)
|
||||
uidMap := []IDMap{
|
||||
{
|
||||
ContainerID: 0,
|
@ -1,32 +0,0 @@
|
||||
From 34f63b7d07c0a1c9a8986c896ebbdf6ae131629f Mon Sep 17 00:00:00 2001
|
||||
From: Jamie Anderson <jamieand@amazon.com>
|
||||
Date: Wed, 3 Mar 2021 17:45:43 +0000
|
||||
Subject: [PATCH] Skip pkg/sysinfo tests that require root
|
||||
|
||||
Signed-off-by: Jamie Anderson <jamieand@amazon.com>
|
||||
---
|
||||
pkg/sysinfo/sysinfo_linux_test.go | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/pkg/sysinfo/sysinfo_linux_test.go b/pkg/sysinfo/sysinfo_linux_test.go
|
||||
index aa557c9..ffb4b70 100644
|
||||
--- a/pkg/sysinfo/sysinfo_linux_test.go
|
||||
+++ b/pkg/sysinfo/sysinfo_linux_test.go
|
||||
@@ -6,12 +6,14 @@ import (
|
||||
"path"
|
||||
"path/filepath"
|
||||
"testing"
|
||||
+ "github.com/docker/docker/testutil"
|
||||
|
||||
"golang.org/x/sys/unix"
|
||||
"gotest.tools/v3/assert"
|
||||
)
|
||||
|
||||
func TestReadProcBool(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
tmpDir, err := os.MkdirTemp("", "test-sysinfo-proc")
|
||||
assert.NilError(t, err)
|
||||
defer os.RemoveAll(tmpDir)
|
||||
--
|
||||
2.25.0.24.gbc7a3d4
|
||||
|
@ -1,33 +0,0 @@
|
||||
From 6ff01f51e73537015d6ec9a182f6b740cea16e76 Mon Sep 17 00:00:00 2001
|
||||
From: Jamie Anderson <jamieand@amazon.com>
|
||||
Date: Thu, 4 Mar 2021 18:11:39 +0000
|
||||
Subject: [PATCH] Skip quota tests that try to manage block devices
|
||||
|
||||
Signed-off-by: Jamie Anderson <jamieand@amazon.com>
|
||||
---
|
||||
quota/projectquota_test.go | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/quota/projectquota_test.go b/quota/projectquota_test.go
|
||||
index 9bf5c29..4e1e9c2 100644
|
||||
--- a/quota/projectquota_test.go
|
||||
+++ b/quota/projectquota_test.go
|
||||
@@ -8,6 +8,7 @@ import (
|
||||
"os"
|
||||
"path/filepath"
|
||||
"testing"
|
||||
+ "github.com/docker/docker/testutil"
|
||||
|
||||
"gotest.tools/v3/assert"
|
||||
is "gotest.tools/v3/assert/cmp"
|
||||
@@ -17,6 +18,7 @@ import (
|
||||
const testQuotaSize = 10 * 1024 * 1024
|
||||
|
||||
func TestBlockDev(t *testing.T) {
|
||||
+ testutil.SkipIfBuildroot(t)
|
||||
if msg, ok := CanTestQuota(); !ok {
|
||||
t.Skip(msg)
|
||||
}
|
||||
--
|
||||
2.25.0.24.gbc7a3d4
|
||||
|
@ -1,41 +0,0 @@
|
||||
From de0a19b6da6b704d63e4c36586f120a6ee6b262a Mon Sep 17 00:00:00 2001
|
||||
From: Jamie Anderson <jamieand@amazon.com>
|
||||
Date: Wed, 10 Mar 2021 19:12:49 +0000
|
||||
Subject: [PATCH] Skip volume store tests that require root
|
||||
|
||||
Signed-off-by: Jamie Anderson <jamieand@amazon.com>
|
||||
---
|
||||
volume/service/store_test.go | 3 +++
|
||||
1 file changed, 3 insertions(+)
|
||||
|
||||
diff --git a/volume/service/store_test.go b/volume/service/store_test.go
|
||||
index 5442f45..ef044d0 100644
|
||||
--- a/volume/service/store_test.go
|
||||
+++ b/volume/service/store_test.go
|
||||
@@ -9,6 +9,7 @@ import (
|
||||
"os"
|
||||
"strings"
|
||||
"testing"
|
||||
+ "github.com/docker/docker/testutil"
|
||||
|
||||
"github.com/docker/docker/volume"
|
||||
volumedrivers "github.com/docker/docker/volume/drivers"
|
||||
@@ -288,6 +289,7 @@ func TestDefererencePluginOnCreateError(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestRefDerefRemove(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
t.Parallel()
|
||||
|
||||
driverName := "test-ref-deref-remove"
|
||||
@@ -309,6 +311,7 @@ func TestRefDerefRemove(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestGet(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
t.Parallel()
|
||||
|
||||
driverName := "test-get"
|
||||
--
|
||||
2.31.0.rc2
|
||||
|
@ -1,22 +0,0 @@
|
||||
diff --git a/pkg/archive/archive_unix_test.go b/pkg/archive/archive_unix_test.go
|
||||
index dc4e1fd..6fb8895 100644
|
||||
--- a/pkg/archive/archive_unix_test.go
|
||||
+++ b/pkg/archive/archive_unix_test.go
|
||||
@@ -241,7 +241,7 @@ func TestTarUntarWithXattr(t *testing.T) {
|
||||
err = os.WriteFile(filepath.Join(origin, "3"), []byte("will be ignored"), 0700)
|
||||
assert.NilError(t, err)
|
||||
// there is no known Go implementation of setcap/getcap with support for v3 file capability
|
||||
- out, err := exec.Command("setcap", "cap_block_suspend+ep", filepath.Join(origin, "2")).CombinedOutput()
|
||||
+ out, err := exec.Command("setcap", "cap_sys_nice+ep", filepath.Join(origin, "2")).CombinedOutput()
|
||||
assert.NilError(t, err, string(out))
|
||||
|
||||
for _, c := range []Compression{
|
||||
@@ -262,7 +262,7 @@ func TestTarUntarWithXattr(t *testing.T) {
|
||||
}
|
||||
out, err := exec.Command("getcap", filepath.Join(origin, "2")).CombinedOutput()
|
||||
assert.NilError(t, err, string(out))
|
||||
- assert.Check(t, is.Contains(string(out), "cap_block_suspend=ep"), "untar should have kept the 'security.capability' xattr")
|
||||
+ assert.Check(t, is.Contains(string(out), "cap_sys_nice+ep"), "untar should have kept the 'security.capability' xattr")
|
||||
}
|
||||
}
|
||||
|
@ -1,43 +0,0 @@
|
||||
From 414e5fb4ca7f14fae5ff57c4fb1fd64b77e9b733 Mon Sep 17 00:00:00 2001
|
||||
From: Jamie Anderson <jamieand@amazon.com>
|
||||
Date: Fri, 12 Mar 2021 17:10:08 +0000
|
||||
Subject: [PATCH] Support /etc/docker-runtimes.d
|
||||
|
||||
Reworked for docker 20.10.4
|
||||
Original patch message:
|
||||
From 77efbceb6f074900c72855af903b63685803bc59 Mon Sep 17 00:00:00 2001
|
||||
From: Jacob Vallejo <jakeev@amazon.com>
|
||||
Date: Mon, 23 Sep 2019 15:58:38 -0700
|
||||
Subject: [PATCH] Support /etc/docker-runtimes.d
|
||||
|
||||
Use additional configured runtimes by evaluating their configs and
|
||||
subsequently providing any necessary configuration flags to the docker
|
||||
daemon at startup.
|
||||
|
||||
Signed-off-by: Jamie Anderson <jamieand@amazon.com>
|
||||
---
|
||||
contrib/init/systemd/docker.service | 5 ++++-
|
||||
1 file changed, 4 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/contrib/init/systemd/docker.service b/contrib/init/systemd/docker.service
|
||||
index d76aee3..7e87245 100644
|
||||
--- a/contrib/init/systemd/docker.service
|
||||
+++ b/contrib/init/systemd/docker.service
|
||||
@@ -9,10 +9,13 @@ Requires=docker.socket
|
||||
Type=notify
|
||||
EnvironmentFile=-/etc/sysconfig/docker
|
||||
EnvironmentFile=-/etc/sysconfig/docker-storage
|
||||
+EnvironmentFile=-/run/docker/runtimes.env
|
||||
+ExecStartPre=/bin/mkdir -p /run/docker
|
||||
+ExecStartPre=/usr/libexec/docker/docker-setup-runtimes.sh
|
||||
# the default is not to use systemd for cgroups because the delegate issues still
|
||||
# exists and systemd currently does not support the cgroup feature set required
|
||||
# for containers run by docker
|
||||
-ExecStart=/usr/bin/dockerd -H fd:// --containerd=/run/containerd/containerd.sock $OPTIONS $DOCKER_STORAGE_OPTIONS
|
||||
+ExecStart=/usr/bin/dockerd -H fd:// --containerd=/run/containerd/containerd.sock $OPTIONS $DOCKER_STORAGE_OPTIONS $DOCKER_ADD_RUNTIMES
|
||||
ExecReload=/bin/kill -s HUP $MAINPID
|
||||
LimitNOFILE=1048576
|
||||
# Having non-zero Limit*s causes performance problems due to accounting overhead
|
||||
--
|
||||
2.31.0.rc2
|
||||
|
@ -1,40 +0,0 @@
|
||||
From 863e370fa7b6abffe839ba405b72f409116ad677 Mon Sep 17 00:00:00 2001
|
||||
From: Jamie Anderson <jamieand@amazon.com>
|
||||
Date: Wed, 10 Mar 2021 19:25:02 +0000
|
||||
Subject: [PATCH] Support the use of sysconfig envvars in unit
|
||||
|
||||
Reworked for 20.10.4
|
||||
Original patch message:
|
||||
From: Jacob Vallejo <jakeev@amazon.com>
|
||||
Date: Mon, 23 Sep 2019 15:55:53 -0700
|
||||
Subject: [PATCH] Support the use of sysconfig envvars in unit
|
||||
|
||||
Environment variables may be conventionally configured here and are
|
||||
wired up into the startup of docker if they are provided.
|
||||
|
||||
Signed-off-by: Jamie Anderson <jamieand@amazon.com>
|
||||
---
|
||||
contrib/init/systemd/docker.service | 4 +++-
|
||||
1 file changed, 3 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/contrib/init/systemd/docker.service b/contrib/init/systemd/docker.service
|
||||
index 5174631..a92685e 100644
|
||||
--- a/contrib/init/systemd/docker.service
|
||||
+++ b/contrib/init/systemd/docker.service
|
||||
@@ -7,10 +7,12 @@ Requires=docker.socket
|
||||
|
||||
[Service]
|
||||
Type=notify
|
||||
+EnvironmentFile=-/etc/sysconfig/docker
|
||||
+EnvironmentFile=-/etc/sysconfig/docker-storage
|
||||
# the default is not to use systemd for cgroups because the delegate issues still
|
||||
# exists and systemd currently does not support the cgroup feature set required
|
||||
# for containers run by docker
|
||||
-ExecStart=/usr/bin/dockerd -H fd://
|
||||
+ExecStart=/usr/bin/dockerd -H fd:// --containerd=/run/containerd/containerd.sock $OPTIONS $DOCKER_STORAGE_OPTIONS
|
||||
ExecReload=/bin/kill -s HUP $MAINPID
|
||||
LimitNOFILE=1048576
|
||||
# Having non-zero Limit*s causes performance problems due to accounting overhead
|
||||
--
|
||||
2.31.0.rc2
|
||||
|
@ -1,29 +0,0 @@
|
||||
Index: docker-20.10.4/contrib/init/sysvinit-redhat/docker
|
||||
===================================================================
|
||||
--- docker-20.10.4.orig/contrib/init/sysvinit-redhat/docker
|
||||
+++ docker-20.10.4/contrib/init/sysvinit-redhat/docker
|
||||
@@ -30,6 +30,15 @@ lockfile="/var/lock/subsys/$prog"
|
||||
logfile="/var/log/$prog"
|
||||
|
||||
[ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog
|
||||
+[ -e /etc/sysconfig/${prog}-storage ] && . /etc/sysconfig/${prog}-storage
|
||||
+
|
||||
+# Additional start options for the Docker daemon can
|
||||
+# be defined in the $OPTIONS variable in /etc/sysconfig/docker,
|
||||
+# which is also the variable name referenced by the systemd unit.
|
||||
+# If $OPTIONS is not defined, we set it to the value of $other_args,
|
||||
+# which is the variable name expected by the upstream sysvinit script.
|
||||
+OPTIONS="${OPTIONS:-${other_args}}"
|
||||
+
|
||||
|
||||
prestart() {
|
||||
service cgconfig status > /dev/null
|
||||
@@ -56,7 +65,7 @@ start() {
|
||||
prestart
|
||||
printf "Starting $prog:\t"
|
||||
echo "\n$(date)\n" >> $logfile
|
||||
- "$unshare" -m -- nohup $exec $other_args >> $logfile 2>&1 &
|
||||
+ "$unshare" -m -- nohup $exec ${OPTIONS} ${DOCKER_STORAGE_OPTIONS} >> $logfile 2>&1 &
|
||||
pid=$!
|
||||
touch $lockfile
|
||||
# wait up to 10 seconds for the pidfile to exist. see
|
@ -1,26 +0,0 @@
|
||||
Index: docker-20.10.4/contrib/init/sysvinit-redhat/docker
|
||||
===================================================================
|
||||
--- docker-20.10.4.orig/contrib/init/sysvinit-redhat/docker
|
||||
+++ docker-20.10.4/contrib/init/sysvinit-redhat/docker
|
||||
@@ -41,6 +41,9 @@ logfile="/var/log/$prog"
|
||||
# which is the variable name expected by the upstream sysvinit script.
|
||||
OPTIONS="${OPTIONS:-${other_args}}"
|
||||
|
||||
+# How many seconds to wait for the pidfile to appear after starting the daemon.
|
||||
+# The default value from upstream is 10.
|
||||
+DAEMON_PIDFILE_TIMEOUT="${DAEMON_PIDFILE_TIMEOUT:-10}"
|
||||
|
||||
prestart() {
|
||||
service cgconfig status > /dev/null
|
||||
@@ -70,10 +73,8 @@ start() {
|
||||
"$unshare" -m -- nohup $exec ${OPTIONS} ${DOCKER_STORAGE_OPTIONS} >> $logfile 2>&1 &
|
||||
pid=$!
|
||||
touch $lockfile
|
||||
- # wait up to 10 seconds for the pidfile to exist. see
|
||||
- # https://github.com/docker/docker/issues/5359
|
||||
tries=0
|
||||
- while [ ! -f $pidfile -a $tries -lt 10 ]; do
|
||||
+ while [ ! -f $pidfile -a $tries -lt ${DAEMON_PIDFILE_TIMEOUT} ]; do
|
||||
sleep 1
|
||||
tries=$((tries + 1))
|
||||
echo -n '.'
|
@ -1,13 +0,0 @@
|
||||
Index: docker-20.10.4/contrib/init/sysvinit-redhat/docker
|
||||
===================================================================
|
||||
--- docker-20.10.4.orig/contrib/init/sysvinit-redhat/docker
|
||||
+++ docker-20.10.4/contrib/init/sysvinit-redhat/docker
|
||||
@@ -32,6 +32,8 @@ logfile="/var/log/$prog"
|
||||
[ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog
|
||||
[ -e /etc/sysconfig/${prog}-storage ] && . /etc/sysconfig/${prog}-storage
|
||||
|
||||
+[ -n "${DAEMON_MAXFILES}" ] && ulimit -n "${DAEMON_MAXFILES}"
|
||||
+
|
||||
# Additional start options for the Docker daemon can
|
||||
# be defined in the $OPTIONS variable in /etc/sysconfig/docker,
|
||||
# which is also the variable name referenced by the systemd unit.
|
@ -1,13 +0,0 @@
|
||||
Index: docker-20.10.4/contrib/init/sysvinit-redhat/docker
|
||||
===================================================================
|
||||
--- docker-20.10.4.orig/contrib/init/sysvinit-redhat/docker
|
||||
+++ docker-20.10.4/contrib/init/sysvinit-redhat/docker
|
||||
@@ -4,7 +4,7 @@
|
||||
#
|
||||
# Daemon for docker.com
|
||||
#
|
||||
-# chkconfig: 2345 95 95
|
||||
+# chkconfig: 2345 95 05
|
||||
# description: Daemon for docker.com
|
||||
|
||||
### BEGIN INIT INFO
|
@ -1,13 +0,0 @@
|
||||
Index: docker-20.10.4/contrib/init/sysvinit-redhat/docker
|
||||
===================================================================
|
||||
--- docker-20.10.4.orig/contrib/init/sysvinit-redhat/docker
|
||||
+++ docker-20.10.4/contrib/init/sysvinit-redhat/docker
|
||||
@@ -56,7 +56,7 @@ start() {
|
||||
prestart
|
||||
printf "Starting $prog:\t"
|
||||
echo "\n$(date)\n" >> $logfile
|
||||
- "$unshare" -m -- $exec $other_args >> $logfile 2>&1 &
|
||||
+ "$unshare" -m -- nohup $exec $other_args >> $logfile 2>&1 &
|
||||
pid=$!
|
||||
touch $lockfile
|
||||
# wait up to 10 seconds for the pidfile to exist. see
|
@ -1,96 +0,0 @@
|
||||
From f8f7e0d380488665cb77d8213d816bfdeeb7a252 Mon Sep 17 00:00:00 2001
|
||||
From: Jamie Anderson <jamieand@amazon.com>
|
||||
Date: Wed, 18 Aug 2021 22:33:15 +0000
|
||||
Subject: [PATCH] Add test skip helpers to cli/testutil
|
||||
|
||||
Signed-off-by: Jamie Anderson <jamieand@amazon.com>
|
||||
---
|
||||
testutil/helpers.go | 14 ++++++++++++++
|
||||
testutil/helpers_unix.go | 34 ++++++++++++++++++++++++++++++++++
|
||||
testutil/helpers_windows.go | 12 ++++++++++++
|
||||
3 files changed, 60 insertions(+)
|
||||
create mode 100644 testutil/helpers.go
|
||||
create mode 100644 testutil/helpers_unix.go
|
||||
create mode 100644 testutil/helpers_windows.go
|
||||
|
||||
diff --git a/testutil/helpers.go b/testutil/helpers.go
|
||||
new file mode 100644
|
||||
index 0000000..0eeff25
|
||||
--- /dev/null
|
||||
+++ b/testutil/helpers.go
|
||||
@@ -0,0 +1,14 @@
|
||||
+package testutil // import "github.com/docker/cli/testutil"
|
||||
+
|
||||
+import (
|
||||
+ "flag"
|
||||
+)
|
||||
+
|
||||
+// This variable and the init() function copied from
|
||||
+// https://github.com/containerd/containerd/blob/master/pkg/testutil/helpers.go
|
||||
+// Original Copyright The Containerd Authors. Licensed under the Apache License, Version 2.0.
|
||||
+var rootEnabled bool
|
||||
+
|
||||
+func init() {
|
||||
+ flag.BoolVar(&rootEnabled, "test.root", false, "enable tests that require root")
|
||||
+}
|
||||
diff --git a/testutil/helpers_unix.go b/testutil/helpers_unix.go
|
||||
new file mode 100644
|
||||
index 0000000..c846775
|
||||
--- /dev/null
|
||||
+++ b/testutil/helpers_unix.go
|
||||
@@ -0,0 +1,34 @@
|
||||
+// +build !windows
|
||||
+
|
||||
+package testutil
|
||||
+
|
||||
+import (
|
||||
+ "os"
|
||||
+ "testing"
|
||||
+
|
||||
+ "gotest.tools/v3/assert"
|
||||
+)
|
||||
+
|
||||
+// This function was copied from
|
||||
+// https://github.com/containerd/containerd/blob/master/pkg/testutil/helpers_unix.go
|
||||
+// Original Copyright The Containerd Authors. Licensed under the Apache License, Version 2.0.
|
||||
+// RequiresRoot skips tests that require root, unless the test.root flag has
|
||||
+// been set
|
||||
+func RequiresRoot(t testing.TB) {
|
||||
+ if !rootEnabled {
|
||||
+ t.Skip("skipping test that requires root")
|
||||
+ }
|
||||
+ assert.Equal(t, 0, os.Getuid(), "This test must be run as root.")
|
||||
+}
|
||||
+
|
||||
+// This function is adapted from a previous patch applied by Amazon
|
||||
+// The existence of /.initialized or /builddir is a marker that we're in a build chroot
|
||||
+// Tests that perform filesystem operations, generate non-localhost network traffic,
|
||||
+// and possibly other things, are likely to not work correctly
|
||||
+func SkipIfBuildroot(t testing.TB) {
|
||||
+ if _, err := os.Stat("/.initialized"); err == nil {
|
||||
+ t.Skip("not appropriate for a buildroot environment")
|
||||
+ } else if _, err := os.Stat("/builddir"); err == nil {
|
||||
+ t.Skip("not appropriate for a buildroot environment")
|
||||
+ }
|
||||
+}
|
||||
diff --git a/testutil/helpers_windows.go b/testutil/helpers_windows.go
|
||||
new file mode 100644
|
||||
index 0000000..aefeca0
|
||||
--- /dev/null
|
||||
+++ b/testutil/helpers_windows.go
|
||||
@@ -0,0 +1,12 @@
|
||||
+// +build windows
|
||||
+
|
||||
+package testutil
|
||||
+
|
||||
+import "testing"
|
||||
+
|
||||
+func RequiresRoot(t testing.TB) {
|
||||
+}
|
||||
+
|
||||
+func SkipIfBuildroot(t testing.TB) {
|
||||
+}
|
||||
+
|
||||
--
|
||||
2.31.0.rc2
|
||||
|
@ -1,99 +0,0 @@
|
||||
From 021e33a5b2c3384243e3ae76444bb90006214f5a Mon Sep 17 00:00:00 2001
|
||||
From: Jamie Anderson <jamieand@amazon.com>
|
||||
Date: Wed, 18 Aug 2021 22:17:52 +0000
|
||||
Subject: [PATCH] Add test skip helpers to testutil
|
||||
|
||||
Signed-off-by: Jamie Anderson <jamieand@amazon.com>
|
||||
---
|
||||
testutil/helpers.go | 10 ++++++++++
|
||||
testutil/helpers_unix.go | 34 ++++++++++++++++++++++++++++++++++
|
||||
testutil/helpers_windows.go | 12 ++++++++++++
|
||||
3 files changed, 56 insertions(+)
|
||||
create mode 100644 testutil/helpers_unix.go
|
||||
create mode 100644 testutil/helpers_windows.go
|
||||
|
||||
diff --git a/testutil/helpers.go b/testutil/helpers.go
|
||||
index e522b5a..6de9de5 100644
|
||||
--- a/testutil/helpers.go
|
||||
+++ b/testutil/helpers.go
|
||||
@@ -1,9 +1,19 @@
|
||||
package testutil // import "github.com/docker/docker/testutil"
|
||||
|
||||
import (
|
||||
+ "flag"
|
||||
"io"
|
||||
)
|
||||
|
||||
+// This variable and the init() function copied from
|
||||
+// https://github.com/containerd/containerd/blob/master/pkg/testutil/helpers.go
|
||||
+// Original Copyright The Containerd Authors. Licensed under the Apache License, Version 2.0.
|
||||
+var rootEnabled bool
|
||||
+
|
||||
+func init() {
|
||||
+ flag.BoolVar(&rootEnabled, "test.root", false, "enable tests that require root")
|
||||
+}
|
||||
+
|
||||
// DevZero acts like /dev/zero but in an OS-independent fashion.
|
||||
var DevZero io.Reader = devZero{}
|
||||
|
||||
diff --git a/testutil/helpers_unix.go b/testutil/helpers_unix.go
|
||||
new file mode 100644
|
||||
index 0000000..c846775
|
||||
--- /dev/null
|
||||
+++ b/testutil/helpers_unix.go
|
||||
@@ -0,0 +1,34 @@
|
||||
+// +build !windows
|
||||
+
|
||||
+package testutil
|
||||
+
|
||||
+import (
|
||||
+ "os"
|
||||
+ "testing"
|
||||
+
|
||||
+ "gotest.tools/v3/assert"
|
||||
+)
|
||||
+
|
||||
+// This function was copied from
|
||||
+// https://github.com/containerd/containerd/blob/master/pkg/testutil/helpers_unix.go
|
||||
+// Original Copyright The Containerd Authors. Licensed under the Apache License, Version 2.0.
|
||||
+// RequiresRoot skips tests that require root, unless the test.root flag has
|
||||
+// been set
|
||||
+func RequiresRoot(t testing.TB) {
|
||||
+ if !rootEnabled {
|
||||
+ t.Skip("skipping test that requires root")
|
||||
+ }
|
||||
+ assert.Equal(t, 0, os.Getuid(), "This test must be run as root.")
|
||||
+}
|
||||
+
|
||||
+// This function is adapted from a previous patch applied by Amazon
|
||||
+// The existence of /.initialized or /builddir is a marker that we're in a build chroot
|
||||
+// Tests that perform filesystem operations, generate non-localhost network traffic,
|
||||
+// and possibly other things, are likely to not work correctly
|
||||
+func SkipIfBuildroot(t testing.TB) {
|
||||
+ if _, err := os.Stat("/.initialized"); err == nil {
|
||||
+ t.Skip("not appropriate for a buildroot environment")
|
||||
+ } else if _, err := os.Stat("/builddir"); err == nil {
|
||||
+ t.Skip("not appropriate for a buildroot environment")
|
||||
+ }
|
||||
+}
|
||||
diff --git a/testutil/helpers_windows.go b/testutil/helpers_windows.go
|
||||
new file mode 100644
|
||||
index 0000000..aefeca0
|
||||
--- /dev/null
|
||||
+++ b/testutil/helpers_windows.go
|
||||
@@ -0,0 +1,12 @@
|
||||
+// +build windows
|
||||
+
|
||||
+package testutil
|
||||
+
|
||||
+import "testing"
|
||||
+
|
||||
+func RequiresRoot(t testing.TB) {
|
||||
+}
|
||||
+
|
||||
+func SkipIfBuildroot(t testing.TB) {
|
||||
+}
|
||||
+
|
||||
--
|
||||
2.31.0.rc2
|
||||
|
@ -1,41 +0,0 @@
|
||||
From fc8490a29aa87f81ad4a58c5b759317acb77876e Mon Sep 17 00:00:00 2001
|
||||
From: Jamie Anderson <jamieand@amazon.com>
|
||||
Date: Mon, 16 Aug 2021 17:21:38 +0000
|
||||
Subject: [PATCH] Skip overlay/tar/untar test
|
||||
|
||||
Signed-off-by: Jamie Anderson <jamieand@amazon.com>
|
||||
---
|
||||
pkg/archive/archive_linux_test.go | 3 +++
|
||||
1 file changed, 3 insertions(+)
|
||||
|
||||
diff --git a/pkg/archive/archive_linux_test.go b/pkg/archive/archive_linux_test.go
|
||||
index 800fda6..08a196b 100644
|
||||
--- a/pkg/archive/archive_linux_test.go
|
||||
+++ b/pkg/archive/archive_linux_test.go
|
||||
@@ -9,6 +9,7 @@ import (
|
||||
|
||||
"github.com/containerd/containerd/sys"
|
||||
"github.com/docker/docker/pkg/system"
|
||||
+ "github.com/docker/docker/testutil"
|
||||
"golang.org/x/sys/unix"
|
||||
"gotest.tools/v3/assert"
|
||||
"gotest.tools/v3/skip"
|
||||
@@ -87,6 +88,7 @@ func checkFileMode(t *testing.T, path string, perm os.FileMode) {
|
||||
}
|
||||
|
||||
func TestOverlayTarUntar(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
oldmask, err := system.Umask(0)
|
||||
assert.NilError(t, err)
|
||||
defer system.Umask(oldmask)
|
||||
@@ -126,6 +128,7 @@ func TestOverlayTarUntar(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestOverlayTarAUFSUntar(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
oldmask, err := system.Umask(0)
|
||||
assert.NilError(t, err)
|
||||
defer system.Umask(oldmask)
|
||||
--
|
||||
2.31.0.rc2
|
||||
|
@ -1,33 +0,0 @@
|
||||
From d099d78e4ac135ff2fcf24e08ad7573067b37a5a Mon Sep 17 00:00:00 2001
|
||||
From: Jamie Anderson <jamieand@amazon.com>
|
||||
Date: Mon, 16 Aug 2021 17:31:32 +0000
|
||||
Subject: [PATCH] Skip pkg/archive tests that require root
|
||||
|
||||
Signed-off-by: Jamie Anderson <jamieand@amazon.com>
|
||||
---
|
||||
pkg/archive/changes_test.go | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/pkg/archive/changes_test.go b/pkg/archive/changes_test.go
|
||||
index 0a2689d..490af6d 100644
|
||||
--- a/pkg/archive/changes_test.go
|
||||
+++ b/pkg/archive/changes_test.go
|
||||
@@ -13,6 +13,7 @@ import (
|
||||
"time"
|
||||
|
||||
"github.com/docker/docker/pkg/system"
|
||||
+ "github.com/docker/docker/testutil"
|
||||
"gotest.tools/v3/assert"
|
||||
"gotest.tools/v3/skip"
|
||||
)
|
||||
@@ -187,6 +188,7 @@ func TestChangesWithChanges(t *testing.T) {
|
||||
|
||||
// See https://github.com/docker/docker/pull/13590
|
||||
func TestChangesWithChangesGH13590(t *testing.T) {
|
||||
+ testutil.RequiresRoot(t)
|
||||
// TODO Windows. Needs further investigation to identify the failure
|
||||
if runtime.GOOS == "windows" {
|
||||
t.Skip("needs more investigation")
|
||||
--
|
||||
2.31.0.rc2
|
||||
|
@ -1,8 +0,0 @@
|
||||
#!/bin/sh
|
||||
{
|
||||
echo -n "DOCKER_ADD_RUNTIMES=\""
|
||||
for file in /etc/docker-runtimes.d/*; do
|
||||
[ -f "$file" ] && [ -x "$file" ] && echo -n "--add-runtime $(basename "$file")=$file "
|
||||
done
|
||||
echo "\""
|
||||
} > /run/docker/runtimes.env
|
@ -1,14 +0,0 @@
|
||||
# This file may be automatically generated by an installation program.
|
||||
|
||||
# By default, Docker uses a loopback-mounted sparse file in
|
||||
# /var/lib/docker. The loopback makes it slower, and there are some
|
||||
# restrictive defaults, such as 100GB max storage.
|
||||
|
||||
# If your installation did not set a custom storage for Docker, you
|
||||
# may do it below.
|
||||
|
||||
# Example: Use a custom pair of raw logical volumes (one for metadata,
|
||||
# one for data).
|
||||
# DOCKER_STORAGE_OPTIONS="--storage-opt dm.metadatadev=/dev/myvg/my-docker-metadata --storage-opt dm.datadev=/dev/myvg/my-docker-data"
|
||||
|
||||
DOCKER_STORAGE_OPTIONS=
|
2
base/docker/docker-systemd-sysusers.conf
Normal file
2
base/docker/docker-systemd-sysusers.conf
Normal file
@ -0,0 +1,2 @@
|
||||
#Type Name ID
|
||||
g docker -
|
38
base/docker/docker.service
Normal file
38
base/docker/docker.service
Normal file
@ -0,0 +1,38 @@
|
||||
[Unit]
|
||||
Description=Docker Application Container Engine
|
||||
Documentation=https://docs.docker.com
|
||||
After=docker.socket network-online.target firewalld.service
|
||||
Requires=docker.socket
|
||||
Wants=network-online.target
|
||||
|
||||
[Service]
|
||||
Type=notify
|
||||
EnvironmentFile=-/etc/sysconfig/docker
|
||||
# the default is not to use systemd for cgroups because the delegate issues still
|
||||
# exists and systemd currently does not support the cgroup feature set required
|
||||
# for containers run by docker
|
||||
ExecStart=/usr/bin/dockerd \
|
||||
--host=fd:// \
|
||||
--exec-opt native.cgroupdriver=systemd \
|
||||
$OPTIONS
|
||||
ExecReload=/bin/kill -s HUP $MAINPID
|
||||
# Having non-zero Limit*s causes performance problems due to accounting overhead
|
||||
# in the kernel. We recommend using cgroups to do container-local accounting.
|
||||
LimitNOFILE=infinity
|
||||
LimitNPROC=infinity
|
||||
LimitCORE=infinity
|
||||
# Uncomment TasksMax if your systemd version supports it.
|
||||
# Only systemd 226 and above support this version.
|
||||
#TasksMax=infinity
|
||||
TimeoutStartSec=0
|
||||
# set delegate yes so that systemd does not reset the cgroups of docker containers
|
||||
#Delegate=yes
|
||||
# kill only the docker process, not all processes in the cgroup
|
||||
KillMode=process
|
||||
# restart the docker process if it exits prematurely
|
||||
Restart=on-failure
|
||||
StartLimitBurst=3
|
||||
StartLimitInterval=60s
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
File diff suppressed because it is too large
Load Diff
@ -1,13 +1,10 @@
|
||||
# The max number of open files for the daemon itself, and all
|
||||
# running containers. The default value of 1048576 mirrors the value
|
||||
# used by the systemd service unit.
|
||||
DAEMON_MAXFILES=1048576
|
||||
# /etc/sysconfig/docker
|
||||
|
||||
# Additional startup options for the Docker daemon, for example:
|
||||
# OPTIONS="--ip-forward=true --iptables=true"
|
||||
# By default we limit the number of open files per container
|
||||
OPTIONS="--default-ulimit nofile=32768:65536"
|
||||
|
||||
# How many seconds the sysvinit script waits for the pidfile to appear
|
||||
# when starting the daemon.
|
||||
DAEMON_PIDFILE_TIMEOUT=10
|
||||
# Modify these options if you want to change the way the docker daemon runs
|
||||
OPTIONS="--selinux-enabled \
|
||||
--log-driver=journald \
|
||||
--live-restore \
|
||||
--default-ulimit nofile=1024:1024 \
|
||||
--init-path /usr/libexec/docker/docker-init \
|
||||
--userland-proxy-path /usr/libexec/docker/docker-proxy \
|
||||
"
|
||||
|
12
base/docker/generate-docs.sh
Normal file
12
base/docker/generate-docs.sh
Normal file
@ -0,0 +1,12 @@
|
||||
cd man
|
||||
for FILE in *.md; do
|
||||
base="$(basename "$FILE")"
|
||||
name="${base%.md}"
|
||||
num="${name##*.}"
|
||||
if [ -z "$num" ] || [ "$name" = "$num" ]; then
|
||||
# skip files that aren't of the format xxxx.N.md (like README.md)
|
||||
continue
|
||||
fi
|
||||
mkdir -p "./man${num}"
|
||||
(set -x ;go-md2man -in "$FILE" -out "./man${num}/${name}")
|
||||
done
|
@ -1,13 +0,0 @@
|
||||
Index: docker-20.10.4/contrib/init/sysvinit-redhat/docker
|
||||
===================================================================
|
||||
--- docker-20.10.4.orig/contrib/init/sysvinit-redhat/docker
|
||||
+++ docker-20.10.4/contrib/init/sysvinit-redhat/docker
|
||||
@@ -70,7 +70,7 @@ start() {
|
||||
prestart
|
||||
printf "Starting $prog:\t"
|
||||
echo "\n$(date)\n" >> $logfile
|
||||
- "$unshare" -m -- nohup $exec ${OPTIONS} ${DOCKER_STORAGE_OPTIONS} >> $logfile 2>&1 &
|
||||
+ nohup $exec ${OPTIONS} ${DOCKER_STORAGE_OPTIONS} >> $logfile 2>&1 &
|
||||
pid=$!
|
||||
touch $lockfile
|
||||
tries=0
|
108
base/docker/provides.spec.inc
Normal file
108
base/docker/provides.spec.inc
Normal file
@ -0,0 +1,108 @@
|
||||
# Bundled dependencies
|
||||
Provides: bundled(tini-static)
|
||||
Provides: bundled(golang(github.com/docker/docker))
|
||||
Provides: bundled(golang(github.com/docker/cli))
|
||||
# grep -v -e '^$' -e '^#' cli-24.0.5/vendor/github.com/docker/distribution/vendor.conf | sort | awk '{print "Provides: bundled(golang("$1")) = "$2}'
|
||||
Provides: bundled(golang(github.com/aws/aws-sdk-go)) = f831d5a0822a1ad72420ab18c6269bca1ddaf490
|
||||
Provides: bundled(golang(github.com/Azure/azure-sdk-for-go)) = 4650843026a7fdec254a8d9cf893693a254edd0b
|
||||
Provides: bundled(golang(github.com/Azure/go-autorest)) = eaa7994b2278094c904d31993d26f56324db3052
|
||||
Provides: bundled(golang(github.com/beorn7/perks)) = 4c0e84591b9aa9e6dcfdf3e020114cd81f89d5f9
|
||||
Provides: bundled(golang(github.com/bshuster-repo/logrus-logstash-hook)) = d2c0ecc1836d91814e15e23bb5dc309c3ef51f4a
|
||||
Provides: bundled(golang(github.com/bugsnag/bugsnag-go)) = b1d153021fcd90ca3f080db36bec96dc690fb274
|
||||
Provides: bundled(golang(github.com/bugsnag/osext)) = 0dd3f918b21bec95ace9dc86c7e70266cfc5c702
|
||||
Provides: bundled(golang(github.com/bugsnag/panicwrap)) = e2c28503fcd0675329da73bf48b33404db873782
|
||||
Provides: bundled(golang(github.com/denverdino/aliyungo)) = afedced274aa9a7fcdd47ac97018f0f8db4e5de2
|
||||
Provides: bundled(golang(github.com/dgrijalva/jwt-go)) = 4bbdd8ac624fc7a9ef7aec841c43d99b5fe65a29
|
||||
Provides: bundled(golang(github.com/docker/go-metrics)) = 399ea8c73916000c64c2c76e8da00ca82f8387ab
|
||||
Provides: bundled(golang(github.com/docker/libtrust)) = fa567046d9b14f6aa788882a950d69651d230b21
|
||||
Provides: bundled(golang(github.com/garyburd/redigo)) = 535138d7bcd717d6531c701ef5933d98b1866257
|
||||
Provides: bundled(golang(github.com/go-ini/ini)) = 2ba15ac2dc9cdf88c110ec2dc0ced7fa45f5678c
|
||||
Provides: bundled(golang(github.com/golang/protobuf)) = 8d92cf5fc15a4382f8964b08e1f42a75c0591aa3
|
||||
Provides: bundled(golang(github.com/gorilla/handlers)) = 60c7bfde3e33c201519a200a4507a158cc03a17b
|
||||
Provides: bundled(golang(github.com/gorilla/mux)) = 599cba5e7b6137d46ddf58fb1765f5d928e69604
|
||||
Provides: bundled(golang(github.com/inconshreveable/mousetrap)) = 76626ae9c91c4f2a10f34cad8ce83ea42c93bb75
|
||||
Provides: bundled(golang(github.com/jmespath/go-jmespath)) = bd40a432e4c76585ef6b72d3fd96fb9b6dc7b68d
|
||||
Provides: bundled(golang(github.com/marstr/guid)) = 8bd9a64bf37eb297b492a4101fb28e80ac0b290f
|
||||
Provides: bundled(golang(github.com/matttproud/golang_protobuf_extensions)) = c12348ce28de40eed0136aa2b644d0ee0650e56c
|
||||
Provides: bundled(golang(github.com/miekg/dns)) = 271c58e0c14f552178ea321a545ff9af38930f39
|
||||
Provides: bundled(golang(github.com/mitchellh/mapstructure)) = 482a9fd5fa83e8c4e7817413b80f3eb8feec03ef
|
||||
Provides: bundled(golang(github.com/ncw/swift)) = a0320860b16212c2b59b4912bb6508cda1d7cee6
|
||||
Provides: bundled(golang(github.com/opencontainers/go-digest)) = a6d0ee40d4207ea02364bd3b9e8e77b9159ba1eb
|
||||
Provides: bundled(golang(github.com/opencontainers/image-spec)) = 67d2d5658fe0476ab9bf414cec164077ebff3920
|
||||
Provides: bundled(golang(github.com/prometheus/client_golang)) = c332b6f63c0658a65eca15c0e5247ded801cf564
|
||||
Provides: bundled(golang(github.com/prometheus/client_model)) = 99fa1f4be8e564e8a6b613da7fa6f46c9edafc6c
|
||||
Provides: bundled(golang(github.com/prometheus/common)) = 89604d197083d4781071d3c65855d24ecfb0a563
|
||||
Provides: bundled(golang(github.com/prometheus/procfs)) = cb4147076ac75738c9a7d279075a253c0cc5acbd
|
||||
Provides: bundled(golang(github.com/satori/go.uuid)) = f58768cc1a7a7e77a3bd49e98cdd21419399b6a3
|
||||
Provides: bundled(golang(github.com/Shopify/logrus-bugsnag)) = 577dee27f20dd8f1a529f82210094af593be12bd
|
||||
Provides: bundled(golang(github.com/sirupsen/logrus)) = 3d4380f53a34dcdc95f0c1db702615992b38d9a4
|
||||
Provides: bundled(golang(github.com/spf13/cobra)) = 312092086bed4968099259622145a0c9ae280064
|
||||
Provides: bundled(golang(github.com/spf13/pflag)) = 5644820622454e71517561946e3d94b9f9db6842
|
||||
Provides: bundled(golang(github.com/xenolf/lego)) = a9d8cec0e6563575e5868a005359ac97911b5985
|
||||
Provides: bundled(golang(github.com/yvasiyarov/go-metrics)) = 57bccd1ccd43f94bb17fdd8bf3007059b802f85e
|
||||
Provides: bundled(golang(github.com/yvasiyarov/gorelic)) = a9bba5b9ab508a086f9a12b8c51fab68478e2128
|
||||
Provides: bundled(golang(github.com/yvasiyarov/newrelic_platform_go)) = b21fdbd4370f3717f3bbd2bf41c223bc273068e6
|
||||
Provides: bundled(golang(golang.org/x/crypto)) = c10c31b5e94b6f7a0283272dc2bb27163dcea24b
|
||||
Provides: bundled(golang(golang.org/x/net)) = 4876518f9e71663000c348837735820161a42df7
|
||||
Provides: bundled(golang(golang.org/x/oauth2)) = 045497edb6234273d67dbc25da3f2ddbc4c4cacf
|
||||
Provides: bundled(golang(golang.org/x/time)) = a4bde12657593d5e90d0533a3e4fd95e635124cb
|
||||
Provides: bundled(golang(google.golang.org/api)) = 9bf6e6e569ff057f75d9604a46c52928f17d2b54
|
||||
Provides: bundled(golang(google.golang.org/appengine)) = 12d5545dc1cfa6047a286d5e853841b6471f4c19
|
||||
Provides: bundled(golang(google.golang.org/cloud)) = 975617b05ea8a58727e6c1a06b6161ff4185a9f2
|
||||
Provides: bundled(golang(google.golang.org/grpc)) = d3ddb4469d5a1b949fc7a7da7c1d6a0d1b6de994
|
||||
Provides: bundled(golang(gopkg.in/check.v1)) = 64131543e7896d5bcc6bd5a76287eb75ea96c673
|
||||
Provides: bundled(golang(gopkg.in/square/go-jose.v1)) = 40d457b439244b546f023d056628e5184136899b
|
||||
Provides: bundled(golang(gopkg.in/yaml.v2)) = v2.2.1
|
||||
Provides: bundled(golang(rsc.io/letsencrypt)) = e770c10b0f1a64775ae91d240407ce00d1a5bdeb
|
||||
# grep -v -e '^$' -e '^#' moby-24.0.5/vendor/github.com/docker/distribution/vendor.conf | sort | awk '{print "Provides: bundled(golang("$1")) = "$2}'
|
||||
Provides: bundled(golang(github.com/aws/aws-sdk-go)) = f831d5a0822a1ad72420ab18c6269bca1ddaf490
|
||||
Provides: bundled(golang(github.com/Azure/azure-sdk-for-go)) = 4650843026a7fdec254a8d9cf893693a254edd0b
|
||||
Provides: bundled(golang(github.com/Azure/go-autorest)) = eaa7994b2278094c904d31993d26f56324db3052
|
||||
Provides: bundled(golang(github.com/beorn7/perks)) = 4c0e84591b9aa9e6dcfdf3e020114cd81f89d5f9
|
||||
Provides: bundled(golang(github.com/bshuster-repo/logrus-logstash-hook)) = d2c0ecc1836d91814e15e23bb5dc309c3ef51f4a
|
||||
Provides: bundled(golang(github.com/bugsnag/bugsnag-go)) = b1d153021fcd90ca3f080db36bec96dc690fb274
|
||||
Provides: bundled(golang(github.com/bugsnag/osext)) = 0dd3f918b21bec95ace9dc86c7e70266cfc5c702
|
||||
Provides: bundled(golang(github.com/bugsnag/panicwrap)) = e2c28503fcd0675329da73bf48b33404db873782
|
||||
Provides: bundled(golang(github.com/denverdino/aliyungo)) = afedced274aa9a7fcdd47ac97018f0f8db4e5de2
|
||||
Provides: bundled(golang(github.com/dgrijalva/jwt-go)) = 4bbdd8ac624fc7a9ef7aec841c43d99b5fe65a29
|
||||
Provides: bundled(golang(github.com/docker/go-metrics)) = 399ea8c73916000c64c2c76e8da00ca82f8387ab
|
||||
Provides: bundled(golang(github.com/docker/libtrust)) = fa567046d9b14f6aa788882a950d69651d230b21
|
||||
Provides: bundled(golang(github.com/garyburd/redigo)) = 535138d7bcd717d6531c701ef5933d98b1866257
|
||||
Provides: bundled(golang(github.com/go-ini/ini)) = 2ba15ac2dc9cdf88c110ec2dc0ced7fa45f5678c
|
||||
Provides: bundled(golang(github.com/golang/protobuf)) = 8d92cf5fc15a4382f8964b08e1f42a75c0591aa3
|
||||
Provides: bundled(golang(github.com/gorilla/handlers)) = 60c7bfde3e33c201519a200a4507a158cc03a17b
|
||||
Provides: bundled(golang(github.com/gorilla/mux)) = 599cba5e7b6137d46ddf58fb1765f5d928e69604
|
||||
Provides: bundled(golang(github.com/inconshreveable/mousetrap)) = 76626ae9c91c4f2a10f34cad8ce83ea42c93bb75
|
||||
Provides: bundled(golang(github.com/jmespath/go-jmespath)) = bd40a432e4c76585ef6b72d3fd96fb9b6dc7b68d
|
||||
Provides: bundled(golang(github.com/marstr/guid)) = 8bd9a64bf37eb297b492a4101fb28e80ac0b290f
|
||||
Provides: bundled(golang(github.com/matttproud/golang_protobuf_extensions)) = c12348ce28de40eed0136aa2b644d0ee0650e56c
|
||||
Provides: bundled(golang(github.com/miekg/dns)) = 271c58e0c14f552178ea321a545ff9af38930f39
|
||||
Provides: bundled(golang(github.com/mitchellh/mapstructure)) = 482a9fd5fa83e8c4e7817413b80f3eb8feec03ef
|
||||
Provides: bundled(golang(github.com/ncw/swift)) = a0320860b16212c2b59b4912bb6508cda1d7cee6
|
||||
Provides: bundled(golang(github.com/opencontainers/go-digest)) = a6d0ee40d4207ea02364bd3b9e8e77b9159ba1eb
|
||||
Provides: bundled(golang(github.com/opencontainers/image-spec)) = 67d2d5658fe0476ab9bf414cec164077ebff3920
|
||||
Provides: bundled(golang(github.com/prometheus/client_golang)) = c332b6f63c0658a65eca15c0e5247ded801cf564
|
||||
Provides: bundled(golang(github.com/prometheus/client_model)) = 99fa1f4be8e564e8a6b613da7fa6f46c9edafc6c
|
||||
Provides: bundled(golang(github.com/prometheus/common)) = 89604d197083d4781071d3c65855d24ecfb0a563
|
||||
Provides: bundled(golang(github.com/prometheus/procfs)) = cb4147076ac75738c9a7d279075a253c0cc5acbd
|
||||
Provides: bundled(golang(github.com/satori/go.uuid)) = f58768cc1a7a7e77a3bd49e98cdd21419399b6a3
|
||||
Provides: bundled(golang(github.com/Shopify/logrus-bugsnag)) = 577dee27f20dd8f1a529f82210094af593be12bd
|
||||
Provides: bundled(golang(github.com/sirupsen/logrus)) = 3d4380f53a34dcdc95f0c1db702615992b38d9a4
|
||||
Provides: bundled(golang(github.com/spf13/cobra)) = 312092086bed4968099259622145a0c9ae280064
|
||||
Provides: bundled(golang(github.com/spf13/pflag)) = 5644820622454e71517561946e3d94b9f9db6842
|
||||
Provides: bundled(golang(github.com/xenolf/lego)) = a9d8cec0e6563575e5868a005359ac97911b5985
|
||||
Provides: bundled(golang(github.com/yvasiyarov/go-metrics)) = 57bccd1ccd43f94bb17fdd8bf3007059b802f85e
|
||||
Provides: bundled(golang(github.com/yvasiyarov/gorelic)) = a9bba5b9ab508a086f9a12b8c51fab68478e2128
|
||||
Provides: bundled(golang(github.com/yvasiyarov/newrelic_platform_go)) = b21fdbd4370f3717f3bbd2bf41c223bc273068e6
|
||||
Provides: bundled(golang(golang.org/x/crypto)) = c10c31b5e94b6f7a0283272dc2bb27163dcea24b
|
||||
Provides: bundled(golang(golang.org/x/net)) = 4876518f9e71663000c348837735820161a42df7
|
||||
Provides: bundled(golang(golang.org/x/oauth2)) = 045497edb6234273d67dbc25da3f2ddbc4c4cacf
|
||||
Provides: bundled(golang(golang.org/x/time)) = a4bde12657593d5e90d0533a3e4fd95e635124cb
|
||||
Provides: bundled(golang(google.golang.org/api)) = 9bf6e6e569ff057f75d9604a46c52928f17d2b54
|
||||
Provides: bundled(golang(google.golang.org/appengine)) = 12d5545dc1cfa6047a286d5e853841b6471f4c19
|
||||
Provides: bundled(golang(google.golang.org/cloud)) = 975617b05ea8a58727e6c1a06b6161ff4185a9f2
|
||||
Provides: bundled(golang(google.golang.org/grpc)) = d3ddb4469d5a1b949fc7a7da7c1d6a0d1b6de994
|
||||
Provides: bundled(golang(gopkg.in/check.v1)) = 64131543e7896d5bcc6bd5a76287eb75ea96c673
|
||||
Provides: bundled(golang(gopkg.in/square/go-jose.v1)) = 40d457b439244b546f023d056628e5184136899b
|
||||
Provides: bundled(golang(gopkg.in/yaml.v2)) = v2.2.1
|
||||
Provides: bundled(golang(rsc.io/letsencrypt)) = e770c10b0f1a64775ae91d240407ce00d1a5bdeb
|
@ -1,19 +0,0 @@
|
||||
Index: docker-ce-17.11.0-ce/components/engine/runc-69663f0bd4b60df09991c08812a60108003fa340/Makefile
|
||||
===================================================================
|
||||
--- docker-ce-17.11.0-ce.orig/components/engine/runc-69663f0bd4b60df09991c08812a60108003fa340/Makefile
|
||||
+++ docker-ce-17.11.0-ce/components/engine/runc-69663f0bd4b60df09991c08812a60108003fa340/Makefile
|
||||
@@ -12,8 +12,12 @@ GIT_BRANCH_CLEAN := $(shell echo $(GIT_B
|
||||
RUNC_IMAGE := runc_dev$(if $(GIT_BRANCH_CLEAN),:$(GIT_BRANCH_CLEAN))
|
||||
PROJECT := github.com/opencontainers/runc
|
||||
BUILDTAGS := seccomp
|
||||
-COMMIT_NO := $(shell git rev-parse HEAD 2> /dev/null || true)
|
||||
-COMMIT := $(if $(shell git status --porcelain --untracked-files=no),"${COMMIT_NO}-dirty","${COMMIT_NO}")
|
||||
+ifeq ($(GIT_COMMIT_OVERRIDE),)
|
||||
+ COMMIT_NO := $(shell git rev-parse HEAD 2> /dev/null || true)
|
||||
+ COMMIT := $(if $(shell git status --porcelain --untracked-files=no),"${COMMIT_NO}-dirty","${COMMIT_NO}")
|
||||
+else
|
||||
+ COMMIT := $(GIT_COMMIT_OVERRIDE)
|
||||
+endif
|
||||
|
||||
MAN_DIR := $(CURDIR)/man/man8
|
||||
MAN_PAGES = $(shell ls $(MAN_DIR)/*.8)
|
@ -1,55 +0,0 @@
|
||||
Index: tini/CMakeLists.txt
|
||||
===================================================================
|
||||
--- a/tini/CMakeLists.txt
|
||||
+++ b/tini/CMakeLists.txt
|
||||
@@ -13,27 +13,32 @@ if(MINIMAL)
|
||||
add_definitions(-DTINI_MINIMAL=1)
|
||||
endif()
|
||||
|
||||
-# Extract git version and dirty-ness
|
||||
-execute_process (
|
||||
- COMMAND git --git-dir "${PROJECT_SOURCE_DIR}/.git" --work-tree "${PROJECT_SOURCE_DIR}" log -n 1 --date=local --pretty=format:%h
|
||||
- WORKING_DIRECTORY "${PROJECT_SOURCE_DIR}"
|
||||
- RESULT_VARIABLE git_version_check_ret
|
||||
- OUTPUT_VARIABLE tini_VERSION_GIT
|
||||
-)
|
||||
-
|
||||
-execute_process(
|
||||
- COMMAND git --git-dir "${PROJECT_SOURCE_DIR}/.git" --work-tree "${PROJECT_SOURCE_DIR}" status --porcelain --untracked-files=no
|
||||
- WORKING_DIRECTORY "${PROJECT_SOURCE_DIR}"
|
||||
- OUTPUT_VARIABLE git_dirty_check_out
|
||||
-)
|
||||
+if("$ENV{GIT_COMMIT_OVERRIDE}" EQUAL "")
|
||||
|
||||
-if("${git_version_check_ret}" EQUAL 0)
|
||||
- set(tini_VERSION_GIT " - git.${tini_VERSION_GIT}")
|
||||
- if(NOT "${git_dirty_check_out}" STREQUAL "")
|
||||
- set(tini_VERSION_GIT "${tini_VERSION_GIT}-dirty")
|
||||
+ # Extract git version and dirty-ness
|
||||
+ execute_process (
|
||||
+ COMMAND git --git-dir "${PROJECT_SOURCE_DIR}/.git" --work-tree "${PROJECT_SOURCE_DIR}" log -n 1 --date=local --pretty=format:%h
|
||||
+ WORKING_DIRECTORY "${PROJECT_SOURCE_DIR}"
|
||||
+ RESULT_VARIABLE git_version_check_ret
|
||||
+ OUTPUT_VARIABLE tini_VERSION_GIT
|
||||
+ )
|
||||
+
|
||||
+ execute_process(
|
||||
+ COMMAND git --git-dir "${PROJECT_SOURCE_DIR}/.git" --work-tree "${PROJECT_SOURCE_DIR}" status --porcelain --untracked-files=no
|
||||
+ WORKING_DIRECTORY "${PROJECT_SOURCE_DIR}"
|
||||
+ OUTPUT_VARIABLE git_dirty_check_out
|
||||
+ )
|
||||
+
|
||||
+ if("${git_version_check_ret}" EQUAL 0)
|
||||
+ set(tini_VERSION_GIT " - git.${tini_VERSION_GIT}")
|
||||
+ if(NOT "${git_dirty_check_out}" STREQUAL "")
|
||||
+ set(tini_VERSION_GIT "${tini_VERSION_GIT}-dirty")
|
||||
+ endif()
|
||||
+ else()
|
||||
+ set(tini_VERSION_GIT "")
|
||||
endif()
|
||||
else()
|
||||
- set(tini_VERSION_GIT "")
|
||||
+ set(tini_VERSION_GIT " - git.$ENV{GIT_COMMIT_OVERRIDE}")
|
||||
endif()
|
||||
|
||||
# Flags
|
207
base/python-docker-pycreds/python-docker-pycreds.spec
Normal file
207
base/python-docker-pycreds/python-docker-pycreds.spec
Normal file
@ -0,0 +1,207 @@
|
||||
# Created by pyp2rpm-1.1.2 and rewrote manually afterwards
|
||||
%global pypi_name docker-pycreds
|
||||
|
||||
%if 0%{?fedora} || 0%{?rhel} > 7
|
||||
# Enable python3 build by default
|
||||
%bcond_without python3
|
||||
# Disable python2 build by default
|
||||
%bcond_with python2
|
||||
%else
|
||||
%bcond_with python3
|
||||
%bcond_without python2
|
||||
%endif
|
||||
|
||||
# the test suite is diabled b/c it needs docker-credential-secretservice binary
|
||||
# and we don't have that now (Sep 2016) in Fedora
|
||||
%bcond_with tests
|
||||
|
||||
Name: python-%{pypi_name}
|
||||
Version: 0.4.0
|
||||
Release: 11%{?dist}
|
||||
Summary: Python bindings for the docker credentials store API
|
||||
|
||||
License: ASL 2.0
|
||||
URL: https://github.com/shin-/dockerpy-creds/
|
||||
Source0: https://files.pythonhosted.org/packages/source/d/%{pypi_name}/%{pypi_name}-%{version}.tar.gz
|
||||
BuildArch: noarch
|
||||
|
||||
|
||||
%description
|
||||
Python bindings for the docker credentials store API
|
||||
|
||||
%if %{with python2}
|
||||
%package -n python2-%{pypi_name}
|
||||
Summary: Python bindings for the docker credentials store API
|
||||
|
||||
BuildRequires: python2-devel
|
||||
BuildRequires: python2-setuptools
|
||||
BuildRequires: python2-six
|
||||
|
||||
%if %{with tests}
|
||||
BuildRequires: python2-pytest
|
||||
%endif # tests
|
||||
|
||||
%py_provides python2-%{pypi_name}
|
||||
|
||||
Requires: python2-six
|
||||
|
||||
%description -n python2-%{pypi_name}
|
||||
Python bindings for the docker credentials store API
|
||||
%endif # with python2
|
||||
|
||||
%if %{with python3}
|
||||
%package -n python%{python3_pkgversion}-%{pypi_name}
|
||||
Summary: Python bindings for the docker credentials store API
|
||||
|
||||
BuildRequires: python%{python3_pkgversion}-devel
|
||||
BuildRequires: python%{python3_pkgversion}-setuptools
|
||||
BuildRequires: python%{python3_pkgversion}-six
|
||||
%if %{with tests}
|
||||
BuildRequires: python%{python3_pkgversion}-pytest
|
||||
%endif # tests
|
||||
|
||||
%py_provides python%{python3_pkgversion}-%{pypi_name}
|
||||
|
||||
Requires: python%{python3_pkgversion}-six
|
||||
|
||||
%description -n python%{python3_pkgversion}-%{pypi_name}
|
||||
Python bindings for the docker credentials store API
|
||||
|
||||
%endif # python3
|
||||
|
||||
|
||||
%prep
|
||||
%autosetup -n %{pypi_name}-%{version}
|
||||
|
||||
|
||||
%build
|
||||
%if %{with python2}
|
||||
%py2_build
|
||||
%endif # with python2
|
||||
%if %{with python3}
|
||||
%py3_build
|
||||
%endif # with python3
|
||||
|
||||
|
||||
%install
|
||||
# Must do the subpackages' install first because the scripts in /usr/bin are
|
||||
# overwritten with every setup.py install (and we want the python2 version
|
||||
# to be the default for now).
|
||||
%if %{with python2}
|
||||
%py2_install
|
||||
%endif # with python2
|
||||
%if %{with python3}
|
||||
%py3_install
|
||||
%endif # with python3
|
||||
|
||||
|
||||
# we are not using setup.py test here b/c the project pins to specific versions
|
||||
%check
|
||||
# sanity test
|
||||
%if %{with python2}
|
||||
%{__python2} -c "import dockerpycreds"
|
||||
%if %{with tests}
|
||||
PYTHONPATH="${PWD}" py.test-%{python2_version} -vv tests/
|
||||
%endif # tests
|
||||
%endif # with python2
|
||||
|
||||
%if %{with python3}
|
||||
%{__python3} -c "import dockerpycreds"
|
||||
%if %{with tests}
|
||||
PYTHONPATH="${PWD}" py.test-%{python3_version} -vv tests/
|
||||
%endif # tests
|
||||
%endif # python3
|
||||
|
||||
%if %{with python2}
|
||||
%files -n python2-%{pypi_name}
|
||||
%doc README.md
|
||||
%license LICENSE
|
||||
%{python2_sitelib}/dockerpycreds
|
||||
%{python2_sitelib}/docker_pycreds-%{version}-py?.?.egg-info
|
||||
%endif # with python2
|
||||
|
||||
%if %{with python3}
|
||||
%files -n python%{python3_pkgversion}-%{pypi_name}
|
||||
%doc README.md
|
||||
%license LICENSE
|
||||
%{python3_sitelib}/dockerpycreds
|
||||
%{python3_sitelib}/docker_pycreds-%{version}-py%{python3_version}.egg-info
|
||||
%endif # python3
|
||||
|
||||
|
||||
%changelog
|
||||
* Tue Jul 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.4.0-11
|
||||
- Second attempt - Rebuilt for
|
||||
https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
|
||||
|
||||
* Fri Jun 04 2021 Python Maint <python-maint@redhat.com> - 0.4.0-10
|
||||
- Rebuilt for Python 3.10
|
||||
|
||||
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.4.0-9
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
|
||||
|
||||
* Wed Jul 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 0.4.0-8
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
|
||||
|
||||
* Tue May 26 2020 Miro Hrončok <mhroncok@redhat.com> - 0.4.0-7
|
||||
- Rebuilt for Python 3.9
|
||||
|
||||
* Thu Jan 30 2020 Fedora Release Engineering <releng@fedoraproject.org> - 0.4.0-6
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
|
||||
|
||||
* Thu Oct 03 2019 Miro Hrončok <mhroncok@redhat.com> - 0.4.0-5
|
||||
- Rebuilt for Python 3.8.0rc1 (#1748018)
|
||||
|
||||
* Mon Aug 19 2019 Miro Hrončok <mhroncok@redhat.com> - 0.4.0-4
|
||||
- Rebuilt for Python 3.8
|
||||
|
||||
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.4.0-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
|
||||
|
||||
* Wed Feb 27 2019 Yatin Karel <ykarel@redhat.com> - 0.4.0-2
|
||||
- Enable python2 build for el7
|
||||
|
||||
* Tue Feb 05 2019 Tomas Tomecek <ttomecek@redhat.com> - 0.4.0-1
|
||||
- New upstream release 0.4.0
|
||||
|
||||
* Sat Feb 02 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.3.0-4
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
|
||||
|
||||
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.3.0-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
|
||||
|
||||
* Tue Jun 19 2018 Miro Hrončok <mhroncok@redhat.com> - 0.3.0-2
|
||||
- Rebuilt for Python 3.7
|
||||
|
||||
* Mon Jun 11 2018 Tomas Tomecek <ttomecek@redhat.com> - 0.3.0-1
|
||||
- New upstream release 0.3.0
|
||||
|
||||
* Wed May 02 2018 Tomas Tomecek <ttomecek@redhat.com> - 0.2.3-1
|
||||
- New upstream release 0.2.3
|
||||
|
||||
* Tue Apr 03 2018 Charalampos Stratakis <cstratak@redhat.com> - 0.2.2-2
|
||||
- Conditionalize the Python 2 subpackage and don't build it on EL > 7
|
||||
|
||||
* Mon Feb 19 2018 Tomas Tomecek <ttomecek@redhat.com> - 0.2.2-1
|
||||
- New upstream release 0.2.2
|
||||
|
||||
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.2.1-7
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
|
||||
|
||||
* Wed Dec 27 2017 Carl George <carl@george.computer> - 0.2.1-6
|
||||
- Add BuildRequires for setuptools
|
||||
|
||||
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.2.1-5
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
|
||||
|
||||
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.2.1-4
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
|
||||
|
||||
* Mon Dec 19 2016 Miro Hrončok <mhroncok@redhat.com> - 0.2.1-3
|
||||
- Rebuild for Python 3.6
|
||||
|
||||
* Wed Oct 05 2016 Tomas Tomecek <ttomecek@redhat.com> - 0.2.1-2
|
||||
- rebuilt
|
||||
|
||||
* Mon Sep 26 2016 Tomas Tomecek <ttomecek@redhat.com> - 0.2.1-1
|
||||
- Initial package.
|
200
base/python-dockerpty/python-dockerpty.spec
Normal file
200
base/python-dockerpty/python-dockerpty.spec
Normal file
@ -0,0 +1,200 @@
|
||||
# what it's called on pypi
|
||||
%global srcname dockerpty
|
||||
# what it's imported as
|
||||
%global libname %{srcname}
|
||||
# name of egg info directory
|
||||
%global eggname %{srcname}
|
||||
# package name fragment
|
||||
%global pkgname %{srcname}
|
||||
|
||||
%if 0%{?fedora} >= 30
|
||||
%bcond_with python2
|
||||
%else
|
||||
%bcond_without python2
|
||||
%endif
|
||||
%bcond_without python3
|
||||
|
||||
Name: python-%{pkgname}
|
||||
Version: 0.4.1
|
||||
Release: 23%{?dist}
|
||||
Summary: Python library to use the pseudo-tty of a docker container
|
||||
License: ASL 2.0
|
||||
URL: https://github.com/d11wtq/dockerpty
|
||||
Source0: %{url}/archive/v%{version}/%{srcname}-%{version}.tar.gz
|
||||
BuildArch: noarch
|
||||
|
||||
%global _description\
|
||||
Provides the functionality needed to operate the pseudo-tty (PTY) allocated to\
|
||||
a docker container, using the Python client
|
||||
|
||||
%description %{_description}
|
||||
|
||||
%if %{with python2}
|
||||
%package -n python2-%{pkgname}
|
||||
Summary: %{summary}
|
||||
BuildRequires: python2-devel
|
||||
BuildRequires: python2-setuptools
|
||||
Requires: python2-six
|
||||
%py_provides python2-%{pkgname}
|
||||
|
||||
%description -n python2-%{pkgname} %{_description}
|
||||
%endif
|
||||
|
||||
%if %{with python3}
|
||||
%package -n python%{python3_pkgversion}-%{pkgname}
|
||||
Summary: %{summary}
|
||||
BuildRequires: python%{python3_pkgversion}-devel
|
||||
BuildRequires: python%{python3_pkgversion}-setuptools
|
||||
Requires: python%{python3_pkgversion}-six
|
||||
%py_provides python%{python3_pkgversion}-%{pkgname}
|
||||
|
||||
%description -n python%{python3_pkgversion}-%{pkgname} %{_description}
|
||||
%endif
|
||||
|
||||
%prep
|
||||
%autosetup -n %{srcname}-%{version}
|
||||
|
||||
%build
|
||||
%{?with_python2:%py2_build}
|
||||
%{?with_python3:%py3_build}
|
||||
|
||||
%install
|
||||
%{?with_python2:%py2_install}
|
||||
%{?with_python3:%py3_install}
|
||||
|
||||
# we are missing the 'expects' library to run the tests
|
||||
# %%check
|
||||
# LANG=en_US.utf8 py.test-%%{python3_version} -vv tests
|
||||
# LANG=en_US.utf8 py.test-%%{python2_version} -vv tests
|
||||
|
||||
%if %{with python2}
|
||||
%files -n python2-%{pkgname}
|
||||
%license LICENSE.txt
|
||||
%doc README.md MANIFEST.in
|
||||
%{python2_sitelib}/%{libname}
|
||||
%{python2_sitelib}/%{eggname}-%{version}-py%{python2_version}.egg-info
|
||||
%endif
|
||||
|
||||
%if %{with python3}
|
||||
%files -n python%{python3_pkgversion}-%{pkgname}
|
||||
%license LICENSE.txt
|
||||
%doc README.md MANIFEST.in
|
||||
%{python3_sitelib}/%{libname}
|
||||
%{python3_sitelib}/%{eggname}-%{version}-py%{python3_version}.egg-info
|
||||
%endif
|
||||
|
||||
%changelog
|
||||
* Tue Jul 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.4.1-23
|
||||
- Second attempt - Rebuilt for
|
||||
https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
|
||||
|
||||
* Fri Jun 04 2021 Python Maint <python-maint@redhat.com> - 0.4.1-22
|
||||
- Rebuilt for Python 3.10
|
||||
|
||||
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.4.1-21
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
|
||||
|
||||
* Wed Jul 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 0.4.1-20
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
|
||||
|
||||
* Tue May 26 2020 Miro Hrončok <mhroncok@redhat.com> - 0.4.1-19
|
||||
- Rebuilt for Python 3.9
|
||||
|
||||
* Thu Mar 5 2020 Michael Hampton <error@ioerror.us> - 0.4.1-18
|
||||
- Rebuilt for unretired package
|
||||
|
||||
* Thu Oct 03 2019 Miro Hrončok <mhroncok@redhat.com> - 0.4.1-17
|
||||
- Rebuilt for Python 3.8.0rc1 (#1748018)
|
||||
|
||||
* Mon Aug 19 2019 Miro Hrončok <mhroncok@redhat.com> - 0.4.1-16
|
||||
- Rebuilt for Python 3.8
|
||||
|
||||
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.4.1-15
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
|
||||
|
||||
* Sat Feb 02 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.4.1-14
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
|
||||
|
||||
* Tue Oct 02 2018 Carl George <carl@george.computer> - 0.4.1-13
|
||||
- Disable python2 subpackage on F30+ rhbz#1634971
|
||||
|
||||
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.4.1-12
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
|
||||
|
||||
* Tue Jun 19 2018 Miro Hrončok <mhroncok@redhat.com> - 0.4.1-11
|
||||
- Rebuilt for Python 3.7
|
||||
|
||||
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.4.1-10
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
|
||||
|
||||
* Thu Jan 04 2018 Carl George <carl@george.computer> - 0.4.1-9
|
||||
- EPEL compatibility, including Python 3 build
|
||||
- Mark license appropriately
|
||||
- Use tarball from git tag
|
||||
|
||||
* Sat Aug 19 2017 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 0.4.1-8
|
||||
- Python 2 binary package renamed to python2-dockerpty
|
||||
See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3
|
||||
|
||||
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.4.1-7
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
|
||||
|
||||
* Thu Feb 23 2017 Tomas Tomecek <ttomecek@redhat.com> - 0.4.1-6
|
||||
- don't depend on docker-py when not importing it (#1425461)
|
||||
|
||||
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.4.1-5
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
|
||||
|
||||
* Mon Dec 19 2016 Miro Hrončok <mhroncok@redhat.com> - 0.4.1-4
|
||||
- Rebuild for Python 3.6
|
||||
|
||||
* Tue Jul 19 2016 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.1-3
|
||||
- https://fedoraproject.org/wiki/Changes/Automatic_Provides_for_Python_RPM_Packages
|
||||
|
||||
* Tue Mar 08 2016 Tomas Tomecek <ttomecek@redhat.com> - 0.4.1-2
|
||||
- fix dependencies for py 3 (rhbz#1287729)
|
||||
|
||||
* Tue Mar 08 2016 Tomas Tomecek <ttomecek@redhat.com> - 0.4.1-1
|
||||
- new upstream release: 0.4.1
|
||||
|
||||
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 0.3.4-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
|
||||
|
||||
* Wed Nov 11 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.3.4-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Changes/python3.5
|
||||
|
||||
* Tue Nov 10 2015 Roman Mohr <roman@fenkhuber.at> - 0.3.4-1
|
||||
- Update to 0.3.4 (#1253859)
|
||||
|
||||
* Tue Nov 10 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.3.3-4
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Changes/python3.5
|
||||
|
||||
* Wed Jul 22 2015 Roman Mohr <roman@fenkhuber.at> - 0.3.3-3
|
||||
- Do not run unit tests until python-expects is packaged
|
||||
|
||||
* Thu Jun 18 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.3.3-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
|
||||
|
||||
* Sat Jun 06 2015 Roman Mohr <roman@fenkhuber.at> - 0.3.3-1
|
||||
- Python3 compatible version (rhbz#1172357)
|
||||
|
||||
* Sun Nov 30 2014 Roman Mohr <roman@fenkhuber.at> - 0.3.2-1
|
||||
- Update to latest upstream
|
||||
- Enable unit tests
|
||||
|
||||
* Fri Aug 22 2014 Adam Miller <maxamillion@fedoraproject.org> - 0.2.3-1
|
||||
- Update to latest upstream
|
||||
|
||||
* Mon Aug 11 2014 Adam Miller <maxamillion@fedoraproject.org> - 0.2.1-4
|
||||
- Fixed egg-info dir listings, set noarch based on reviewer feedback
|
||||
|
||||
* Mon Aug 11 2014 Adam Miller <maxamillion@fedoraproject.org> - 0.2.1-3
|
||||
- Fixed files section, fixed py3 summary listing
|
||||
|
||||
* Fri Aug 08 2014 Adam Miller <maxamillion@fedoraproject.org> - 0.2.1-2
|
||||
- Fix __python vs __python2 macro usage and __python3's description
|
||||
- Set ExclusiveArch because of docker
|
||||
- Remove clean section, not needed
|
||||
|
||||
* Wed Jul 23 2014 Adam Miller <maxamillion@fedoraproject.org> - 0.2.1-1
|
||||
- Initial package for Fedora
|
Loading…
x
Reference in New Issue
Block a user