[Starlingx-discuss] Build installer instructions

Penney, Don Don.Penney at windriver.com
Tue Sep 18 01:23:35 UTC 2018

I made the README file as a way to track changes I'd make to the installer over the last few years. I'd considered automating it, but never really had a need, so thank you for doing that. I added comments to a recent review adding lz4 to the installer, identifying pkgs that should be dropped, but haven't really looked through the make-installer-images.sh script yet. One reason I just did it manually was to ensure everything went smoothly, so I could catch any oddities along the way. There'd need to be a lot of error checking, to ensure the installer is updated safely.

The idea of using a symlink is good. I'd suggest we include it in the stx/downloads dir. It could be created by the populate_downloads.sh script as an additional step, maybe with an environment variable or argument to point to a particular location, so there's no change in developer process (aside from maybe setting a new var)

-----Original Message-----
From: Hu, Yong [mailto:yong.hu at intel.com] 
Sent: Monday, September 17, 2018 9:07 PM
To: Penney, Don; Cordoba Malibran, Erich; starlingx-discuss at lists.starlingx.io
Subject: Re: [Starlingx-discuss] Build installer instructions

Originally here is a readme to describe how to make/update installer images: 
Later I made 2 scripts to automate the process descripted in that readme:
While, due to the hard-coding (referring to the mirror folder for a specified version, for example, /import/mirrors/CentOS/tis-installer/initrd.img-stx-0.4) in "~/cgcs-root/stx/stx-metal/installer/pxe-network-installer/centos/build_srpm.data", we have to manually edit this file every time.

So, I would agree Don's suggest that we use the symlinks to the latest version to get rid of versions attached. 
Further, instead of using the hard-coded "/import/mirror/CentOS/tis-installer", 
we can use a relative directory, something like "~/cgcs-root/cgcs-centos-repo/tis-installer".
 Here "tis-installer" could be a symbol link to the actual place where the init images are placed.

´╗┐On 18/09/2018, 12:41 AM, "Penney, Don" <Don.Penney at windriver.com> wrote:

    It's good to note that if you've already got installer images generated (ie. on a shared system, in /import/mirror/CentOS/tis-installer), you don't need to run "build-pkgs --installer". So presumably, this would not be part of a general designer workflow.
    Historically, we upversioned these images whenever they were updated, but this introduces some challenges under Starling-X. It may make sense to drop the version number from the images as referenced in the pxe-network-installer package build, essentially treating it as a .latest version. Individuals or groups could then manage their own installer version history as they see fit, ie. build images with 0.1, 0.2, 0.3, with symlinks to the latest perhaps. If these images aren't being hosted somewhere, if individuals/groups are generating their own, then the versioning shouldn't be in the build files.
    -----Original Message-----
    From: Cordoba Malibran, Erich [mailto:erich.cordoba.malibran at intel.com] 
    Sent: Monday, September 17, 2018 12:12 PM
    To: starlingx-discuss at lists.starlingx.io
    Subject: [Starlingx-discuss] Build installer instructions
    I would like to share/discuss the instructions to generate the
    installer before are publish into the wiki. I couldn't find a previous
    version of these instructions, probably I confused with this warning
    from the download_mirror.sh[0]. The update-pxe-network-installer script
    follows the steps detailed here[1].
    Build installer
    To get your StarlingX ISO ready to use, you will need to create the
    init files that will be used to boot the ISO as well to boot additional
    controllers and compute nodes.
    Once you had run `build-iso`, run:
    build-pkgs --installer
    This will build `rpm` and `anaconda` packages. Then run:
    The update-pxe-network-installer` covers the steps detailed in
    `$MY_REPO/stx/stx-metal/installer/initrd/README`. This script will
    create three files on `/localdisk/loadbuild/<user>/<project>/pxe-
    Then, rename them to:
    There are two ways to use these files:
    1. Store the files in the '/import/mirror/CentOS/tis-installer/`
    folder  for future use.
    2. Store it in an arbitrary location and modify the `$MY_REPO/stx/stx-
    metal/installer/pxe-network-installer/centos/build_srpm.data` file to
    point to these files.
    Now, the `pxe-network-installer` package needs to be recreated and the
    ISO regenerated.
    build-pkgs --clean pxe-network-installer
    build-pkgs pxe-network-installer
    Now your ISO should be able to boot. 
    Updating these files is not a common tasks, it is recommended only do
    it if the kernel version is upgraded or new kernel modules are added.
    End of documentation
    [0] http://git.starlingx.io/cgit/stx-tools/tree/centos-mirror-tools/download_mirror.sh#n264
    [1] http://git.starlingx.io/cgit/stx-metal/tree/installer/initrd/README
    Starlingx-discuss mailing list
    Starlingx-discuss at lists.starlingx.io
    Starlingx-discuss mailing list
    Starlingx-discuss at lists.starlingx.io

More information about the Starlingx-discuss mailing list