debian-koji/koji
David Abdurachmanov 7e1809bafd Add support for tag/target macros for Mageia
Discussions with Son_Goku (from Mageia) on IRC revealed that they need
per tag/target macro support in Koji. We store tag macros in 'Extra Options'
and macro has to start with '%'.

Example:

    % koji taginfo f29
    Tag: f29 [11]
    Arches: riscv64
    Groups:
    Required permission: 'admin'
    Tag options:
      %mymacro : 'value123'
      %packager : 'Fedora Project RISC-V'
      mock.package_manager : 'dnf'
    [..]

Tag macros can be added using koji edit-tag.

The tag macros are allowed to overwrite macros set in koji.genMockConfig.
For example, %packager is set in koji.genMockConfig by default. The mock
configuration generated by kojid was:

    [..]
    config_opts['macros']['%_host'] = 'riscv64-koji-linux-gnu'
    config_opts['macros']['%mymacro'] = 'value123'
    config_opts['macros']['%_host_cpu'] = 'riscv64'
    config_opts['macros']['%vendor'] = 'Fedora Project'
    config_opts['macros']['%distribution'] = 'Fedora Project'
    config_opts['macros']['%_topdir'] = '/builddir/build'
    config_opts['macros']['%_rpmfilename'] = '%%{NAME}-%%{VERSION}-%%{RELEASE}.%%{ARCH}.rpm'
    config_opts['macros']['%packager'] = 'Fedora Project RISC-V'
    [..]

This two-line change was tested on Fedora RISC-V koji instance.

Signed-off-by: David Abdurachmanov <david.abdurachmanov@gmail.com>
2019-07-15 10:10:29 -04:00
..
__init__.py Add support for tag/target macros for Mageia 2019-07-15 10:10:29 -04:00
arch.py note origin of koji.arch and chmod -x the lib 2019-02-12 16:24:13 -05:00
auth.py use base64.b64decode 2019-03-04 09:28:39 -05:00
context.py note origin of koji.arch and chmod -x the lib 2019-02-12 16:24:13 -05:00
daemon.py tweak rank calculation 2019-04-09 15:40:00 -04:00
db.py fix import 2019-02-05 15:49:54 +01:00
Makefile misc changes for build and test 2019-01-28 08:46:11 -05:00
plugin.py python-modernize -f libmodernize.fixes.fix_import 2018-07-11 17:37:39 -04:00
policy.py don't fail on missing field in base policy tests 2018-11-28 09:01:20 +01:00
rpmdiff.py rpm builds 2019-02-12 16:06:00 -05:00
server.py drop mod_python support 2017-07-06 14:04:19 +02:00
tasks.py rename source_srpm to srpm 2019-06-26 09:06:48 +02:00
util.py new base64 helper functions 2019-03-04 09:28:39 -05:00
xmlrpcplus.py fix xmlrpc encoding error 2019-02-12 16:09:19 -05:00