Add debian package for virt/cloud-init

Add debian packaging infrastructure for virt/cloud-init
to build a debian package.

Verification:
- Built package
- Built image

Story: 2009101
Task: 44025

Signed-off-by: Leonardo Fagundes Luz Serrano <Leonardo.FagundesLuzSerrano@windriver.com>
Change-Id: Ifaacdc067812503113fc52c81bcd3be68a17ae3e
This commit is contained in:
Leonardo Fagundes Luz Serrano 2021-11-22 10:45:58 -03:00
parent 4eecd1f723
commit 6d1244bda9
3 changed files with 43 additions and 0 deletions

View File

@ -0,0 +1,9 @@
debname: cloud-init
debver: 20.4.1-2+deb11u1
dl_path:
name: cloud-init-debian-20.4.1-2+deb11u1.tar.gz
url: https://salsa.debian.org/cloud-team/cloud-init/-/archive/debian/20.4.1-2+deb11u1/cloud-init-debian-20.4.1-2+deb11u1.tar.gz
md5sum: e125f0b7651386430cbf6a5e80789b8e
revision:
dist: $STX_DIST
PKG_GITREVCOUNT: true

View File

@ -0,0 +1,33 @@
From 5cb0a79cadabe8659ba36c9ac794cd49fc4f41c1 Mon Sep 17 00:00:00 2001
From: Leonardo Fagundes Luz Serrano
<Leonardo.FagundesLuzSerrano@windriver.com>
Date: Wed, 5 Jan 2022 10:36:18 -0300
Subject: [PATCH] For invoking parted w/o handling cmd prompts interactively
From resizepart.sh:
"This is a workaround to allow cloud-init to invoke parted
without needing to handle command prompts interactively.
Support for non-interactive parted commands
are not supported on mounted partitions."
Signed-off-by: Leonardo Fagundes Luz Serrano <Leonardo.FagundesLuzSerrano@windriver.com>
---
cloudinit/config/cc_growpart.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/cloudinit/config/cc_growpart.py b/cloudinit/config/cc_growpart.py
index 9f338ad1..e70b0d1e 100644
--- a/cloudinit/config/cc_growpart.py
+++ b/cloudinit/config/cc_growpart.py
@@ -192,7 +192,7 @@ class ResizeGpart(object):
before = get_size(partdev)
try:
- subp.subp(["gpart", "resize", "-i", partnum, diskdev])
+ subp.subp(["resizepart.sh", diskdev, partnum])
except subp.ProcessExecutionError as e:
util.logexc(LOG, "Failed: gpart resize -i %s %s", partnum, diskdev)
raise ResizeFailedException(e) from e
--
2.17.1

View File

@ -0,0 +1 @@
0001-For-invoking-parted-w-o-handling-cmd-prompts-interac.patch