Skip to content
Snippets Groups Projects
Commit 04b74ae8 authored by hahn's avatar hahn
Browse files

- vor dem Build wird revision angezeigt

- dropdown-Menus bei Mouseover
- Morphomed-Projekt hinzugefuegt
parent 1ea388c0
No related branches found
No related tags found
No related merge requests found
auxiliary.org-netbeans-modules-php-phpunit.bootstrap_2e_create_2e_tests=false
auxiliary.org-netbeans-modules-php-phpunit.bootstrap_2e_path=
auxiliary.org-netbeans-modules-php-phpunit.configuration_2e_path=
auxiliary.org-netbeans-modules-php-phpunit.customSuite_2e_path=
auxiliary.org-netbeans-modules-php-phpunit.phpUnit_2e_path=
auxiliary.org-netbeans-modules-php-phpunit.test_2e_groups_2e_ask=false
auxiliary.org-netbeans-modules-php-phpunit.test_2e_run_2e_all=false
ignore.path=
include.path=\
${php.global.include.path}
php.version=PHP_53
phpunit.bootstrap=
phpunit.bootstrap.create.tests=false
phpunit.configuration=
phpunit.run.test.files=false
phpunit.script=
phpunit.suite=
phpunit.test.groups.ask=false
source.encoding=UTF-8
src.dir=.
tags.asp=false
......
......@@ -47,7 +47,7 @@ if (array_key_exists("confirm", $aParams)) {
<tbody>
<tr>
<td class="'.$sPhase.'">
auf dem Server <strong>'.$sPhase.'</strong> ist installiert:
auf dem Server ist installiert:<br>
'.$oPrj->renderPhaseDetail($sPhase, "deployed", false).'
</td>
<td style="vertical-align: middle;">
......@@ -58,12 +58,13 @@ if (array_key_exists("confirm", $aParams)) {
'.$oPrj->renderPhaseDetail($sNext, "onhold", false).'
</td>
<td class="'.$sNext.'">
im Repo:
im Repo:<br>
'.$oPrj->renderPhaseDetail($sNext, "ready4deployment", false).'
</td>
</tr>
</tbody>
</table>
<br>
';
if (
......
......@@ -18,7 +18,38 @@ if (array_key_exists("confirm", $aParams)) {
$sOut.='
<p>
Es wird ein neues Paket erstellt und f&uuml;r die Phase <em class="'.$sNext.'">'.$sNext.'</em> bereitgestellt.<br>
</p>
<table>
<thead>
<tr>
<th class="'.$sPhase.'">'.$sPhase.'</th>
<th> </th>
<th class="'.$sNext.'" colspan="2">'.$sNext.'</th>
</tr>
</thead>
<tbody>
<tr>
<td class="'.$sPhase.'">
HEAD ist:<br>
'.$oPrj->showRepoInfo().'
</td>
<td style="vertical-align: middle;">
<img src="/deployment/images/nuvola64x64/apps/noatun.png">
</td>
<td class="'.$sNext.'">
in der Queue:<br>
'.$oPrj->renderPhaseDetail($sNext, "onhold", false).'
</td>
<td class="'.$sNext.'">
im Repo:<br>
'.$oPrj->renderPhaseDetail($sNext, "ready4deployment", false).'
</td>
</tr>
</tbody>
</table>
<br>
';
// Eingabe Kommentare zum Deployment
......
......@@ -15,12 +15,14 @@ if (!array_key_exists("prj", $aParams)){
$oPrj=new project($aParams["prj"]);
$sPhpOut='
<h3>Angaben zum Projekt</h3>
<p>'.$oPrj->renderProjektInfos().'</p>
'.$oPrj->renderProjektInfos().'
<h3>Phasen</h3>
<p>
F&uuml;r das Projekt sind folgende Phasen konfiguriert:
</p>
'.$oPrj->renderPhaseInfo().'
<br>
'.$oPrj->renderLink("build").'
<br><br>
<h3>Versionen</h3>
......
......@@ -130,12 +130,14 @@
border-radius: 0px;
margin-bottom: 0px;
}
ul.nav li.dropdown:hover ul.dropdown-menu{
display: block;
margin-top:0px
}
</style>
<title>IML Deployment</title>
<!--
<meta name="robots" content="noindex, nofollow" />
<style type="text/css" title="currentStyle">
......@@ -145,10 +147,10 @@
<script type="text/javascript" src="/shared/js/jquery.js"></script>
<script type="text/javascript" src="/shared/js/datatables/media/js/jquery.dataTables.min.js"></script>
-->
<link rel="stylesheet" type="text/css" href="main.css" media="screen">
<script type="text/javascript" src="main.js"></script>
-->
{{HEADER}}
......
......@@ -284,7 +284,7 @@ class project {
foreach ($this->_aData["phases"] as $sPhase=>$aData){
foreach(array_keys($this->_aPlaces) as $sPlace){
if (array_key_exists($sPlace, $aData) && array_key_exists("version", $aData[$sPlace])){
$this->_aVersions[$aData[$sPlace]["version"]][]=$sPhase.":".$sPlace;
$this->_aVersions[$aData[$sPlace]["version"]][]=array('phase'=>$sPhase, 'place'=>$sPlace);
}
}
}
......@@ -643,6 +643,34 @@ class project {
}
/**
* TODO: fix or delete
* @return type
*/
public function showRepoInfo(){
// return "TODO: fix or delete project::showRepoInfo()<br>";
$sReturn="";
switch ($this->_aPrjConfig["build"]["type"]) {
case "git":
$sKeyfile = dirname(dirname(__file__)) . "/" . $this->_aPrjConfig["build"]["keyfile"];
$sWrapper = dirname(dirname(dirname(dirname(__file__)))) . "/shellscripts/gitsshwrapper.sh";
// $sReturn.=$this->_execAndSend("export GIT_SSH=$sWrapper ; export PKEY=$sKeyfile; git ls-remote --heads " . $this->_aPrjConfig["build"]["ssh"]);
$sGitCmd="git ls-remote --heads " . $this->_aPrjConfig["build"]["ssh"] . " master";
$sReturn.="$sGitCmd<br><pre>";
$sReturn.= shell_exec("export GIT_SSH=$sWrapper ; export PKEY=$sKeyfile; $sGitCmd");
$sReturn."</pre>";
// $sVersioninfo = str_replace("\n", "<br>", shell_exec("cd $sTempDir && git log -1"));
break;
default:
return $this->getBox("error", "Build Type not supported: " . $this->_aPrjConfig["build"]["type"]. $sReturn);
}
return $sReturn;
}
/**
* Build a new package for the deployment. It will be put to the queue
* of the first active phase (i.e. preview).
......
......@@ -72,6 +72,34 @@ $aProjects=array(
),
),
),
"mmmu-sf2"=>array(
"label"=>"Morphomed Maintenance Utility",
"fileprefix"=>"elearning",
"description" => 'E-Learning, Morphomed Backend mit Symfony 2',
"contact" => 'Rafael Beck',
"build"=>array(
"type"=>"git", // one of git, svn, ...
// for github:
// generate ssh keypair
// https://help.github.com/articles/generating-ssh-keys
"ssh"=>"git@github.com:iml-it/mmmu-sf2.git",
// der public Key muss beim Git-Repo hinterlegt sein
"keyfile"=>"config/sshkeys/git@gitlab.iml.unibe.ch",
"webaccess"=>"https://github.com/iml-it/mmmu-sf2",
),
"phases"=>array(
"preview"=>array(
"url"=>"http://preview.e-learning.iml.unibe.ch/",
),
"stage"=>array(
// "url"=>"http://stage.scrudu.iml.unibe.ch/"
),
"live"=>array(
// "url"=>"http://www.scrudu.iml.unibe.ch/"
),
),
),
"scrudu"=>array(
"label"=>"Scrudu",
"fileprefix"=>"scrudu",
......@@ -100,18 +128,6 @@ $aProjects=array(
),
),
),
"prj1"=>array(
"label"=>"Test-Projekt.",
"fileprefix"=>"testprj",
"description" => 'Eine kurze Beschreibung, um was für eine Applikation es sich handelt',
"contact" => 'Entwickler, Verantwortliche etc.',
"build"=>array(
"type"=>"git", // one of git, svn, ...
"url"=>"ssh gituser@gitserver:/path/to/project",
),
"phases"=>array(),
),
);
// ----------------------------------------------------------------------
......
......@@ -115,16 +115,19 @@ function getTopArea(){
</li>
-->
</ul>
<ul class="nav pull-right">
<li><a href="https://secure.iml.unibe.ch/wiki/doku.php/it/entwicklung/continuous_deployment"><i class=" icon-question-sign"></i> Hilfe</a></li>
</ul>
</div>
</div><div id="header2">';
if (!array_key_exists("prj", $aParams)){
$sReturn.='<img src="'.$sImageBase.$aImages['overview'].'" id="imgtop">'
$sReturn.='<img src="'.$sImageBase.$aImages['overview'].'" id="imgtop" alt="">'
. '<h1>&Uuml;bersicht</h1><span class="description">Alle Projekte und Versionen in den einzelnen Phasen</span>';
} else {
$oPrj=new project($aParams["prj"]);
$sReturn.='<img src="'.$sImageBase.$aImages['project'].'" id="imgtop">
<h1>'.$oPrj->getLabel().'</h1><span class="description">'.$oPrj->getDescription().'</div>';
$sReturn.='<img src="'.$sImageBase.$aImages['project'].'" id="imgtop" alt="">
<h1>'.$oPrj->getLabel().'</h1><span class="description">'.$oPrj->getDescription().'</span>';
if (array_key_exists("action", $aParams)){
// $sReturn.='<h2>Aktion: '.$aParams["action"].'</h2>';
}
......@@ -151,7 +154,7 @@ function getAction(){
}
$sReturn.='<h2 class="action '.$aParams["action"].'">'.$sLabel.'</h2>';
} else if (array_key_exists("prj", $aParams)){
$sReturn.='<h2 class="action prjhome"> Startseite des Projekts</h2>';
$sReturn.='<h2 class="action prjhome"> Projekt-Home</h2>';
}
return $sReturn;
}
......
......@@ -36,7 +36,7 @@ $sPhpOut='
'.$sPhpOut.'
</div>
<div id="footer">
IML Deployment &copy '.date("Y").' <a href="http://www.iml.unibe.ch/">Institut f&uuml;r medizinische Lehre; Universit&auml;t Bern</a>
IML Deployment &copy; '.date("Y").' <a href="http://www.iml.unibe.ch/">Institut f&uuml;r medizinische Lehre; Universit&auml;t Bern</a>
</div>
';
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment