diff options
Diffstat (limited to 'elivepatch_server/resources/dispatcher.py')
-rw-r--r-- | elivepatch_server/resources/dispatcher.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/elivepatch_server/resources/dispatcher.py b/elivepatch_server/resources/dispatcher.py index d470cd7..70a62d7 100644 --- a/elivepatch_server/resources/dispatcher.py +++ b/elivepatch_server/resources/dispatcher.py @@ -72,7 +72,9 @@ class BuildLivePatch(Resource): if args['KernelVersion']: print("build livepatch: " + str(args)) # check vmlinux presence if not rebuild the kernel - lpatch.get_kernel_sources(args['UUID'], args['KernelVersion']) + kernel_sources_status = lpatch.get_kernel_sources(args['UUID'], args['KernelVersion']) + if not kernel_sources_status: + return make_response(jsonify({'message': 'gentoo-sources not available'}), 403) lpatch.build_livepatch(args['UUID'], 'vmlinux') pack = { 'id': packs['id'] + 1, |