mirror of https://github.com/sipwise/repoapi.git
We no longer use the old way of build projects/releases, lets remove no used code Change-Id: Ia39eb72af87f72d0a785ac790f48003e6d9be821pull/7/head
parent
28a0d343ef
commit
28d1be9a4c
@ -1,65 +0,0 @@
|
||||
# Copyright (C) 2016 The Sipwise Team - http://sipwise.com
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify it
|
||||
# under the terms of the GNU General Public License as published by the Free
|
||||
# Software Foundation, either version 3 of the License, or (at your option)
|
||||
# any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful, but WITHOUT
|
||||
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
|
||||
# more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License along
|
||||
# with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
from django import forms
|
||||
|
||||
from . import trunk_build_deps
|
||||
from . import trunk_projects
|
||||
from ..conf import settings
|
||||
|
||||
|
||||
class BuildForm(forms.Form):
|
||||
common_select = forms.CharField(max_length=50)
|
||||
version_release = forms.CharField(max_length=50)
|
||||
distribution = forms.CharField(max_length=30)
|
||||
|
||||
|
||||
class BuildDepForm(BuildForm):
|
||||
def __init__(self, *args, **kwargs):
|
||||
super(BuildDepForm, self).__init__(*args, **kwargs)
|
||||
|
||||
for project in settings.RELEASE_DASHBOARD_BUILD_DEPS:
|
||||
self.fields["version_%s" % project] = forms.CharField(
|
||||
max_length=15
|
||||
)
|
||||
|
||||
|
||||
class BuildReleaseForm(BuildForm):
|
||||
def __init__(self, *args, **kwargs):
|
||||
super(BuildReleaseForm, self).__init__(*args, **kwargs)
|
||||
|
||||
for project in settings.RELEASE_DASHBOARD_PROJECTS:
|
||||
self.fields["version_%s" % project] = forms.CharField(
|
||||
max_length=15
|
||||
)
|
||||
|
||||
|
||||
class BuildTrunkDepForm(BuildForm):
|
||||
def __init__(self, *args, **kwargs):
|
||||
super(BuildTrunkDepForm, self).__init__(*args, **kwargs)
|
||||
|
||||
for project in trunk_build_deps:
|
||||
self.fields["version_%s" % project] = forms.CharField(
|
||||
max_length=30
|
||||
)
|
||||
|
||||
|
||||
class BuildTrunkReleaseForm(BuildForm):
|
||||
def __init__(self, *args, **kwargs):
|
||||
super(BuildTrunkReleaseForm, self).__init__(*args, **kwargs)
|
||||
|
||||
for project in trunk_projects:
|
||||
self.fields["version_%s" % project] = forms.CharField(
|
||||
max_length=30
|
||||
)
|
@ -1,13 +0,0 @@
|
||||
{% extends "release_dashboard/base.html" %}
|
||||
{% load static %}
|
||||
{% block title %}Build release{% endblock %}
|
||||
{% block navlist %}
|
||||
<li><a href="{% url 'release_dashboard:index_old'%}">Release Dashboard</a></li>
|
||||
<li><a href="{% url 'release_dashboard:build_release_old'%}">Build Release</a></li>
|
||||
{% endblock %}
|
||||
{% block content %}
|
||||
{% include "release_dashboard/build_content.html" %}
|
||||
{% endblock %}
|
||||
{% block extrajs %}
|
||||
<script src="{% static 'release_dashboard/js/build.js' %}"></script>
|
||||
{% endblock %}
|
@ -1,79 +0,0 @@
|
||||
<div class="container">
|
||||
<form method="POST" class="form-inline">{% csrf_token %}
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">Actions</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
{% if common_versions %}
|
||||
<div class="form-group">
|
||||
<label for="common_select">Common selection</label>
|
||||
<select class="form-control" id="common_select"
|
||||
name="common_select">
|
||||
<option value="ignore">ignore</option>
|
||||
{% for v in common_versions.branches %}
|
||||
<option value="branch/{{ v }}">branch/{{ v }}</option>
|
||||
{% endfor %}
|
||||
{% for v in common_versions.tags %}
|
||||
<option value="tag/{{ v }}">tag/{{ v }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</div>
|
||||
{% endif %}
|
||||
<div class="form-group">
|
||||
<label for="version_release">Release version</label>
|
||||
<input class="form-control" id="version_release"
|
||||
name="version_release" type="text"
|
||||
value="none">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="distribution">Debian release</label>
|
||||
<select class="form-control" id="distribution"
|
||||
name="distribution">
|
||||
{% for d in debian %}
|
||||
<option value="{{ d }}">{{ d }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</div>
|
||||
<button id="main" type="submit" class="btn btn-default">Submit</button>
|
||||
</div>
|
||||
<div id="select_text_info" class="panel-footer"></div>
|
||||
</div>
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">Data</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<table class="table table-condensed">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Project</th>
|
||||
<th>Version</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for p in projects %}
|
||||
<tr class="repo">
|
||||
<th><label for="version_{{ p.name }}">{{ p.name }}</label></th>
|
||||
<td class="version col-md-1">
|
||||
<select class="form-control" id="version_{{ p.name }}" name="version_{{ p.name }}">
|
||||
<option value="ignore">ignore</option>
|
||||
{% for t in p.tags %}
|
||||
<option value="tag/{{ t }}">tag/{{ t }}</option>
|
||||
{% endfor %}
|
||||
{% for b in p.branches %}
|
||||
<option value="branch/{{ b }}">branch/{{ b }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</td>
|
||||
<td>
|
||||
<button type="button" id="ignore_{{ p.name }}" onclick="click_ignore(event)" class="btn btn-warning">Ignore</button>
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
@ -1,13 +0,0 @@
|
||||
{% extends "release_dashboard/base.html" %}
|
||||
{% load static %}
|
||||
{% block title %}Build dependences{% endblock %}
|
||||
{% block navlist %}
|
||||
<li><a href="{% url 'release_dashboard:index_old'%}">Release Dashboard</a></li>
|
||||
<li><a href="{% url 'release_dashboard:build_deps_old'%}">Build dependences</a></li>
|
||||
{% endblock %}
|
||||
{% block content %}
|
||||
{% include "release_dashboard/build_content.html" %}
|
||||
{% endblock %}
|
||||
{% block extrajs %}
|
||||
<script src="{% static 'release_dashboard/js/build.js' %}"></script>
|
||||
{% endblock %}
|
@ -1,40 +0,0 @@
|
||||
{% extends "release_dashboard/base.html" %}
|
||||
{% load static %}
|
||||
{% block title %}Build release{% endblock %}
|
||||
{% block navlist %}
|
||||
<li><a href="{% url 'release_dashboard:index'%}">Release Dashboard</a></li>
|
||||
{% if release %}
|
||||
<li><a href="{% url 'panel:release-view' release %}">Panel {{release}}</a></li>
|
||||
{% else %}
|
||||
<li><a href="{% url 'release_dashboard:build_docker_images'%}">Build project docker images</a></li>
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
{% block content %}
|
||||
<div class="container">
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">Results {{release}}</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
{% if error %}
|
||||
<p class="bg-danger">{{ error }}</p>
|
||||
{% endif %}
|
||||
{% for project in projects %}
|
||||
{% if project.url %}
|
||||
<p class="bg-success">
|
||||
{% if release %}
|
||||
<a href="{% url 'panel:project-view' release project.name %}">{{ project.name }}</a>
|
||||
{% else %}
|
||||
<a href="{{ project.url }}">{{ project.name }}</a>
|
||||
{% endif %}
|
||||
</p>
|
||||
{% else %}
|
||||
<p class="bg-danger">
|
||||
{{ project.name }}: Not triggered
|
||||
</p>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{% endblock %}
|
@ -1,13 +0,0 @@
|
||||
{% extends "release_dashboard/base.html" %}
|
||||
{% load static %}
|
||||
{% block title %}Build release{% endblock %}
|
||||
{% block navlist %}
|
||||
<li><a href="{% url 'release_dashboard:index_old'%}">Release Dashboard</a></li>
|
||||
<li><a href="{% url 'release_dashboard:build_release_tag_old'%}">Build Release by tag</a></li>
|
||||
{% endblock %}
|
||||
{% block content %}
|
||||
{% include "release_dashboard/build_content.html" %}
|
||||
{% endblock %}
|
||||
{% block extrajs %}
|
||||
<script src="{% static 'release_dashboard/js/build.js' %}"></script>
|
||||
{% endblock %}
|
@ -1,13 +0,0 @@
|
||||
{% extends "release_dashboard/base.html" %}
|
||||
{% load static %}
|
||||
{% block title %}Build release{% endblock %}
|
||||
{% block navlist %}
|
||||
<li><a href="{% url 'release_dashboard:index_old'%}">Release Dashboard</a></li>
|
||||
<li><a href="{% url 'release_dashboard:build_trunk_release_old'%}">Build Trunk Release</a></li>
|
||||
{% endblock %}
|
||||
{% block content %}
|
||||
{% include "release_dashboard/build_content.html" %}
|
||||
{% endblock %}
|
||||
{% block extrajs %}
|
||||
<script src="{% static 'release_dashboard/js/build.js' %}"></script>
|
||||
{% endblock %}
|
@ -1,13 +0,0 @@
|
||||
{% extends "release_dashboard/base.html" %}
|
||||
{% load static %}
|
||||
{% block title %}Build dependences{% endblock %}
|
||||
{% block navlist %}
|
||||
<li><a href="{% url 'release_dashboard:index_old'%}">Release Dashboard</a></li>
|
||||
<li><a href="{% url 'release_dashboard:build_trunk_deps_old'%}">Build Trunk dependences</a></li>
|
||||
{% endblock %}
|
||||
{% block content %}
|
||||
{% include "release_dashboard/build_content.html" %}
|
||||
{% endblock %}
|
||||
{% block extrajs %}
|
||||
<script src="{% static 'release_dashboard/js/build.js' %}"></script>
|
||||
{% endblock %}
|
Loading…
Reference in new issue