Commit Graph

20 Commits

Author SHA1 Message Date
Fredrik Lönnegren f132230beb Update copyright year (2025)
Signed-off-by: Fredrik Lönnegren <fredrik.lonnegren@suse.com>
2025-01-07 16:43:28 +01:00
Fredrik Lönnegren 1a529527ae Bump yip to v1.9.3
This removes the Git plugin and alot of go dependencies.

Signed-off-by: Fredrik Lönnegren <fredrik.lonnegren@suse.com>
2024-09-05 14:47:12 +02:00
David Cassany b41f7d20ad Bump tp yip 1.6.2
Signed-off-by: David Cassany <dcassany@suse.com>
2024-07-04 16:05:47 +02:00
David Cassany Viladomat c05f5d4913
bump elemental-toolkit to v2 (#1969)
* bump elemental-toolkit to v2

Signed-off-by: David Cassany <dcassany@suse.com>

* Move pkg/types/v2 to simply pkg/types

This commit leaves the code with a single set of types
and in refers to it as the types packge instead of
v1 or v2.

For the time being we do not foresee managing more
than one single major version of type within the
same code.

Signed-off-by: David Cassany <dcassany@suse.com>

* Stop referring to mocks package as v2mock in favor of simply 'mocks'

Signed-off-by: David Cassany <dcassany@suse.com>

* Fix leftovers after rebase

Signed-off-by: David Cassany <dcassany@suse.com>

---------

Signed-off-by: David Cassany <dcassany@suse.com>
2024-03-08 09:14:56 +01:00
Fredrik Lönnegren 324583fced Use rancher/yip v1.4.8
Signed-off-by: Fredrik Lönnegren <fredrik.lonnegren@suse.com>
2024-01-25 11:11:20 +01:00
David Cassany 2e18efa696 Bump twpayne/vfs module to latest version
Specifically bumping from v1.7.2 to v4.3.0. We were pretty outdated.

This commit could not get rid of the old version dependency completely
because yip requires a vfs v1 within the plugin API and we implement
a yip plugin for partitioning in elemental-toolkit. Because of that
both versions are coexisting.

Signed-off-by: David Cassany <dcassany@suse.com>
2024-01-19 16:56:49 +01:00
Fredrik Lönnegren cd4e009b88 Update copyright year (2024)
Signed-off-by: Fredrik Lönnegren <fredrik.lonnegren@suse.com>
2024-01-09 09:44:34 +01:00
David Cassany Viladomat 3ea9d757e4
build-disk command (#1794)
This commit adds in elemental client the build-disk command. With this command we can eventually build an image that includes partitions:

* EFI
* OEM
* Recovery
* State

Having State partition to match the minimum size (to reduce resulting image size), only includes config files no image.

Then the State partition could be expanded on first boot to desired size (build-disk command already pre-appends the required cloud-config files for that to happen) and then the Persistent partition created at the end with all the available space (or some desired specific size too).

This setup can be executed without running a single mount (thanks to squashfs usage), meaning this disk could be built in a container or Dockerfile (like we do with ISOs).

Building full disks including all partitions with an specified size is still possible, however this approach requires mount privileges and because of that it can't be executed inside non privileged containers.


Signed-off-by: David Cassany <dcassany@suse.com>
2023-10-17 14:26:19 +02:00
Fredrik Lönnegren 1262bcd099 Move elemental-cli into elemental-toolkit module
Signed-off-by: Fredrik Lönnegren <fredrik.lonnegren@suse.com>
2023-05-16 09:43:57 +02:00
David Cassany be54c0707f Use year range in copyright headers instead of just bumping the year
Signed-off-by: David Cassany <dcassany@suse.com>
2023-01-12 11:13:33 +01:00
David Cassany 408d2ab56f Bump year in copyright headers
Signed-off-by: David Cassany <dcassany@suse.com>
2023-01-12 11:13:33 +01:00
Itxaka 772b2d1d7d
Bump ghw and fix labels (#253) 2022-06-14 11:56:41 +00:00
Francesco Giudici 6458932b86
Rename package to rancher/elemental-cli (#236)
Update package name and internal references.

Signed-off-by: Francesco Giudici <francesco.giudici@suse.com>
2022-06-06 15:27:57 +02:00
Ettore Di Giacinto 4f8bf31dff
Bump luet and wire up logger from elemental (#226)
Signed-off-by: Ettore Di Giacinto <edigiacinto@suse.com>
2022-05-26 17:02:06 +02:00
Itxaka 89d323a36c
Drop lsblk in favour of ghw library (#155) 2022-04-05 12:13:43 +02:00
David Cassany Viladomat 2dc11d6295
Remove blkid dependency and limit lsblk usage (#147)
This commit removes all blkid calls and wraps lsblk in a more
normalized and generic way. lsblk is only called in two methods:

* GetDevicePartitions: returns a v1.PartitionList with all the
partitions or loop devices for the given device path.

* GetAllPartitions: returns a v1.PartitionList with all the partitions
and loop devices of the host.

Signed-off-by: David Cassany <dcassany@suse.com>
2022-03-16 10:54:06 +00:00
Ettore Di Giacinto 785ef65cec
Check partial yaml unmarshal errors and unify FS (#125)
* Check partial yaml unmarshal errors

Signed-off-by: Ettore Di Giacinto <edigiacinto@suse.com>

* Make sure cloud-init paths are created in the system

Signed-off-by: Ettore Di Giacinto <edigiacinto@suse.com>

* Don't use terminal to read cmdline

Also, refactor common code

Signed-off-by: Ettore Di Giacinto <edigiacinto@suse.com>

* Introduce FS interface

Signed-off-by: Ettore Di Giacinto <edigiacinto@suse.com>

* Get rid of afero

Signed-off-by: Ettore Di Giacinto <edigiacinto@suse.com>

* Add fs to rsync command

This allows the rsync library we use beneath to be fs-aware.

Signed-off-by: Ettore Di Giacinto <edigiacinto@suse.com>

* Mitigate licence check on fs.go

Signed-off-by: Ettore Di Giacinto <edigiacinto@suse.com>
2022-03-09 18:31:17 +01:00
Itxaka 491b27d09a
Use golangci for lint+license check (#123) 2022-03-03 09:49:22 +00:00
David Cassany Viladomat 22cfa4043c
Ensure cloudinit tests can be executed in parallel (#112)
Signed-off-by: David Cassany <dcassany@suse.com>
2022-02-18 11:13:01 +00:00
David Cassany Viladomat adea0565b6
Implement yip's Layout plugin using partitioner package (#111)
This commit makes use of the partitioner elemental package to provide a
custom implementation of the yip's layout plugin. This has the benefit
of adding support for MSDOS partition tables.

In order to make that happen few refactors were needed:

* Separate cloud-init-runner interface and implementation in separate
packages.
* Extend v1.Runner interface
* Separate v1.RunConfig initializer to a separate package

Signed-off-by: David Cassany <dcassany@suse.com>
2022-02-17 17:35:19 +01:00