diff --git a/awx/api/views.py b/awx/api/views.py index 9247cfb149..06170a02a8 100644 --- a/awx/api/views.py +++ b/awx/api/views.py @@ -1474,6 +1474,7 @@ class JobTemplateDetail(RetrieveUpdateDestroyAPIView): class JobTemplateLaunch(GenericAPIView): model = JobTemplate + is_job_start = True def get(self, request, *args, **kwargs): obj = self.get_object() diff --git a/awx/main/access.py b/awx/main/access.py index bae789f871..a39aaf836d 100644 --- a/awx/main/access.py +++ b/awx/main/access.py @@ -978,6 +978,7 @@ class JobTemplateAccess(BaseAccess): Q(user=self.user) | Q(team__users__in=[self.user]), inventory=obj.inventory, project=obj.project, + active=True, permission_type__in=[PERM_JOBTEMPLATE_CREATE, PERM_INVENTORY_CHECK, PERM_INVENTORY_DEPLOY], )