from django.urls import path from django.views.generic import TemplateView from devops_kubernetes.k8s import self_login_request from workload import views urlpatterns = [ path('deployment/', self_login_request( TemplateView.as_view(template_name='workload/deployment.html')), name='deployment'), path('deployment_create/', self_login_request( TemplateView.as_view( template_name='workload/deployment_create.html')), name='deployment_create'), path('deployment_details/', self_login_request(views.DeploymentDetailsView.as_view()), name='deployment_details'), path('replicaset_api', views.ReplicasetApiView.as_view(), name='replicaset_api'), path('daemonsets/', self_login_request( TemplateView.as_view(template_name='workload/daemonsets.html')), name='daemonsets'), path('pods/', self_login_request( TemplateView.as_view(template_name='workload/pods.html')), name='pods'), path('pods_log/', self_login_request(views.PodsLogView.as_view()),
from django.urls import path from django.views.generic import TemplateView from devops_kubernetes.k8s import self_login_request from storage import views urlpatterns = [ path('secrets/', self_login_request( TemplateView.as_view(template_name="storage/secrets.html")), name='secret'), path('secrets_api/', views.SecretsApiView.as_view(), name='secrets_api'), path('persistentvolumeclaims_api/', views.PersistentVolumeClaimsApiView.as_view(), name='persistentvolumeclaims_api'), path('persistentvolumeclaims/', self_login_request( TemplateView.as_view( template_name='storage/persistentvolumeclaims.html')), name='persistentvolumeclaims'), path('configmaps/', self_login_request( TemplateView.as_view(template_name='storage/configmaps.html')), name='configmaps'), path('configmaps_api/', views.ConfigMapsApiView.as_view(), name='configmaps_api') ]
from django.urls import path from django.views.generic import TemplateView from devops_kubernetes.k8s import self_login_request from load_balancer import views urlpatterns = [ path('services/', self_login_request(TemplateView.as_view(template_name='loadbalancer/service.html')), name='services'), path('services_api/', views.ServicesApiView.as_view(), name='services_api'), path('ingress/', self_login_request(TemplateView.as_view(template_name='loadbalancer/ingress.html')), name='ingress'), path('ingress_api', views.IngressApiView.as_view(), name='ingress_api') ]
from django.urls import path from django.views.generic import TemplateView from devops_kubernetes.k8s import self_login_request from kube.views import NamespaceApiView, NodesApiView, PersistentVolunmeApiView, NodeDetailsView urlpatterns = [ path('nodes/', self_login_request( TemplateView.as_view(template_name="kube/nodes.html")), name='nodes'), path('node_details/', NodeDetailsView.as_view(), name='node_details'), path('namespaces/', self_login_request( TemplateView.as_view(template_name="kube/namespaces.html")), name='namespaces'), path( 'persistentvolunmes/', self_login_request( TemplateView.as_view(template_name='kube/persistentvolumes.html')), name='persistentvolunmes'), path('persistentvolunmes_create', self_login_request( TemplateView.as_view( template_name='kube/persistentvolumes_create.html')), name='persistentvolunmes_create'), path('namespace_api/', NamespaceApiView.as_view(), name='namespace_api'), path('nodes_api/', NodesApiView.as_view(), name='nodes_api'), path('persistentvolunmes_api/', PersistentVolunmeApiView.as_view(),
https://docs.djangoproject.com/en/3.1/topics/http/urls/ Examples: Function views 1. Add an import: from my_app import views 2. Add a URL to urlpatterns: path('', views.home, name='home') Class-based views 1. Add an import: from other_app.views import Home 2. Add a URL to urlpatterns: path('', Home.as_view(), name='home') Including another URLconf 1. Import the include() function: from django.urls import include, path 2. Add a URL to urlpatterns: path('blog/', include('blog.urls')) """ # from django.contrib import admin from django.urls import path, include from django.views.generic import TemplateView from django.views.generic.base import RedirectView from devops_kubernetes.k8s import self_login_request urlpatterns = [ path('', self_login_request( TemplateView.as_view(template_name="dashboard/index.html")), name='index'), path('dashboard/', include('dashboard.urls')), path('kube/', include('kube.urls')), path('load_balancer/', include('load_balancer.urls')), path('storage/', include('storage.urls')), path('workload/', include('workload.urls')), ]