<commit_before>{% extends "base.html" %}

{% block content %}
  <div class="row">
    <div class="col-md-12"><h1>Manage hostnames</h1></div>
  </div>

  <ul class="nav nav-tabs">
    <li class="active"><a href="/user/hosts/add">Add hostname</a></li>
    <li><a href="/user/hosts/list">Your hostnames</a></li>
  </ul>
  <br>

  <div class="row">
    {% if suffixes %}
    <div class="col-md-8">
      <p>
        Use the from to specify your hostnames. You can add up to 
        {{config.dns.max_hosts}} hostnames with a maximum length of 
        63 characters each. Only alphanumeric characters plus the minus (-)
        character are allowed.
      </p>

      {% if suffixes|count > 1 %}
      <p>
        From the dropdown menu, you can choose from a list of available 
        suffixes for your DNS name. 
      </p>
      {% endif %}

      <p>
        Each hostname you add gets its individual password for updating.
        The minimum password length is {{config.auth.password_min_chars}} 
        characters. If you want to update multiple hostnames at once, you
        have to use the same password for them.
      </p>

      <p>
        If you specify an initial IP address, your hostname will instantly
        be available. If you leave the IP address field blank, you have to
        update it using your homerouter or the ddclient program, before it
        will respond to DNS queries.
      </p>
      <p>
        After adding a new hostname, you can modify it or display configuration
        examples by navigating to the <em><a href="/user/hosts/list">Your hostnames</a></em>
        tab and click the <em>Details</em> button.
      </p>
    </div>

    <div class="col-md-4">
      <div class="box">
        <form role="form" action="/user/hosts/add" method="post">
          <div class="form-group">
            <label for="inputHostname">Hostname</label>
            <div class="input-group">
              <span class="input-group-addon"><i class="fa fa-desktop"></i></span>
              <input class="form-control" type="text" id="inputHostname" placeholder="Hostname" name="hostname" required="required">
            </div>
          </div>

          {% if suffixes|count > 1 %}
          <div class="form-group">
            <label for="inputSuffix">Suffix</label>
            <div class="input-group">
              <span class="input-group-addon"><i class="fa fa-sitemap"></i></span>
              <select class="form-control" name="suffix" id="inputSuffix">
                {% for suffix in suffixes %}
                <option value="{{suffix.id}}">{{suffix.name}}</option>
                {% endfor %}
              </select>
            </div>
          </div>
          {% else %}
          <input type="hidden" name="suffix" value="{{suffixes[0].id}}">
          {% endif %}<commit_msg>suffix -> zone<commit_after>{% extends "base.html" %}

{% block content %}
  <div class="row">
    <div class="col-md-12"><h1>Manage hostnames</h1></div>
  </div>

  <ul class="nav nav-tabs">
    <li class="active"><a href="/user/hosts/add">Add hostname</a></li>
    <li><a href="/user/hosts/list">Your hostnames</a></li>
  </ul>
  <br>

  <div class="row">
    {% if suffixes %}
    <div class="col-md-8">
      <p>
        Use the from to specify your hostnames. You can add up to 
        {{config.dns.max_hosts}} hostnames with a maximum length of 
        63 characters each. Only alphanumeric characters plus the minus (-)
        character are allowed.
      </p>

      {% if suffixes|count > 1 %}
      <p>
        From the dropdown menu, you can choose from a list of available 
        zones for your DNS name. 
      </p>
      {% endif %}

      <p>
        Each hostname you add gets its individual password for updating.
        The minimum password length is {{config.auth.password_min_chars}} 
        characters. If you want to update multiple hostnames at once, you
        have to use the same password for them.
      </p>

      <p>
        If you specify an initial IP address, your hostname will instantly
        be available. If you leave the IP address field blank, you have to
        update it using your homerouter or the ddclient program, before it
        will respond to DNS queries.
      </p>
      <p>
        After adding a new hostname, you can modify it or display configuration
        examples by navigating to the <em><a href="/user/hosts/list">Your hostnames</a></em>
        tab and click the <em>Details</em> button.
      </p>
    </div>

    <div class="col-md-4">
      <div class="box">
        <form role="form" action="/user/hosts/add" method="post">
          <div class="form-group">
            <label for="inputHostname">Hostname</label>
            <div class="input-group">
              <span class="input-group-addon"><i class="fa fa-desktop"></i></span>
              <input class="form-control" type="text" id="inputHostname" placeholder="Hostname" name="hostname" required="required">
            </div>
          </div>

          {% if suffixes|count > 1 %}
          <div class="form-group">
            <label for="inputSuffix">Zone</label>
            <div class="input-group">
              <span class="input-group-addon"><i class="fa fa-sitemap"></i></span>
              <select class="form-control" name="suffix" id="inputSuffix">
                {% for suffix in suffixes %}
                <option value="{{suffix.id}}">{{suffix.name}}</option>
                {% endfor %}
              </select>
            </div>
          </div>
          {% else %}
          <input type="hidden" name="suffix" value="{{suffixes[0].id}}">
          {% endif %}
{'fraction_non_alphanumeric': 0.1415929203539823, 'fraction_numerical': 0.0038938053097345134, 'mean_word_length': 2.1394444444444445, 'pattern_counts': {'":': 0, '<': 133, '<?xml version=': 0, '>': 138, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7308064', 'n_tokens_mistral': 1712, 'n_tokens_neox': 1601, 'n_words': 507}