lifecycle: run bootstrap tasks inline when using automated install
Signed-off-by: Jens Langhammer <jens.langhammer@beryju.org>
This commit is contained in:
		
							
								
								
									
										13
									
								
								authentik/core/management/commands/bootstrap_tasks.py
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										13
									
								
								authentik/core/management/commands/bootstrap_tasks.py
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,13 @@ | ||||
| """Run bootstrap tasks""" | ||||
| from django.core.management.base import BaseCommand | ||||
|  | ||||
| from authentik.root.celery import _get_startup_tasks | ||||
|  | ||||
|  | ||||
| class Command(BaseCommand):  # pragma: no cover | ||||
|     """Run bootstrap tasks to ensure certain objects are created""" | ||||
|  | ||||
|     def handle(self, **options): | ||||
|         tasks = _get_startup_tasks() | ||||
|         for task in tasks: | ||||
|             task() | ||||
		Reference in New Issue
	
	Block a user
	 Jens Langhammer
					Jens Langhammer