8484 - os : ubuntu-24.04
8585 python-version : ' 3.13'
8686 toxenv : py313-fuse3
87+ - os : ubuntu-24.04
88+ python-version : ' 3.14-dev'
89+ toxenv : py314-fuse3
8790
8891 env :
8992 TOXENV : ${{ matrix.toxenv }}
9497 steps :
9598 - uses : actions/checkout@v4
9699 with :
97- # just fetching 1 commit is not enough for setuptools-scm, so we fetch all
100+ # Just fetching one commit is not enough for setuptools-scm, so we fetch all.
98101 fetch-depth : 0
99102 - name : Set up Python ${{ matrix.python-version }}
100103 uses : actions/setup-python@v5
@@ -117,7 +120,60 @@ jobs:
117120 sudo apt-get install -y libfuse-dev fuse || true # Required for Python llfuse module
118121 sudo apt-get install -y libfuse3-dev fuse3 || true # Required for Python pyfuse3 module
119122 sudo apt-get install -y bash zsh fish # for shell completion tests
120-
123+ sudo apt-get install -y rclone openssh-server curl
124+ - name : Configure OpenSSH SFTP server (test only)
125+ run : |
126+ sudo mkdir -p /run/sshd
127+ sudo useradd -m -s /bin/bash sftpuser || true
128+ # Create SSH key for the CI user and authorize it for sftpuser
129+ mkdir -p ~/.ssh
130+ chmod 700 ~/.ssh
131+ test -f ~/.ssh/id_ed25519 || ssh-keygen -t ed25519 -N '' -f ~/.ssh/id_ed25519
132+ sudo mkdir -p /home/sftpuser/.ssh
133+ sudo chmod 700 /home/sftpuser/.ssh
134+ sudo cp ~/.ssh/id_ed25519.pub /home/sftpuser/.ssh/authorized_keys
135+ sudo chown -R sftpuser:sftpuser /home/sftpuser/.ssh
136+ sudo chmod 600 /home/sftpuser/.ssh/authorized_keys
137+ # Allow publickey auth and enable Subsystem sftp
138+ sudo sed -i 's/^#\?PasswordAuthentication .*/PasswordAuthentication no/' /etc/ssh/sshd_config
139+ sudo sed -i 's/^#\?PubkeyAuthentication .*/PubkeyAuthentication yes/' /etc/ssh/sshd_config
140+ if ! grep -q '^Subsystem sftp' /etc/ssh/sshd_config; then echo 'Subsystem sftp /usr/lib/openssh/sftp-server' | sudo tee -a /etc/ssh/sshd_config; fi
141+ # Ensure host keys exist to avoid slow generation on first sshd start
142+ sudo ssh-keygen -A
143+ # Start sshd (listen on default 22 inside runner)
144+ sudo /usr/sbin/sshd -D &
145+ # Add host key to known_hosts so paramiko trusts it
146+ ssh-keyscan -H localhost 127.0.0.1 | tee -a ~/.ssh/known_hosts
147+ # Start ssh-agent and add our key so paramiko can use the agent
148+ eval "$(ssh-agent -s)"
149+ ssh-add ~/.ssh/id_ed25519
150+ # Export SFTP test URL for tox via GITHUB_ENV
151+ echo "BORG_TEST_SFTP_REPO=sftp://sftpuser@localhost:22/borg/sftp-repo" >> $GITHUB_ENV
152+ - name : Install and configure MinIO S3 server (test only)
153+ run : |
154+ set -e
155+ arch=$(uname -m)
156+ case "$arch" in
157+ x86_64|amd64) srv_url=https://dl.min.io/server/minio/release/linux-amd64/minio; cli_url=https://dl.min.io/client/mc/release/linux-amd64/mc ;;
158+ aarch64|arm64) srv_url=https://dl.min.io/server/minio/release/linux-arm64/minio; cli_url=https://dl.min.io/client/mc/release/linux-arm64/mc ;;
159+ *) echo "Unsupported arch: $arch"; exit 1 ;;
160+ esac
161+ curl -fsSL -o /usr/local/bin/minio "$srv_url"
162+ curl -fsSL -o /usr/local/bin/mc "$cli_url"
163+ sudo chmod +x /usr/local/bin/minio /usr/local/bin/mc
164+ export PATH=/usr/local/bin:$PATH
165+ # Start MinIO on :9000 with default credentials (minioadmin/minioadmin)
166+ MINIO_DIR="$GITHUB_WORKSPACE/.minio-data"
167+ MINIO_LOG="$GITHUB_WORKSPACE/.minio.log"
168+ mkdir -p "$MINIO_DIR"
169+ nohup minio server "$MINIO_DIR" --address ":9000" >"$MINIO_LOG" 2>&1 &
170+ # Wait for MinIO port to be ready
171+ for i in $(seq 1 60); do (echo > /dev/tcp/127.0.0.1/9000) >/dev/null 2>&1 && break; sleep 1; done
172+ # Configure client and create bucket
173+ mc alias set local http://127.0.0.1:9000 minioadmin minioadmin
174+ mc mb --ignore-existing local/borg
175+ # Export S3 test URL for tox via GITHUB_ENV
176+ echo "BORG_TEST_S3_REPO=s3:minioadmin:minioadmin@http://127.0.0.1:9000/borg/s3-repo" >> $GITHUB_ENV
121177 - name : Install Python requirements
122178 run : |
123179 python -m pip install --upgrade pip setuptools wheel
@@ -150,7 +206,7 @@ jobs:
150206 include :
151207 - os : macos-14
152208 python-version : ' 3.11'
153- toxenv : py311-none # note : no fuse testing, due to #6099, see also #6196.
209+ toxenv : py311-none # Note : no FUSE testing due to #6099; see also #6196.
154210
155211 env :
156212 # Configure pkg-config to use OpenSSL from Homebrew
@@ -163,7 +219,7 @@ jobs:
163219 steps :
164220 - uses : actions/checkout@v4
165221 with :
166- # just fetching 1 commit is not enough for setuptools-scm, so we fetch all
222+ # Just fetching one commit is not enough for setuptools-scm, so we fetch all
167223 fetch-depth : 0
168224 - name : Set up Python ${{ matrix.python-version }}
169225 uses : actions/setup-python@v5
@@ -187,21 +243,21 @@ jobs:
187243 run : |
188244 python -m pip install --upgrade pip setuptools wheel
189245 pip install -r requirements.d/development.txt
190- - name : Install borgbackup
246+ - name : Install BorgBackup
191247 env :
192- # we already have that in the global env , but something is broken and overwrites that .
193- # so, set it here, again.
248+ # We already have this in the global environment , but something overrides it .
249+ # So set it here again.
194250 PKG_CONFIG_PATH : " /opt/homebrew/opt/openssl@3.0/lib/pkgconfig:$PKG_CONFIG_PATH"
195251 run : |
196252 pip install -ve .
197- - name : run tox env
253+ - name : Run pytest via tox
198254 env :
199- # we already have that in the global env , but something is broken and overwrites that .
200- # so, set it here, again.
255+ # We already have this in the global environment , but something overrides it .
256+ # So set it here again.
201257 PKG_CONFIG_PATH : " /opt/homebrew/opt/openssl@3.0/lib/pkgconfig:$PKG_CONFIG_PATH"
202258 XDISTN : " 6"
203259 run : |
204- # do not use fakeroot, but run as root. avoids the dreaded EISDIR sporadic failures. see #2482.
260+ # Do not use fakeroot; run as root. Avoids the dreaded sporadic EISDIR failures; see #2482.
205261 #sudo -E bash -c "tox -e py"
206262 tox --skip-missing-interpreters
207263 - name : Upload coverage to Codecov
@@ -215,7 +271,7 @@ jobs:
215271
216272 windows :
217273
218- if : false # can be used to temporary disable build
274+ if : false # can be used to temporarily disable the build
219275 runs-on : windows-latest
220276 timeout-minutes : 120
221277 needs : linux
0 commit comments