Commit Graph

3044 Commits

Author SHA1 Message Date
Owen W. Taylor
433ddce11c MockModuleBuild: Avoid accumulating blank lines around yum.conf
Every time we read-and-rewrote mock.cfg, we'd add another set of
blank lines around the yum configuration.
2023-03-16 13:19:03 +00:00
Owen W. Taylor
0a8160a91c MockModuleBuilder: add missing kwarg to tag_artifacts 2023-03-16 13:19:03 +00:00
Owen W. Taylor
9c1f0edd0e MockModuleBuilder: fix a typo in a comment 2023-03-16 13:19:03 +00:00
Owen W. Taylor
14597fb1a7 MockModuleBuilder: don't accidentally remove log files from other threads
The _purge_useless_log_files() method, if run at the wrong time, would
remove log files that other threads were still creating.
2023-03-16 13:19:03 +00:00
Brendan Reilly
710e610850 Merge #1770 Pass koji_tag to get_built_rpms_in_module_build() 2023-03-15 17:54:28 +00:00
Owen W. Taylor
35086174ba Pass koji_tag to get_built_rpms_in_module_build()
For local builds, required modules are not necessarily in the local
database, so the method of looking up the build to find the koji tag
doesn't work reliably. However, the caller has the koji_tag - so just
pass it in.
2023-03-15 17:53:38 +00:00
Brendan Reilly
e974aca48e Merge #1765 Add a framework for special console handling of messages 2023-03-15 17:16:56 +00:00
Owen W. Taylor
646b0590ee MBSConsoleHandler: show status of ongoing repository downloads
When downloading files from Koji to make a local repository, display
a temporary status of which files are being displayed to the console
appended after any log messages. Updates are done by erasing the status
that was written, adding a log message, then writing the status again.
2023-03-15 17:16:24 +00:00
Owen W. Taylor
f5100609aa Filter console output through a special handler
When running in local mode, add a special handler that filters log
messages to the console to produce attractive output. Implemented
behaviors include:

 - INFO level messages are only displayed if done through
   MBSLogger.console() rather than MBSLogger.info().
 - Timestamps and thread names are omitted unless the local build
   is started with the -d option
 - Warning/error messages have the level highlighted in red
 - Special handling can be added to log messages, initially:
    - Long running operations can be displayed to the console as
      "Doing foo ... <pause>done"
2023-03-15 17:16:24 +00:00
Brendan Reilly
ae004e86a0 Merge #1766 batches.py: Fix handling of "changed-and-after" 2023-03-07 21:10:16 +00:00
Owen W. Taylor
4f3c60c808 batches.py: Fix handling of "changed-and-after"
all_reused_in_prev_batch should only check components in the previous
batch, not components in all batches including future batches. This
was accidentally regressed by some code refactoring in c36bd7ebac.
2023-03-07 21:08:55 +00:00
Brendan Reilly
a518bee114 Merge #1764 local builds: improve handling of build.log 2023-03-07 18:36:43 +00:00
Owen W. Taylor
a276a33969 LocalBuildConfiguration: log to <build_dir>/build.log not <build_dir>/build-2.log
Since the build log is already within the a build-specific directory, we
don't need to put the build ID (which ends up always being "2") into the
build log filename.
2023-03-07 18:33:30 +00:00
Owen W. Taylor
1c8e2a07d8 Local builds: buffer up initial logs and replay to the module build file
Logging during a build that occurs before the build directory is created
used to be logged to the console, but not retained in the build log
file. This made referring to the build log file confusing. Solve this
by buffering logs in memory until the log file is created and replaying
them.

A little bit of hackery is needed to avoid saving dangling references to
libsolv objects.
2023-03-07 18:33:30 +00:00
Brendan Reilly
295847e672 Merge #1780 Allow krb ccache to be configured 2023-02-27 17:59:35 +00:00
jmicanek
8709c632b0 Allow krb ccache to be configured
Access to the kernel keyring may be restricted in containers. Allow users to specify non keyring ccache for kerberos.
2023-02-27 18:35:53 +01:00
Brendan Reilly
f58e07df2a Merge #1778 switch to using gssapi_login for koji 2023-02-22 15:41:26 +00:00
Mike McLean
f6dcf6c346 switch to using gssapi_login for koji
Fixes https://pagure.io/fm-orchestrator/issue/1777

koji recently dropped this old call
https://pagure.io/koji/pull-request/3599

Previously, koji was ignoring the ctx arg and wrapping gssapi_login,
so this change is completely equivalent to the old behavior.
2023-02-22 10:22:53 -05:00
Brendan Reilly
c76f541bca Merge #1762 Increase test coverage of code used in local builds: 2023-02-21 16:49:15 +00:00
Owen W. Taylor
88c138084c Test more code paths in create_local_repo_from_koji_tag 2023-02-21 16:47:24 +00:00
Owen W. Taylor
8ab293dc9e test_start_next_batch_build_repo_building: actually try to start the batch 2023-02-21 16:47:24 +00:00
Brendan Reilly
c76bc32380 Merge #1761 local.py: Pass state to modules_failed_handler() correctly 2023-02-16 18:33:20 +00:00
Owen W. Taylor
2e373d2fe0 local.py: Pass state to modules_failed_handler() correctly
Handlers take a state integer rather than a string
2023-02-16 18:10:00 +00:00
Brendan Reilly
4e4fe47e87 Merge #1681 Improve handling of configuration file 2023-02-15 19:16:56 +00:00
Owen W. Taylor
b6c11f83d8 Improve handling of configuration file
* Allow MBS_CONFIG_FILE="" to entirely suppress loading any configuration
   file (useful for running tests and avoiding loading a system-wide
   configuration file.)
 * When loading the configuration file:
   * If the default configuration file path doesn't exist, silently fall back
     to the default configuration
   * For any other OSError, print the exact error
   * Let any other exception throw through, to allow people to debug their
     configuration file
2023-01-23 18:39:25 -05:00
Brendan Reilly
ab41f01209 Merge #1769 Remove unnecessary requirements 2023-01-06 18:14:42 +00:00
Brendan Reilly
f4625e56c3 Remove unnecessary requirements 2022-12-21 10:16:50 -05:00
Brendan Reilly
75abfad341 Merge #1767 Use click instead of flask script 2022-12-20 20:27:50 +00:00
Brendan Reilly
543e2a013f Match dockerfile deps with Fedora requirements 2022-12-20 11:44:47 -05:00
Brendan Reilly
6b43180229 Replace deprecated getargspec with getfullargspec 2022-12-19 13:45:46 -05:00
Brendan Reilly
ac2a338786 Add workaround for upgradedb entrypoint 2022-12-15 15:11:47 -05:00
Brendan Reilly
60692b0c6a Fix C3I tests 2022-12-15 10:19:35 -05:00
Brendan Reilly
f12fc9c969 Use click instead of flask script 2022-12-13 13:31:56 -05:00
Brendan Reilly
e4dba5e242 Release 3.8.0 3.8.0 2022-12-07 13:06:00 -05:00
Mike McLean
407b93f9af Merge #1760 use branch name as default component ref 2022-11-22 14:40:09 +00:00
Mike McLean
a014f20f15 handle default_ref recursively for module components 2022-11-21 15:17:30 -05:00
Mike McLean
9287297943 fix unit test 2022-11-08 19:23:33 -05:00
Mike McLean
46f4f449a8 partial work 2022-11-08 14:39:24 -05:00
Mike McLean
1236fed8b8 bugfix 2022-11-08 14:39:24 -05:00
Mike McLean
79648cf188 use submitted branch as default ref for components 2022-11-08 14:39:24 -05:00
Mike McLean
d1180871de fix unit test 2022-11-08 14:39:24 -05:00
Mike McLean
879e3befae combine code for noting params in xmd 2022-11-08 14:39:24 -05:00
Brendan Reilly
1ff8f66c02 Merge #1743 Allow siblings in the garbage state 2022-11-03 14:56:39 +00:00
Brendan Reilly
9460b56f69 Release 3.7.0 3.7.0 2022-10-28 13:48:16 -04:00
Brendan Reilly
84b4199e7a Release 3.7.0 2022-10-28 13:37:53 -04:00
Brendan Reilly
bcb62004ca Merge #1747 Architecture limited module builds fail to build locally 2022-10-11 13:33:55 +00:00
Brendan Reilly
18cbd2d022 Merge #1758 Add delay to missed new repo check 2022-09-21 16:44:07 +00:00
Brendan Reilly
79e3eae43e Add delay to missed new repo check 2022-09-02 12:01:34 -04:00
Mike McLean
7f6f58401d Merge #1757 install mbs in the container images using pip 2022-08-24 21:54:07 +00:00
Mike Bonnet
ecf7da7aa3 install mbs in the container images using pip
Removing the requirement to build the rpm as part of the image build simplifies the
build process and reduces fragility introduced by trying to keep the rpm build and
image builds in sync.
2022-08-24 12:03:08 -07:00