File: 01-module-configuration

package info (click to toggle)
python-diskimage-builder 3.37.0-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 5,572 kB
  • sloc: sh: 7,380; python: 6,444; makefile: 37
file content (24 lines) | stat: -rwxr-xr-x 525 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#!/bin/bash
#
# When building RHEL overcloud images, certain modules may be preferred
# or even required.
#
# For example, container-tools:2.0 is notably a requirement when running
# the Train releases on RHEL 8.2.
#

if [ "${DIB_DEBUG_TRACE:-0}" -gt 0 ]; then
    set -x
fi

set -eu
set -o pipefail

export DIB_DNF_MODULE_STREAMS=${DIB_DNF_MODULE_STREAMS:-}

if [ "${YUM}" == "dnf" ]; then
    for m in ${DIB_DNF_MODULE_STREAMS}; do
        ${YUM} -y module disable ${m/:*/}
        ${YUM} -y module enable ${m}
    done
fi