From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [IPv6:2a01:7e0:0:424::9]) by lore.proxmox.com (Postfix) with ESMTPS id C26901FF187 for ; Fri, 19 Dec 2025 17:18:20 +0100 (CET) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 970491134F; Fri, 19 Dec 2025 17:19:09 +0100 (CET) From: Robert Obkircher To: pbs-devel@lists.proxmox.com Date: Fri, 19 Dec 2025 17:18:27 +0100 Message-ID: <20251219161850.244154-1-r.obkircher@proxmox.com> X-Mailer: git-send-email 2.47.3 MIME-Version: 1.0 X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1766161132515 X-SPAM-LEVEL: Spam detection results: 0 AWL 0.057 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment RCVD_IN_VALIDITY_CERTIFIED_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. RCVD_IN_VALIDITY_RPBL_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. RCVD_IN_VALIDITY_SAFE_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record URIBL_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to URIBL was blocked. See http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block for more information. [mod.rs, datastore.rs, push.rs, test-pipes.sh, environment.rs, main.rs] Subject: [pbs-devel] [PATCH v2 proxmox-backup 0/5] fix: #3847 pipe from STDIN to proxmox-backup-client X-BeenThere: pbs-devel@lists.proxmox.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Proxmox Backup Server development discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Proxmox Backup Server development discussion Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: pbs-devel-bounces@lists.proxmox.com Sender: "pbs-devel" Add support for commands like: ssh host cmd | proxmox-backup-client backup data.img:/dev/stdin proxmox-backup-client backup a.img:<(mysqldump) b.img:<(pgdump) Changes since v1: - use mremap+ftruncate instead of write_all_at - make the size API parameter optional instead of using 0 - use an enum to represent fixed/dynamic chunk size in UploadOptions - alias "-" to "/dev/stdin" - split changes into separate commits This does not yet need a detailed review, but let me know if anything looks completely off. I'm still planning on writing some proper tests for the backend. That may involve moving the resizing logic to a type like proxmox_sys::mmap::Mmap, so it can be tested in isolation. Christian Ebner previously suggested defining a trait for the FixedIndexWriter, with separate implementations for known and unknown size. I'm not sure if this is still necessary, because the changes are already much more isolated. Should I still introduce such a trait? Robert Obkircher (5): fix #3847: datastore: support writing fidx files of unknown size fix #3847: api: backup: make fixed index file size optional fix #3847: client: support fifo pipe inputs for images fix #3847: client: treat minus sign as stdin DO NOT MERGE: test script for reference pbs-client/src/backup_writer.rs | 37 ++++++++---- pbs-datastore/src/datastore.rs | 2 +- pbs-datastore/src/fixed_index.rs | 98 +++++++++++++++++++++++++++++-- proxmox-backup-client/src/main.rs | 37 ++++++++---- src/api2/backup/environment.rs | 8 ++- src/api2/backup/mod.rs | 4 +- src/server/push.rs | 13 ++-- test-pipes.sh | 68 +++++++++++++++++++++ 8 files changed, 227 insertions(+), 40 deletions(-) create mode 100755 test-pipes.sh -- 2.47.3 _______________________________________________ pbs-devel mailing list pbs-devel@lists.proxmox.com https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel