From ec416d41a0a1d2a3577dd8c1294a291196d8df3e1fdb1d817a989fd5a6de17a4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Adrian=20Schr=C3=B6ter?= Date: Tue, 13 May 2025 17:12:51 +0200 Subject: [PATCH] Sync from SUSE:SLFO:Main python-sshtunnel revision 40aea9375e884d56e68089f711acd699 --- .gitattributes | 23 +++++++++++ python-sshtunnel.changes | 88 ++++++++++++++++++++++++++++++++++++++++ python-sshtunnel.spec | 82 +++++++++++++++++++++++++++++++++++++ sshtunnel-0.4.0.tar.gz | 3 ++ 4 files changed, 196 insertions(+) create mode 100644 .gitattributes create mode 100644 python-sshtunnel.changes create mode 100644 python-sshtunnel.spec create mode 100644 sshtunnel-0.4.0.tar.gz diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..9b03811 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,23 @@ +## Default LFS +*.7z filter=lfs diff=lfs merge=lfs -text +*.bsp filter=lfs diff=lfs merge=lfs -text +*.bz2 filter=lfs diff=lfs merge=lfs -text +*.gem filter=lfs diff=lfs merge=lfs -text +*.gz filter=lfs diff=lfs merge=lfs -text +*.jar filter=lfs diff=lfs merge=lfs -text +*.lz filter=lfs diff=lfs merge=lfs -text +*.lzma filter=lfs diff=lfs merge=lfs -text +*.obscpio filter=lfs diff=lfs merge=lfs -text +*.oxt filter=lfs diff=lfs merge=lfs -text +*.pdf filter=lfs diff=lfs merge=lfs -text +*.png filter=lfs diff=lfs merge=lfs -text +*.rpm filter=lfs diff=lfs merge=lfs -text +*.tbz filter=lfs diff=lfs merge=lfs -text +*.tbz2 filter=lfs diff=lfs merge=lfs -text +*.tgz filter=lfs diff=lfs merge=lfs -text +*.ttf filter=lfs diff=lfs merge=lfs -text +*.txz filter=lfs diff=lfs merge=lfs -text +*.whl filter=lfs diff=lfs merge=lfs -text +*.xz filter=lfs diff=lfs merge=lfs -text +*.zip filter=lfs diff=lfs merge=lfs -text +*.zst filter=lfs diff=lfs merge=lfs -text diff --git a/python-sshtunnel.changes b/python-sshtunnel.changes new file mode 100644 index 0000000..add9648 --- /dev/null +++ b/python-sshtunnel.changes @@ -0,0 +1,88 @@ +------------------------------------------------------------------- +Thu Mar 28 07:19:25 UTC 2024 - Steve Kowalik + +- Require update-alternatives for the scriptlets. + +------------------------------------------------------------------- +Tue Mar 26 18:57:48 UTC 2024 - John Paul Adrian Glaubitz + +- Switch build system from setuptools to pyproject.toml + + Add python-pip and python-wheel to BuildRequires + + Replace %python_build with %pyproject_wheel + + Replace %python_install with %pyproject_install +- Limit Python files matched in %files section + +------------------------------------------------------------------- +Mon Jan 15 13:49:41 UTC 2024 - Antonio Larrosa + +- Use %sle15_python_module_pythons + +------------------------------------------------------------------- +Wed Apr 20 07:47:51 UTC 2022 - pgajdos@suse.com + +- do not require python-mock for build + +------------------------------------------------------------------- +Mon Feb 1 22:00:48 UTC 2021 - Dirk Müller + +- update to 0.4.0: + + Change the daemon mod flag for all tunnel threads (is not fully backward + compatible) to prevent unexpected hangs (`#219`_) + Add docker based end to end + functinal tests for Mongo/Postgres/MySQL + + Add docker based end to end hangs tests + + Fix host key directory detection + + Unify default ssh config folder to `~/.ssh` + + Increase open connection timeout to 10 secods + + Change default with context behavior to use `.stop(force=True)` on exit + + Remove useless `daemon_forward_servers = True` hack for hangs prevention + + Set transport keepalive to 5 second by default + + Set default transport timeout to 0.1 + + Deprecate and remove `block_on_close` option + + Fix "deadlocks" / "tunneling hangs" + + Add `.stop(force=True)` for force close active connections + + Fixes bug with orphan thread for a tunnel that is DOWN + + Support IPv6 without proxy command. Use built-in paramiko create socket + logic. The logic tries to use ipv6 socket family first, then ipv4 socket + family. + +------------------------------------------------------------------- +Mon Jul 22 12:49:32 UTC 2019 - Tomáš Chvátal + +- Update to 0.1.5: + * Introduce block_on_close attribute + +------------------------------------------------------------------- +Thu Mar 7 15:08:15 UTC 2019 - John Vandenberg + +- Remove test runner exception as bug is fixed upstream + +------------------------------------------------------------------- +Thu Aug 23 14:27:09 UTC 2018 - alarrosa@suse.com + +- Update to 0.1.4 + * Allow loading pkeys from ~/.ssh + +------------------------------------------------------------------- +Wed May 9 11:21:33 UTC 2018 - tchvatal@suse.com + +- Disable deprecation detector test as it is broken + +------------------------------------------------------------------- +Wed May 9 10:59:26 UTC 2018 - tchvatal@suse.com + +- Switch to pytest and run tests directly instead of running them + in tox virtual enviroment + +------------------------------------------------------------------- +Wed May 9 10:55:00 UTC 2018 - tchvatal@suse.com + +- Use %license to install license +- Really execute tests +- Really switch to github url as pypi deployment does not contain + the tests + +------------------------------------------------------------------- +Mon May 7 08:23:14 UTC 2018 - adrian.glaubitz@suse.com + +- Initial build + + Version 0.1.3 diff --git a/python-sshtunnel.spec b/python-sshtunnel.spec new file mode 100644 index 0000000..10033ac --- /dev/null +++ b/python-sshtunnel.spec @@ -0,0 +1,82 @@ +# +# spec file for package python-sshtunnel +# +# Copyright (c) 2024 SUSE LLC +# +# All modifications and additions to the file contributed by third parties +# remain the property of their copyright owners, unless otherwise agreed +# upon. The license for this file, and modifications and additions to the +# file, is the same license as for the pristine package itself (unless the +# license for the pristine package is not an Open Source License, in which +# case the license is the MIT License). An "Open Source License" is a +# license that conforms to the Open Source Definition (Version 1.9) +# published by the Open Source Initiative. + +# Please submit bugfixes or comments via https://bugs.opensuse.org/ +# + + +%{?sle15_python_module_pythons} +Name: python-sshtunnel +Version: 0.4.0 +Release: 0 +Summary: SSH tunnels to remote server +License: MIT +Group: Development/Languages/Python +URL: https://github.com/pahaz/sshtunnel/ +Source: https://files.pythonhosted.org/packages/source/s/sshtunnel/sshtunnel-%{version}.tar.gz +BuildRequires: %{python_module paramiko >= 2.7.2} +BuildRequires: %{python_module pip} +BuildRequires: %{python_module pytest} +BuildRequires: %{python_module setuptools} +BuildRequires: %{python_module wheel} +# for the tests to validate some things +BuildRequires: fdupes +BuildRequires: openssh +BuildRequires: python-rpm-macros +Requires: openssh +Requires: python-paramiko >= 2.7.2 +Requires(post): update-alternatives +Requires(postun): update-alternatives +BuildArch: noarch +%python_subpackages + +%description +The sshtunnel package allows one to create SSH tunnels using local +or remote port forwarding. Thus, it provides a Python wrapper to +the same functionality provided by the SSH command using the -L +and -R parameters. + +%prep +%setup -q -n sshtunnel-%{version} +# Remove shebang line +sed -i '1{\,^#!%{_bindir}/env python,d}' sshtunnel.py + +%build +%pyproject_wheel + +%install +%pyproject_install +%python_clone -a %{buildroot}%{_bindir}/sshtunnel +%python_expand %fdupes %{buildroot}%{$python_sitelib} + +%check +# https://github.com/pahaz/sshtunnel/issues/259 +sed -i 's:import mock:from unittest import mock:' tests/test_forwarder.py +%pytest + +%post +%python_install_alternative sshtunnel + +%postun +%python_uninstall_alternative sshtunnel + +%files %{python_files} +%license LICENSE +%doc *.rst +%python_alternative %{_bindir}/sshtunnel +%pycache_only %{python_sitelib}/__pycache__/sshtunnel*pyc +%{python_sitelib}/sshtunnel.py +%{python_sitelib}/sshtunnel-{%version}.dist-info + +%changelog diff --git a/sshtunnel-0.4.0.tar.gz b/sshtunnel-0.4.0.tar.gz new file mode 100644 index 0000000..382f115 --- /dev/null +++ b/sshtunnel-0.4.0.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e7cb0ea774db81bf91844db22de72a40aae8f7b0f9bb9ba0f666d474ef6bf9fc +size 62716