Commit bb123461 authored by Charlie Jacomme's avatar Charlie Jacomme

Fix cnames

parent ad1ce4ed
Pipeline #747 failed with stage
......@@ -816,13 +816,12 @@ class CNAMERecordSerializer(serializers.ModelSerializer):
"""Serialize `machines.models.Domain` objects with the data needed to
generate a CNAME DNS record.
alias = serializers.CharField(source='', read_only=True)
alias = serializers.CharField(source='cname', read_only=True)
hostname = serializers.CharField(source='name', read_only=True)
extension = serializers.CharField(source='', read_only=True)
class Meta:
model = machines.Domain
fields = ('alias', 'hostname', 'extension')
fields = ('alias', 'hostname')
class DNSZonesSerializer(serializers.ModelSerializer):
......@@ -712,8 +712,7 @@ class Extension(RevMixin, AclMixin, models.Model):
from re2o.utils import all_active_assigned_interfaces
return (Domain.objects
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment