[pbs-devel] applied: [PATCH proxmox-backup] api types: add missing conf to blob archive name mapping
Fabian Grünbichler
f.gruenbichler at proxmox.com
Tue Nov 26 13:32:06 CET 2024
On November 26, 2024 1:24 pm, Christian Ebner wrote:
> Commit addfae26 ("api types: introduce `BackupArchiveName` type")
> introduced a dedicated archive name api type to add rust type
> checking and bundle helpers to the api type. Since this, the backup
> archive name to server archive name mapping is handled by its parser.
>
> This however did not cover the `.conf` extension used for VM config
> files. Add the missing `.conf` to `.conf.blob` to the match statement
> and the test cases.
>
> Fixes: addfae26 ("api types: introduce `BackupArchiveName` type")
> Reported-by: Stoiko Ivanov <s.ivanov at proxmox.com>
> Signed-off-by: Christian Ebner <c.ebner at proxmox.com>
> ---
> pbs-api-types/src/datastore.rs | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/pbs-api-types/src/datastore.rs b/pbs-api-types/src/datastore.rs
> index 4927f3724..688b7dd03 100644
> --- a/pbs-api-types/src/datastore.rs
> +++ b/pbs-api-types/src/datastore.rs
> @@ -1833,6 +1833,7 @@ impl BackupArchiveName {
> Some("ppxar") => ArchiveType::DynamicIndex,
> Some("pcat1") => ArchiveType::DynamicIndex,
> Some("img") => ArchiveType::FixedIndex,
> + Some("conf") => ArchiveType::Blob,
> Some("json") => ArchiveType::Blob,
> Some("key") => ArchiveType::Blob,
> Some("log") => ArchiveType::Blob,
> @@ -1910,6 +1911,8 @@ mod tests {
> "/valid/rsa-encrypted.key.blob",
> "/valid/archive-name.log",
> "/valid/archive-name.log.blob",
> + "/valid/qemu-server.conf",
> + "/valid/qemu-server.conf.blob",
> ];
>
> for archive_name in valid_archive_names {
> --
> 2.39.5
>
>
>
> _______________________________________________
> pbs-devel mailing list
> pbs-devel at lists.proxmox.com
> https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel
>
>
>
More information about the pbs-devel
mailing list