Re: Request for feedback: Differentiate server/desktop ISOs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Folks,

On Fri, Jun 8, 2018 at 5:07 PM, Fabiano Fidêncio <fabiano@xxxxxxxxxxxx> wrote:
> People,
>
> I've talked to Felipe Borges a few days ago and he told me one thing
> he'd need, from GNOME Boxes perspective, is whether an ISO is intended
> to be a "Desktop" or a "Server" ISO.
>
> IMO supporting this on libosinfo should be fairly easy, but I'd like
> to check with all you whether my approach seems okay, before start to
> implement it.
>
> A simple "flavour" field in the <media> entry would do the job. We can
> have an enum as "desktop", "server" and "default". The "default" would
> be selected in case anything is specified and would be treated as
> "it's not specific a desktop neither a server ISO".
>
> The idea behind this is to simple allow apps as GNOME Boxes to sort
> how they'd present the medias to the users according to what the user
> needs.
>
> Is this approach okay? May I start implementing it?
>
> Best Regards,
> --
> Fabiano Fidêncio

I've started playing with this and the initial idea is:
```
[fidencio@machado osinfo-db]$ git diff HEAD~1
diff --git a/data/schema/osinfo.rng.in b/data/schema/osinfo.rng.in
index 843519d..a8096a6 100644
--- a/data/schema/osinfo.rng.in
+++ b/data/schema/osinfo.rng.in
@@ -360,6 +360,11 @@
           <ref name='bool'/>
         </attribute>
       </optional>
+      <optional>
+        <attribute name='flavour'>
+          <ref name='flavours'/>
+        </attribute>
+      </optional>
       <interleave>
         <optional>
           <element name='variant'>
@@ -437,6 +442,11 @@
       <attribute name='arch'>
         <ref name='archnames'/>
       </attribute>
+      <optional>
+        <attribute name='flavour'>
+          <ref name='flavours'/>
+        </attribute>
+      </optional>
       <interleave>
         <optional>
           <element name='variant'>
@@ -823,4 +833,10 @@
       </data>
     </element>
   </define>
+
+  <define name='flavours'>
+    <data type="string">
+      <param name="pattern">desktop|server|generic</param>
+    </data>
+  </define>
 </grammar>
```

It'd look as something like:
```
<media arch="x86_64" live="true" flavour="desktop">
  <variant id="workstation"/>
  <url>https://download.fedoraproject.org/pub/fedora/linux/releases/28/Workstation/x86_64
   /iso/Fedora-Workstation-Live-x86_64-28-1.1.iso</url>
  <iso>
    <volume-id>Fedora-WS-Live-28.*</volume-id>
    <system-id>LINUX</system-id>
  </iso>
  <kernel>isolinux/vmlinuz</kernel>
  <initrd>isolinux/initrd.img</initrd>
</media>
`
<tree arch="x86_64" flavour="server">
  <url>https://download.fedoraproject.org/pub/fedora/linux/releases/28/Server/x86_64/os/<
   /url>
  <variant id="server"/>
  <treeinfo>
    <family>Fedora</family>
    <version>28</version>
    <arch>x86_64</arch>
  </treeinfo>
</tree>
```

I'm keeping "generic" as something that can be used for both desktop &
server. For now I don't see a reason for adding "none" or any other
kind of flavour as it can be easily expanded according to our needs
later on.

So, is that okay for all the parts that commented so far (Marc-André, Felipe)?
-- 
Fabiano Fidêncio

_______________________________________________
Libosinfo mailing list
Libosinfo@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libosinfo




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Fedora Users]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]

  Powered by Linux