machine-image: introduce two different classes of images
This distuingishes two different classes of images, one for the purpose of npsawn-like containers, i.e. "machines", and one for portable services. This distinction is mostly about search paths. We look for machine images in /var/lib/machines and for portable images in /var/lib/portables.
This commit is contained in:
+2
-2
@@ -69,7 +69,7 @@ static int export_tar(int argc, char *argv[], void *userdata) {
|
||||
int r, fd;
|
||||
|
||||
if (machine_name_is_valid(argv[1])) {
|
||||
r = image_find(argv[1], &image);
|
||||
r = image_find(IMAGE_MACHINE, argv[1], &image);
|
||||
if (r < 0)
|
||||
return log_error_errno(r, "Failed to look for machine %s: %m", argv[1]);
|
||||
if (r == 0) {
|
||||
@@ -148,7 +148,7 @@ static int export_raw(int argc, char *argv[], void *userdata) {
|
||||
int r, fd;
|
||||
|
||||
if (machine_name_is_valid(argv[1])) {
|
||||
r = image_find(argv[1], &image);
|
||||
r = image_find(IMAGE_MACHINE, argv[1], &image);
|
||||
if (r < 0)
|
||||
return log_error_errno(r, "Failed to look for machine %s: %m", argv[1]);
|
||||
if (r == 0) {
|
||||
|
||||
Reference in New Issue
Block a user