From 42189c8abcfa7b73fc302f032f6314a156a26b9d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20P=C3=B6hn?= Date: Wed, 8 Oct 2025 21:30:52 +0200 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=B4=20implement=20pull=20for=20vagrant?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- fdroidserver/pull.py | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/fdroidserver/pull.py b/fdroidserver/pull.py index 8144470f..4ec21195 100644 --- a/fdroidserver/pull.py +++ b/fdroidserver/pull.py @@ -33,6 +33,7 @@ Since this is an internal command, the strings are not localized. import os import sys import logging +import subprocess import tarfile import tempfile import traceback @@ -59,6 +60,22 @@ def podman_pull(appid, vercode, path): def vagrant_pull(appid, vercode, path): """Pull the path from the Vagrant VM.""" + vagrantfile = common.get_vagrantfile_path(appid, vercode) + path_in_vm = os.path.join(common.BUILD_HOME, path) + + vagrantbin = common.get_vagrant_bin_path() + rsyncbin = common.get_rsync_bin_path() + + with common.TmpVagrantSshConf(vagrantbin, vagrantfile.parent) as ssh_config_file: + cmd = [ + rsyncbin, + '-av', + '-e', + f'ssh -F {ssh_config_file}', + f'default:{path_in_vm}', + './unsigned', + ] + subprocess.check_call(cmd) def make_file_list(appid, vercode):