Add installation environment details app
This commit is contained in:
@@ -0,0 +1,7 @@
|
|||||||
|
from __future__ import absolute_import
|
||||||
|
|
||||||
|
from project_tools.api import register_tool
|
||||||
|
|
||||||
|
from .links import installation_details
|
||||||
|
|
||||||
|
register_tool(installation_details)
|
||||||
@@ -0,0 +1,7 @@
|
|||||||
|
from __future__ import absolute_import
|
||||||
|
|
||||||
|
from django.utils.translation import ugettext_lazy as _
|
||||||
|
|
||||||
|
from .permissions import PERMISSION_INSTALLATION_DETAILS
|
||||||
|
|
||||||
|
installation_details = {'text': _(u'installation details'), 'view': 'installation_details', 'icon': 'interface_preferences.png', 'permissions': [PERMISSION_INSTALLATION_DETAILS]}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
from django.db import models
|
||||||
|
|
||||||
|
# Create your models here.
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
from __future__ import absolute_import
|
||||||
|
|
||||||
|
from django.utils.translation import ugettext_lazy as _
|
||||||
|
|
||||||
|
from permissions.models import PermissionNamespace, Permission
|
||||||
|
|
||||||
|
namespace = PermissionNamespace('installation', _(u'Installation'))
|
||||||
|
PERMISSION_INSTALLATION_DETAILS = Permission.objects.register(namespace, 'installation_details', _(u'View installation environment details'))
|
||||||
Binary file not shown.
|
After Width: | Height: | Size: 1.9 KiB |
@@ -0,0 +1,5 @@
|
|||||||
|
from django.conf.urls.defaults import patterns, url
|
||||||
|
|
||||||
|
urlpatterns = patterns('installation.views',
|
||||||
|
url(r'^details/$', 'installation_details', (), 'installation_details'),
|
||||||
|
)
|
||||||
@@ -0,0 +1,37 @@
|
|||||||
|
from __future__ import absolute_import
|
||||||
|
|
||||||
|
import sys
|
||||||
|
import platform
|
||||||
|
|
||||||
|
from pbs import lsb_release, uname
|
||||||
|
|
||||||
|
from django.shortcuts import render_to_response
|
||||||
|
from django.template import RequestContext
|
||||||
|
from django.utils.translation import ugettext_lazy as _
|
||||||
|
from django.shortcuts import get_object_or_404
|
||||||
|
from django.contrib.contenttypes.models import ContentType
|
||||||
|
from django.db.models.loading import get_model
|
||||||
|
from django.http import Http404
|
||||||
|
from django.core.exceptions import PermissionDenied
|
||||||
|
|
||||||
|
from permissions.models import Permission
|
||||||
|
|
||||||
|
from .permissions import PERMISSION_INSTALLATION_DETAILS
|
||||||
|
|
||||||
|
def installation_details(request):
|
||||||
|
Permission.objects.check_permissions(request.user, [PERMISSION_INSTALLATION_DETAILS])
|
||||||
|
|
||||||
|
paragraphs = []
|
||||||
|
|
||||||
|
paragraphs.append(_(u'Distributor ID: %s') % lsb_release('-i','-s'))
|
||||||
|
paragraphs.append(_(u'Description: %s') % lsb_release('-d','-s'))
|
||||||
|
paragraphs.append(_(u'Release: %s') % lsb_release('-r','-s'))
|
||||||
|
paragraphs.append(_(u'Codename: %s') % lsb_release('-c','-s'))
|
||||||
|
paragraphs.append(_(u'System info: %s') % uname('-a'))
|
||||||
|
paragraphs.append(_(u'Platform: %s') % sys.platform)
|
||||||
|
paragraphs.append(_(u'Processor: %s') % platform.processor())
|
||||||
|
|
||||||
|
return render_to_response('generic_template.html', {
|
||||||
|
'paragraphs': paragraphs,
|
||||||
|
'title': _(u'Installation environment details')
|
||||||
|
}, context_instance=RequestContext(request))
|
||||||
@@ -14,16 +14,26 @@ As with the previous release bug fixes and minor feature were the focus
|
|||||||
for this release too. Long standing `issue #24`_ has been fixed and document
|
for this release too. Long standing `issue #24`_ has been fixed and document
|
||||||
check outs have been added too as per the feature request posted as `issue #26`_.
|
check outs have been added too as per the feature request posted as `issue #26`_.
|
||||||
|
|
||||||
|
#TODO: add improvements to history app info
|
||||||
|
|
||||||
What's new in Mayan EDMS v0.12.2
|
What's new in Mayan EDMS v0.12.2
|
||||||
================================
|
================================
|
||||||
|
|
||||||
Document check outs
|
Document check outs
|
||||||
~~~~~~~~~~~~~~~~~~~~~
|
~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
|
||||||
|
Installation environment app
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
|
||||||
Upgrading from a previous version
|
Upgrading from a previous version
|
||||||
=================================
|
=================================
|
||||||
|
|
||||||
|
Start off by adding the new requirements::
|
||||||
|
|
||||||
|
$ pip install -r requirements/production.txt
|
||||||
|
|
||||||
Migrate existing database schema with::
|
Migrate existing database schema with::
|
||||||
|
|
||||||
$ ./manage.py migrate checkouts
|
$ ./manage.py migrate checkouts
|
||||||
|
|||||||
@@ -17,3 +17,4 @@ South==0.7.5
|
|||||||
https://github.com/rosarior/python-gnupg/zipball/0.2.8
|
https://github.com/rosarior/python-gnupg/zipball/0.2.8
|
||||||
python-hkp==0.1.3
|
python-hkp==0.1.3
|
||||||
requests==0.13.1
|
requests==0.13.1
|
||||||
|
pbs==0.105
|
||||||
|
|||||||
@@ -175,6 +175,7 @@ INSTALLED_APPS = (
|
|||||||
'rest_api',
|
'rest_api',
|
||||||
'document_signatures',
|
'document_signatures',
|
||||||
'checkouts',
|
'checkouts',
|
||||||
|
'installation',
|
||||||
|
|
||||||
# Has to be last so the other apps can register it's signals
|
# Has to be last so the other apps can register it's signals
|
||||||
'signaler',
|
'signaler',
|
||||||
|
|||||||
@@ -33,6 +33,7 @@ urlpatterns = patterns('',
|
|||||||
(r'^documents/signatures/', include('document_signatures.urls')),
|
(r'^documents/signatures/', include('document_signatures.urls')),
|
||||||
(r'^feedback/', include('feedback.urls')),
|
(r'^feedback/', include('feedback.urls')),
|
||||||
(r'^checkouts/', include('checkouts.urls')),
|
(r'^checkouts/', include('checkouts.urls')),
|
||||||
|
(r'^installation/', include('installation.urls')),
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user