Compare commits
	
		
			No commits in common. "main" and "feat/handle-pending-events" have entirely different histories.
		
	
	
		
			main
			...
			feat/handl
		
	
		
							
								
								
									
										4
									
								
								Makefile
									
									
									
									
									
								
							
							
						
						
									
										4
									
								
								Makefile
									
									
									
									
									
								
							| @ -14,10 +14,10 @@ django: | |||||||
| 	docker build . -t mumui:local | 	docker build . -t mumui:local | ||||||
| 
 | 
 | ||||||
| pushpin-local: | pushpin-local: | ||||||
| 	cd pushpin && docker build . -t pushpin:mumui | 	cd pushpin && docker build . -t pushpin:local | ||||||
| 
 | 
 | ||||||
| nginx-local: | nginx-local: | ||||||
| 	cd nginx && docker build . -t nginx:mumui | 	cd nginx && docker build . -t nginx:local | ||||||
| 
 | 
 | ||||||
| build: | build: | ||||||
| 	$(MAKE) pushpin-local | 	$(MAKE) pushpin-local | ||||||
|  | |||||||
| @ -4,7 +4,7 @@ from django.urls import path, include | |||||||
| from deployment.views import index, create, details, deploy, abort | from deployment.views import index, create, details, deploy, abort | ||||||
| 
 | 
 | ||||||
| urlpatterns = [ | urlpatterns = [ | ||||||
|     path("", index, name="deployments"), |     path("", index, name="deployment"), | ||||||
|     path("create", create, name="deployment-create"), |     path("create", create, name="deployment-create"), | ||||||
|     path("<uuid:deployment_id>", details, name="deployment-details"), |     path("<uuid:deployment_id>", details, name="deployment-details"), | ||||||
|     path("<uuid:deployment_id>/deploy", deploy, name="deployment-launch"), |     path("<uuid:deployment_id>/deploy", deploy, name="deployment-launch"), | ||||||
| @ -13,7 +13,7 @@ urlpatterns = [ | |||||||
|         "events/<user_id>/", |         "events/<user_id>/", | ||||||
|         include(django_eventstream.urls), |         include(django_eventstream.urls), | ||||||
|         {"format-channels": ["deployment_{user_id}"]}, |         {"format-channels": ["deployment_{user_id}"]}, | ||||||
|         name="deployments-events", |         name="deployment-events", | ||||||
|     ), |     ), | ||||||
|     path( |     path( | ||||||
|         "events/<user_id>/<deployment_id>/", |         "events/<user_id>/<deployment_id>/", | ||||||
|  | |||||||
| @ -71,9 +71,9 @@ def deploy(request, deployment_id): | |||||||
|         launch_deploy.delay(deployment_id) |         launch_deploy.delay(deployment_id) | ||||||
| 
 | 
 | ||||||
|     if page := request.GET.get("page", ""): |     if page := request.GET.get("page", ""): | ||||||
|         return HttpResponseRedirect(f"/deployments?page={page}") |         return HttpResponseRedirect(f"/deployment?page={page}") | ||||||
| 
 | 
 | ||||||
|     return HttpResponseRedirect("/deployments") |     return HttpResponseRedirect("/deployment") | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| def abort(request, deployment_id): | def abort(request, deployment_id): | ||||||
| @ -95,7 +95,7 @@ def abort(request, deployment_id): | |||||||
|         Event.send_details(deployment, progress) |         Event.send_details(deployment, progress) | ||||||
|         Event.send(deployment) |         Event.send(deployment) | ||||||
| 
 | 
 | ||||||
|     return HttpResponseRedirect(f"/deployments/{deployment.id}") |     return HttpResponseRedirect(f"/deployment/{deployment.id}") | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| def details(request, deployment_id): | def details(request, deployment_id): | ||||||
| @ -116,7 +116,7 @@ def details(request, deployment_id): | |||||||
|             deployment.delete() |             deployment.delete() | ||||||
|         except Exception as e: |         except Exception as e: | ||||||
|             return HttpResponseServerError(e) |             return HttpResponseServerError(e) | ||||||
|         return HttpResponseRedirect("/deployments") |         return HttpResponseRedirect("/deployment") | ||||||
| 
 | 
 | ||||||
|     return render( |     return render( | ||||||
|         request, |         request, | ||||||
| @ -145,4 +145,4 @@ def create(request): | |||||||
|         except Exception as e: |         except Exception as e: | ||||||
|             return HttpResponseServerError(e) |             return HttpResponseServerError(e) | ||||||
| 
 | 
 | ||||||
|     return HttpResponseRedirect("/deployments") |     return HttpResponseRedirect("/deployment") | ||||||
|  | |||||||
| @ -2,15 +2,15 @@ version: '3' | |||||||
| services: | services: | ||||||
|   redis: |   redis: | ||||||
|     image: redis/redis-stack-server:latest |     image: redis/redis-stack-server:latest | ||||||
|     container_name: redis-mumui |     container_name: redis | ||||||
|     networks: |     networks: | ||||||
|       - mumui_network |       - mumui_network | ||||||
|     volumes: |     volumes: | ||||||
|       - redis_data:/data |       - redis_data:/data | ||||||
| 
 | 
 | ||||||
|   pushpin: |   pushpin: | ||||||
|     image: pushpin:mumui |     image: pushpin:local | ||||||
|     container_name: pushpin-mumui |     container_name: pushpin | ||||||
|     networks: |     networks: | ||||||
|       - mumui_network |       - mumui_network | ||||||
|     depends_on: |     depends_on: | ||||||
| @ -18,7 +18,7 @@ services: | |||||||
| 
 | 
 | ||||||
|   postgres: |   postgres: | ||||||
|     image: postgres:latest |     image: postgres:latest | ||||||
|     container_name: postgres-mumui |     container_name: postgres | ||||||
|     env_file: |     env_file: | ||||||
|       - .env |       - .env | ||||||
|     networks: |     networks: | ||||||
| @ -39,8 +39,8 @@ services: | |||||||
|       - postgres |       - postgres | ||||||
| 
 | 
 | ||||||
|   nginx: |   nginx: | ||||||
|     image: nginx:mumui |     image: nginx:local | ||||||
|     container_name: nginx-mumui |     container_name: nginx | ||||||
|     networks: |     networks: | ||||||
|       - mumui_network |       - mumui_network | ||||||
|     volumes: |     volumes: | ||||||
|  | |||||||
| @ -21,6 +21,6 @@ from django.views.generic.base import TemplateView | |||||||
| urlpatterns = [ | urlpatterns = [ | ||||||
|     path("admin/", admin.site.urls), |     path("admin/", admin.site.urls), | ||||||
|     path("accounts/", include("django.contrib.auth.urls")), |     path("accounts/", include("django.contrib.auth.urls")), | ||||||
|     path("deployments/", include("deployment.urls")), |     path("deployment/", include("deployment.urls")), | ||||||
|     path("", TemplateView.as_view(template_name="home.html"), name="home"), |     path("", TemplateView.as_view(template_name="home.html"), name="home"), | ||||||
| ] | ] | ||||||
|  | |||||||
| @ -92,7 +92,7 @@ | |||||||
|     {% endif %} |     {% endif %} | ||||||
|     <script> |     <script> | ||||||
|         function goBack() { |         function goBack() { | ||||||
|             window.location={% url 'deployments' %}; |             window.location={% url 'deployment' %}; | ||||||
|         } |         } | ||||||
|     </script> |     </script> | ||||||
| {% endblock %} | {% endblock %} | ||||||
| @ -15,7 +15,7 @@ | |||||||
|                         <a class="nav-link" href="/">Home</a> |                         <a class="nav-link" href="/">Home</a> | ||||||
|                     </li> |                     </li> | ||||||
|                     <li class="nav-item"> |                     <li class="nav-item"> | ||||||
|                         <a href="{% url 'deployments' %}" class="nav-link">Deployments</a></li> |                         <a href="{% url 'deployment' %}" class="nav-link">Deployments</a></li> | ||||||
|                     </li> |                     </li> | ||||||
|                     <li class="nav-item"> |                     <li class="nav-item"> | ||||||
|                         <a class="nav-link" href="#">About</a></li> |                         <a class="nav-link" href="#">About</a></li> | ||||||
|  | |||||||
| @ -13,7 +13,7 @@ | |||||||
|             <div class="row justify-content-md-center"> |             <div class="row justify-content-md-center"> | ||||||
|                 <div class="col-lg-6 col-md-8 col-sm-8"> |                 <div class="col-lg-6 col-md-8 col-sm-8"> | ||||||
|                     <div style="text-align: center;">Forget, i don't care... Please go on  |                     <div style="text-align: center;">Forget, i don't care... Please go on  | ||||||
|                         <a href="{% url 'deployments' %}">Deployments</a>  |                         <a href="{% url 'deployment' %}">Deployments</a>  | ||||||
|                         and enjoy the life ! |                         and enjoy the life ! | ||||||
|                     </div> |                     </div> | ||||||
|                 </div> |                 </div> | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user