/usr/share/pybit-web/static/packageinstance.htm is in pybit-web 1.0.0-3.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 | <!DOCTYPE html>
<html lang="en">
<head>
<META HTTP-EQUIV='PRAGMA' CONTENT='NO-CACHE'>
<META HTTP-EQUIV="Expires" CONTENT="-1">
<meta charset="utf-8">
<title>pyBit - Package Instances </title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="">
<meta name="author" content="">
<link href="bootstrap/css/bootstrap.min.css" rel="stylesheet">
<link rel="shortcut icon" href="favicon.ico">
<link rel="apple-touch-icon" href="favicon.png" />
<style type="text/css">
body
{
padding-top : 60px; /* 60px to make the container go all the way
* to the bottom of the topbar */
padding-bottom : 40px;
}
</style>
<link href="bootstrap/css/bootstrap-responsive.min.css" rel="stylesheet">
<script src="{{protocol}}{{jqueryurl}}" type="text/javascript"></script>
<script src="{{protocol}}{{jqueryformurl}}" type="text/javascript"></script>
<script src="bootstrap/js/bootstrap.min.js" type="text/javascript"></script>
</head>
<body>
<div class="container-fluid">
<div class="row-fluid">
<div class="navbar navbar-inverse navbar-fixed-top">
<div class="navbar-inner">
<div class="container-fluid">
<a class="btn btn-navbar" data-toggle="collapse" data-target=".nav-collapse"> <span class="icon-bar"></span> <span class="icon-bar"></span> <span class="icon-bar"></span> </a>
<a class="brand" href="index.htm">pyBit</a>
<div class="nav-collapse collapse">
<ul class="nav">
<li>
<a href="index.htm">Home</a>
</li>
<li>
<a href="lookups.htm">Lookups</a>
</li>
<li>
<a href="package.htm">Packages</a>
</li>
<li class="active">
<a href="packageinstance.htm">Package Instances</a>
</li>
<li>
<a href="job.htm">Jobs</a>
</li>
<li>
<a href="buildd.htm">Build Boxes</a>
</li>
</ul>
</div>
<!--/.nav-collapse -->
</div>
</div>
</div>
</div>
<div class="span2">
<!--Sidebar content-->
<div class="well sidebar-nav">
<ul class="nav nav-list">
<li class="nav-header">
Navigation
</li>
<li>
<a href="index.htm">Home</a>
</li>
<li class="nav-header">
Lookups
</li>
<li>
<a href="arches.htm">Architectures</a>
</li>
<li>
<a href="statuses.htm">Statuses</a>
</li>
<li>
<a href="dists.htm">Dists</a>
</li>
<li>
<a href="formats.htm">Formats</a>
</li>
<li>
<a href="suites.htm">Suites</a>
</li>
<li>
<a href="envs.htm">Build Environments</a>
</li>
<li class="nav-header">
Packages
</li>
<li>
<a href="package.htm">All Packages</a>
</li>
<li class="active">
<a href="packageinstance.htm">Package Instances</a>
</li>
<li class="nav-header">
Jobs
</li>
<li>
<a href="job.htm">Jobs</a>
</li>
<li>
<a href="buildd.htm">BuildBoxes</a>
</li>
<li>
<a href="blacklist.htm">Blacklist Rules</a>
</li>
</ul>
</div>
<!--/.well -->
</div>
<div class="span10">
<!--Body content-->
<div class="container-fluid">
<h1>PyBit - python Buildd Integration Toolkit.</h1>
<h3>Package Instances</h3>
<div class="accordion" id="accordion1">
<div class="accordion-group">
<div class="accordion-heading">
<a class="accordion-toggle" data-toggle="collapse" data-parent="#accordion1" href="#collapseOne"> Click here to show the submit packageinstance form. </a>
</div>
<div id="collapseOne" class="accordion-body collapse">
<div class="accordion-inner">
<form class="form" method="POST" action="packageinstance" id="packageinstance_form" name="packageinstance_form">
<legend>
Create a package instance
</legend>
<span class="help-block">Choose an existing package by name and version, then define the arch, suite, distribution, and format, for this particular instance, then click 'Submit', to add it to the database. This generally happens automatically thanks to the SVN or other VCS hook.</span>
<label for="package">Package: </label>
<select name="package" id="package" onclick="changePackage()"></select> <label for="version">Package Version: </label>
<select name="version" id="version"></select><label for="arch_id">Architecture: </label><select name="arch_id" id="arch_id"></select><label for="suite_id">Suite: </label><select name="suite_id" id="suite_id"></select><label for="dist_id">Distribution: </label><select name="dist_id" id="dist_id"></select><label for="format_id">Package Format: </label><select name="format_id" id="format_id"></select>
<label for="build_env_id">Build Environment</label><select name="build_env_id" id="build_env_id"></select>
<br>
<input type="checkbox" name="slave" value="0" id="slave">
Slave</input>
<br>
<button type="submit" class="btn btn-primary">
Submit
</button>
<button type="button" class="btn">
Cancel
</button>
</form>
</div>
</div>
</div>
</div>
<span class="help-block">Existing packages instances are listed below. To add a new package instance to the database, add its details using the form above.</span>
<table id="tbl_packageinstances" class="table table-bordered table-condensed">
<tr>
<th colspan='8'>Package Instances</th>
</tr>
<tr>
<th>ID</th><th>Package</th><th>Architecture</th><th>Distribution</th><th>Format</th><th>Suite</th><th>Environment</th><th>Master?</th>
</tr>
</table>
<hr>
<footer>
<p>
© TCL 2012
</p>
</footer>
</div>
<!--/.fluid-container-->
<script type="text/javascript">
function getUrlVars ( )
{
var vars =
{
};
var parts = window.location.href.replace ( /[?&]+([^=&]+)=([^&]*)/gi , function ( m , key , value )
{
vars [ key ] = value;
} );
return vars;
}
function changePackage()
{
var element = document.getElementById ( "package" );
$ ( "#version" ).empty();
if(element.options [ element.selectedIndex ] == null)
{
return;
}
else
{
packageName = element.options [ element.selectedIndex ].value;
var named_versions = "" + window.location.protocol.toString ( ) + "//" + window.location.host.toString ( ) + "/package/details/" + packageName
$.getJSON ( named_versions , function ( json2 )
{
$.each ( json2 , function ( j , field2 )
{
$ ( "#version" ).append ( "<option value='" + field2.version + "'>" + field2.version + "</option>" );
} );
} );
}
}
$ ( ).ready ( function ( )
{
var packageinstance_page = 1;
$ ( '#packageinstance_form' ).ajaxForm ( function ( )
{
alert ( "Packageinstance Added!" );
location.reload ( );
} );
var package_names = "" + window.location.protocol.toString ( ) + "//" + window.location.host.toString ( ) + "/package/names"
$.getJSON ( package_names , function ( json )
{
$.each ( json , function ( i , field )
{
$ ( "#package" ).append ( "<option value='" + field.name + "'>" + field.name + "</option>" );
} );
changePackage();
} );
var arches = "" + window.location.protocol.toString ( ) + "//" + window.location.host.toString ( ) + "/arch"
$.getJSON ( arches , function ( json )
{
$.each ( json , function ( i , field )
{
$ ( "#arch_id" ).append ( "<option value='" + field.id + "'>" + field.name + "</option>" );
} );
} );
var suites = "" + window.location.protocol.toString ( ) + "//" + window.location.host.toString ( ) + "/suite"
$.getJSON ( suites , function ( json )
{
$.each ( json , function ( i , field )
{
$ ( "#suite_id" ).append ( "<option value='" + field.id + "'>" + field.name + "</option>" );
} );
} );
var dists = "" + window.location.protocol.toString ( ) + "//" + window.location.host.toString ( ) + "/dist"
$.getJSON ( dists , function ( json )
{
$.each ( json , function ( i , field )
{
$ ( "#dist_id" ).append ( "<option value='" + field.id + "'>" + field.name + "</option>" );
} );
} );
var formats = "" + window.location.protocol.toString ( ) + "//" + window.location.host.toString ( ) + "/format"
$.getJSON ( formats , function ( json )
{
$.each ( json , function ( i , field )
{
$ ( "#format_id" ).append ( "<option value='" + field.id + "'>" + field.name + "</option>" );
} );
} );
var envs = "" + window.location.protocol.toString ( ) + "//" + window.location.host.toString ( ) + "/env"
// Special case
$ ( "#build_env_id" ).append ( "<option value=''>Not Specified</option>" );
$.getJSON ( envs , function ( json )
{
$.each ( json , function ( i , field )
{
$ ( "#build_env_id" ).append ( "<option value='" + field.id + "'>" + field.name + "</option>" );
} );
} );
if ( getUrlVars() [ "packageinstance_page" ] )
{
packageinstance_page = getUrlVars() [ "packageinstance_page" ]
var url = "" + window.location.protocol.toString ( ) + "//" + window.location.host.toString ( ) + "/packageinstance/page/" + packageinstance_page
}
else
{
var url = "" + window.location.protocol.toString ( ) + "//" + window.location.host.toString ( ) + "/packageinstance/page/1"
}
new_packageinstance_page = parseInt ( packageinstance_page ) + 1;
last_packageinstance_page = parseInt ( packageinstance_page ) - 1;
$.getJSON ( url , function ( json )
{
$.each ( json , function ( i , field )
{
if (field.build_env == null) {
env_name = ""
} else {
env_name = field.build_env.name
}
$ ( "#tbl_packageinstances" ).append ( "<tr><td>" + field.id + "</td><td>" + field.package.name + " " + field.package.version + "</a></td><td>" + field.arch.name + "</td><td>" + field.distribution.name + "</td><td>" + field.format.name + "</td><td>" + field.suite.name + "</td><td>" + env_name + "</td><td>" + field.master + "</td></tr>" );
} );
var url2= "" + window.location.protocol.toString ( ) + "//" + window.location.host.toString ( ) + "/packageinstance/count"
$.getJSON ( url2 , function ( json2 )
{
var html_part1 = "";
if (packageinstance_page > 0)
{
html_part1 = "<li><a href='" + window.location.protocol.toString ( ) + "//" + window.location.host.toString ( ) + "/packageinstance.htm?packageinstance_page=" + last_packageinstance_page + "'>Prev</a></li><li><a>" + packageinstance_page + "/" + json2 + "</a></li>";
}
var html_part2 = "";
if (packageinstance_page < json2) // Not last page
{
html_part2 = "<li><a href='" + window.location.protocol.toString ( ) + "//" + window.location.host.toString ( ) + "/packageinstance.htm?packageinstance_page=" + new_packageinstance_page + "'>Next</a></li>";
}
$ ( '#tbl_packageinstances' ).append ( "<div class='pagination'><ul>" + html_part1 + html_part2 + "</ul></div>" );
});
} );
} );
</script>
</div>
</div>
</body>
</html>
|