commit
ed673c68d0
14
.travis.yml
14
.travis.yml
@ -15,18 +15,18 @@ env:
|
||||
|
||||
matrix:
|
||||
include:
|
||||
- python: "2.7"
|
||||
dist: trusty
|
||||
env: DJANGO=1.11 COVERAGE="coverage run -m" TEST_K="not ddns_client" TEST_OPTS="--pep8"
|
||||
- python: "3.5"
|
||||
dist: trusty
|
||||
env: DJANGO=1.11
|
||||
dist: xenial
|
||||
env: DJANGO=2.2
|
||||
- python: "3.6"
|
||||
dist: trusty
|
||||
env: DJANGO=1.11
|
||||
dist: xenial
|
||||
env: DJANGO=2.2
|
||||
- python: "3.7"
|
||||
dist: xenial
|
||||
env: DJANGO=2.2
|
||||
- python: "3.8"
|
||||
dist: xenial
|
||||
env: DJANGO=2.2 COVERAGE="coverage run -m" TEST_K="not ddns_client" TEST_OPTS="--pep8"
|
||||
|
||||
install:
|
||||
- ./scripts/travis/install.sh
|
||||
|
2
LICENSE
2
LICENSE
@ -1,7 +1,7 @@
|
||||
This project is licensed under the the 3-clause BSD license (also known as
|
||||
"Revised BSD License", "New BSD License", or "Modified BSD License"):
|
||||
|
||||
Copyright (c) 2013-2018, The nsupdate.info Development Team (see AUTHORS file)
|
||||
Copyright (c) 2013-2020, The nsupdate.info Development Team (see AUTHORS file)
|
||||
All rights reserved.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
|
@ -227,6 +227,11 @@ To make nsupdate.info (Django) use PostgreSQL, put this into YOUR settings::
|
||||
|
||||
Now proceed with manage migrate as shown above.
|
||||
|
||||
Disable User Registration
|
||||
-------------------------
|
||||
If you want to disable user registration, put this into YOUR settings::
|
||||
|
||||
REGISTRATION_OPEN = False
|
||||
|
||||
Customization of the Web UI
|
||||
===========================
|
||||
|
BIN
logo/github_social_preview.png
Normal file
BIN
logo/github_social_preview.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 29 KiB |
@ -1,7 +1,7 @@
|
||||
# packages always needed
|
||||
dnspython
|
||||
netaddr
|
||||
django~=1.11.0
|
||||
django~=2.2.0
|
||||
django-bootstrap-form
|
||||
django-referrer-policy
|
||||
django-registration-redux
|
||||
|
7
setup.py
7
setup.py
@ -29,9 +29,9 @@ setup(
|
||||
platforms='any',
|
||||
setup_requires=['setuptools_scm'],
|
||||
install_requires=[
|
||||
'dnspython<1.17.0', # 1.16 is last with py27 support
|
||||
'dnspython',
|
||||
'netaddr',
|
||||
'django>=1.11.0',
|
||||
'django>=2.2.0',
|
||||
'django-bootstrap-form',
|
||||
'django-referrer-policy',
|
||||
'django-registration-redux',
|
||||
@ -47,12 +47,11 @@ setup(
|
||||
'License :: OSI Approved :: BSD License',
|
||||
'Operating System :: OS Independent',
|
||||
'Programming Language :: Python',
|
||||
'Programming Language :: Python :: 2',
|
||||
'Programming Language :: Python :: 2.7',
|
||||
'Programming Language :: Python :: 3',
|
||||
'Programming Language :: Python :: 3.5',
|
||||
'Programming Language :: Python :: 3.6',
|
||||
'Programming Language :: Python :: 3.7',
|
||||
'Programming Language :: Python :: 3.8',
|
||||
'Topic :: Internet :: Name Service (DNS)',
|
||||
],
|
||||
)
|
||||
|
@ -3,6 +3,8 @@ register our models for Django's admin
|
||||
"""
|
||||
|
||||
from django.contrib import admin
|
||||
from django.urls import reverse
|
||||
from django.utils.safestring import mark_safe
|
||||
|
||||
from .models import Host, RelatedHost, Domain, BlacklistedHost, ServiceUpdater, ServiceUpdaterHostConfig
|
||||
|
||||
@ -16,10 +18,19 @@ class DomainAdmin(admin.ModelAdmin):
|
||||
|
||||
@admin.register(Host)
|
||||
class HostAdmin(admin.ModelAdmin):
|
||||
list_display = ("name", "domain", "created_by", "client_faults", "api_auth_faults", "abuse", "abuse_blocked")
|
||||
list_display = ("name", "domain", "created_by_link", "client_faults", "api_auth_faults", "abuse", "abuse_blocked")
|
||||
list_filter = ("created", "abuse", "abuse_blocked", "domain")
|
||||
read_only_fields = ('created_by_link',)
|
||||
|
||||
search_fields = ("name", "created_by__username", "created_by__email")
|
||||
|
||||
def created_by_link(self, obj):
|
||||
return mark_safe('<a href="{}">{}</a>'.format(
|
||||
reverse("admin:auth_user_change", args=(obj.created_by.pk,)),
|
||||
obj.created_by.username
|
||||
))
|
||||
created_by_link.short_description = 'created by'
|
||||
|
||||
|
||||
@admin.register(RelatedHost)
|
||||
class RelatedHostAdmin(admin.ModelAdmin):
|
||||
|
@ -149,7 +149,7 @@ TEMPLATES = [
|
||||
# 'django.template.context_processors.media',
|
||||
# 'django.template.context_processors.static',
|
||||
# 'django.template.context_processors.tz',
|
||||
# 'django.contrib.messages.context_processors.messages',
|
||||
'django.contrib.messages.context_processors.messages',
|
||||
'social_django.context_processors.backends',
|
||||
'social_django.context_processors.login_redirect',
|
||||
|
||||
|
@ -9,8 +9,8 @@
|
||||
|
||||
<title>{% block title %}{{ WWW_HOST }}{% endblock %}</title>
|
||||
|
||||
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous">
|
||||
<link href="https://use.fontawesome.com/releases/v5.5.0/css/all.css" rel="stylesheet" integrity="sha384-B4dIYHKNBt8Bc12p+WXckhzcICo0wtJAoU8YZTY5qE0Id1GSseTk6S+L3BlXeVIU" crossorigin="anonymous">
|
||||
<link href="https://stackpath.bootstrapcdn.com/bootstrap/3.4.1/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-HSMxcRTRxnN+Bdg0JdbxYKrThecOKuH5zCYotlSAcp1+c8xmyTe9GYg1l9a69psu" crossorigin="anonymous">
|
||||
<link href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.11.2/css/all.min.css" rel="stylesheet" integrity="sha256-+N4/V/SbAFiW1MPBCXnfnP9QSN3+Keu+NlB+0ev/YKQ=" crossorigin="anonymous" />
|
||||
<link href="{% static 'css/nsupdate.css' %}" rel="stylesheet">
|
||||
<link rel="icon" type="image/svg+xml" sizes="any" href="{% static "img/favicon.svg" %}">
|
||||
<link rel="icon" type="image/png" href="{% static "img/favicon_32.png" %}" sizes="32x32">
|
||||
@ -18,8 +18,8 @@
|
||||
<!-- note: keep jQuery and bootstrap js here,
|
||||
stuff in the include / block right below might depend on it!
|
||||
-->
|
||||
<script src="https://code.jquery.com/jquery-3.3.1.min.js" integrity="sha256-FgpCb/KJQlLNfOu91ta32o/NMZxltwRo8QtmkMRdAu8=" crossorigin="anonymous"></script>
|
||||
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js" integrity="sha384-Tc5IQib027qvyjSMfHjOMaLkfuWVxZxUPnCJA7l2mCWNIpG9mGCD8wGNIcPD7Txa" crossorigin="anonymous"></script>
|
||||
<script src="https://code.jquery.com/jquery-3.4.1.min.js" integrity="sha256-CSXorXvZcTkaix6Yvo6HppcZGetbYMGWSFlBw8HfCJo=" crossorigin="anonymous"></script>
|
||||
<script src="https://stackpath.bootstrapcdn.com/bootstrap/3.4.1/js/bootstrap.min.js" integrity="sha384-aJ21OjlMXNL5UyIl/XNwTMqvzeRMZH2w8c5cRVpzpU8Y5bApTppSuUkhZXN0VxHd" crossorigin="anonymous"></script>
|
||||
{% include "includes/base_head.html" %}
|
||||
{% block html_head %}{% endblock %}
|
||||
</head>
|
||||
|
Loading…
x
Reference in New Issue
Block a user