@@ -15,12 +15,17 @@ mpp-vars:
15
15
ppc_prep_size_mb : 4
16
16
reserved_part_size_mb : 1
17
17
efi_system_size_mb : 127
18
+ se_size_mb : 200
18
19
boot_size_mb : 384
20
+ root_size_mb : 1800
21
+ boot_verity_size_mb : 128
22
+ root_verity_size_mb : 256
19
23
sector_size : 512
20
24
four_k_sector_size : 4096
21
25
# Filesystem UUID and label definitions. These UUIDs
22
26
# are looked for on boot and if found replaced with
23
27
# a new random UUID to make each install unique.
28
+ sd_fs_label : se
24
29
boot_fs_uuid : 96d15588-3596-4b3c-adca-a2ff7279ea63
25
30
boot_fs_label : boot
26
31
root_fs_uuid : 910678ff-f77e-4a7d-8d53-86f2ac47a823
@@ -40,6 +45,8 @@ mpp-vars:
40
45
# the host buildroot is the default if nothing is specified.
41
46
# We're still defining it here in an attempt to be explicit.
42
47
qemu_stage_buildroot : " "
48
+ # IBM Secure Execution
49
+ qemu_secex : $qemu_secex
43
50
mpp-define-images :
44
51
- id : image
45
52
sector_size :
@@ -75,6 +82,40 @@ mpp-define-images:
75
82
- name : root
76
83
type : 0FC63DAF-8483-4772-8E79-3D69D8477DE4
77
84
partnum : 4
85
+ # Secure Execution image. It MUST contain same partitions as `image` plus 3 additional
86
+ - id : image_secex
87
+ sector_size :
88
+ mpp-format-int : " {sector_size}"
89
+ size :
90
+ mpp-format-string : " {metal_image_size_mb * 1024 * 1024}"
91
+ table :
92
+ uuid : 00000000-0000-4000-a000-000000000001
93
+ label : gpt
94
+ partitions :
95
+ - name : se
96
+ type : 0FC63DAF-8483-4772-8E79-3D69D8477DE4
97
+ partnum : 1
98
+ size :
99
+ mpp-format-int : " {se_size_mb * 1024 * 1024 / sector_size}"
100
+ - name : boot
101
+ type : 0FC63DAF-8483-4772-8E79-3D69D8477DE4
102
+ partnum : 3
103
+ size :
104
+ mpp-format-int : " {boot_size_mb * 1024 * 1024 / sector_size}"
105
+ - name : root
106
+ type : 0FC63DAF-8483-4772-8E79-3D69D8477DE4
107
+ partnum : 4
108
+ size :
109
+ mpp-format-int : " {root_size_mb * 1024 * 1024 / sector_size}"
110
+ - name : boothash
111
+ partnum : 5
112
+ size :
113
+ mpp-format-int : " {boot_verity_size_mb * 1024 * 1024 / sector_size}"
114
+ - name : roothash
115
+ type : B325BFBE-C7BE-4AB8-8357-139E652D2F6B
116
+ partnum : 6
117
+ size :
118
+ mpp-format-int : " {root_verity_size_mb * 1024 * 1024 / sector_size}"
78
119
pipelines :
79
120
# If installing from container then let's pull the container file into a pipeline
80
121
- name : oci-archive
@@ -148,6 +189,13 @@ pipelines:
148
189
# filesystem by OSTree (boot -> .) that makes it so that /boot paths
149
190
# will always work.
150
191
bootprefix : true
192
+ # If on s390x with secex then mkdir for filesytem labeled `se`, where `sdboot` image gets stored
193
+ - mpp-if : qemu_secex != ''
194
+ then :
195
+ type : org.osbuild.mkdir
196
+ options :
197
+ paths :
198
+ - path : /se
151
199
- type : org.osbuild.ignition
152
200
# Deploy via OSTree repo if specified, otherwise ociarchive or container.
153
201
- mpp-if : ostree_repo != ''
@@ -475,6 +523,130 @@ pipelines:
475
523
source : mount
476
524
deployment :
477
525
default : true
526
+ # IBM Secure Execution (secex) image has special layout
527
+ - name : raw-secex-image
528
+ build :
529
+ mpp-format-string : ' {buildroot}'
530
+ stages :
531
+ - type : org.osbuild.truncate
532
+ options :
533
+ filename : disk.img
534
+ size :
535
+ mpp-format-string : ' {image_secex.size}'
536
+ - type : org.osbuild.sfdisk
537
+ devices :
538
+ device :
539
+ type : org.osbuild.loopback
540
+ options :
541
+ filename : disk.img
542
+ options :
543
+ mpp-format-json : ' {image_secex.layout}'
544
+ - type : org.osbuild.mkfs.ext4
545
+ devices :
546
+ device :
547
+ type : org.osbuild.loopback
548
+ options :
549
+ filename : disk.img
550
+ start :
551
+ mpp-format-int : ' {image_secex.layout['' se'' ].start}'
552
+ size :
553
+ mpp-format-int : ' {image_secex.layout['' se'' ].size}'
554
+ lock : true
555
+ options :
556
+ uuid : random
557
+ label :
558
+ mpp-format-string : ' {sd_fs_label}'
559
+ - type : org.osbuild.mkfs.ext4
560
+ devices :
561
+ device :
562
+ type : org.osbuild.loopback
563
+ options :
564
+ filename : disk.img
565
+ start :
566
+ mpp-format-int : ' {image_secex.layout['' boot'' ].start}'
567
+ size :
568
+ mpp-format-int : ' {image_secex.layout['' boot'' ].size}'
569
+ lock : true
570
+ options :
571
+ uuid :
572
+ mpp-format-string : ' {boot_fs_uuid}'
573
+ label :
574
+ mpp-format-string : ' {boot_fs_label}'
575
+ # Set manually the metadata_csum_seed ext4 option otherwise changing the
576
+ # filesystem UUID while it's mounted doesn't work. Can remove this when
577
+ # metadata_csum_seed is default in RHEL, which can be checked by looking
578
+ # in /etc/mke2fs.conf.
579
+ metadata_csum_seed : true
580
+ - type : org.osbuild.mkfs.xfs
581
+ devices :
582
+ device :
583
+ type : org.osbuild.loopback
584
+ options :
585
+ filename : disk.img
586
+ start :
587
+ mpp-format-int : ' {image_secex.layout['' root'' ].start}'
588
+ size :
589
+ mpp-format-int : ' {image_secex.layout['' root'' ].size}'
590
+ lock : true
591
+ options :
592
+ uuid :
593
+ mpp-format-string : ' {root_fs_uuid}'
594
+ label :
595
+ mpp-format-string : ' {root_fs_label}'
596
+ - type : org.osbuild.copy
597
+ inputs :
598
+ tree :
599
+ type : org.osbuild.tree
600
+ origin : org.osbuild.pipeline
601
+ references :
602
+ - name:tree
603
+ options :
604
+ paths :
605
+ - from : input://tree/
606
+ to : mount://root/
607
+ devices :
608
+ disk :
609
+ type : org.osbuild.loopback
610
+ options :
611
+ filename : disk.img
612
+ partscan : true
613
+ mounts :
614
+ - name : root
615
+ type : org.osbuild.xfs
616
+ source : disk
617
+ partition :
618
+ mpp-format-int : ' {image_secex.layout['' root'' ].partnum}'
619
+ target : /
620
+ - name : boot
621
+ type : org.osbuild.ext4
622
+ source : disk
623
+ partition :
624
+ mpp-format-int : ' {image_secex.layout['' boot'' ].partnum}'
625
+ target : /boot
626
+ - type : org.osbuild.chattr
627
+ options :
628
+ items :
629
+ mount://root/ :
630
+ immutable : true
631
+ devices :
632
+ disk :
633
+ type : org.osbuild.loopback
634
+ options :
635
+ filename : disk.img
636
+ partscan : true
637
+ mounts :
638
+ - name : root
639
+ type : org.osbuild.xfs
640
+ source : disk
641
+ partition :
642
+ mpp-format-int : ' {image_secex.layout['' root'' ].partnum}'
643
+ target : /
644
+ - name : ostree.deployment
645
+ type : org.osbuild.ostree.deployment
646
+ options :
647
+ source : mount
648
+ deployment :
649
+ default : true
478
650
- mpp-import-pipelines :
479
651
path : platform.metal.ipp.yaml
480
652
- mpp-import-pipelines :
0 commit comments