Skip to content

Commit

Permalink
fix asset update bug
Browse files Browse the repository at this point in the history
  • Loading branch information
ibuler committed Dec 15, 2015
1 parent 9c0825c commit e817715
Show file tree
Hide file tree
Showing 6 changed files with 160 additions and 781 deletions.
2 changes: 1 addition & 1 deletion jasset/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -451,7 +451,7 @@ def asset_update(request):
return HttpResponseRedirect(reverse('asset_detail')+'?id=%s' % asset_id)
else:
asset_ansible_update([asset], name)
return HttpResponseRedirect(reverse('asset_detail')+'/?id=%s' % asset_id)
return HttpResponseRedirect(reverse('asset_detail')+'?id=%s' % asset_id)


@require_role('admin')
Expand Down
16 changes: 8 additions & 8 deletions jumpserver.conf
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
#coding: utf8

[base]
url = http://yourIP
key = 16位字母数字
log = debug | warning
url = http://j
key = 88aaaf7ffe3c6c04
log = debug

[db]
host = 127.0.0.1
Expand All @@ -13,12 +13,12 @@ password = mysql234
database = jumpserver

[websocket]
web_socket_host = yourIP|yourDomainName:3000
web_socket_host = j:3000

[mail]
mail_enable = 1
email_host = yourSMTPHost
email_port = yourSMTPHost|25
email_host_user = yourEmail
email_host_password = yourEmailPassword
email_host = smtp.exmail.qq.com
email_port = 25
email_host_user = [email protected]
email_host_password = jumpserver1234
email_use_tls = True
1 change: 1 addition & 0 deletions jumpserver/urls.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
url(r'^setting', 'setting', name='setting'),
url(r'^terminal/$', 'web_terminal', name='terminal'),
url(r'^install/$', 'install', name='install'),
url(r'^install/test/(\w+)/$', 'install_test', name='install_test'),
url(r'^juser/', include('juser.urls')),
url(r'^jasset/', include('jasset.urls')),
url(r'^jlog/', include('jlog.urls')),
Expand Down
14 changes: 13 additions & 1 deletion jumpserver/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -357,4 +357,16 @@ def web_terminal(request):


def install(request):
return render_to_response('test.html', locals())
return render_to_response('install.html', locals())


def install_test(request, offset):
if offset == 'db':
db_host = request.GET.get('db_host')
db_port = request.GET.get('db_port')
db_user = request.GET.get('db_user')
db_pass = request.GET.get('db_pass')
db = request.GET.get('db')



Loading

0 comments on commit e817715

Please sign in to comment.