Git Product home page Git Product logo

check's Introduction

Contao check

With this script you can check the Contao Open Source CMS system requirements, validate an existing Contao installation or set up a new Contao installation.

What's included

Here is a short overview of what you can do with the script:

  • Check which Contao versions can be installed;
  • check if PHP is allowed to write files on the server;
  • check if the Live Update service can be used;
  • check if the Composer package manager can be used;
  • check if the extension repository can be used;
  • install the latest Contao version or Contao LTS version;
  • validate an existing Contao installation.

How to use

Upload the /check folder to your server where you want to install Contao. To validate an existing installation, upload the /check folder to the root of your Contao installation. Then open it in a web browser.

Be aware that validation of an existing installation is mainly designed for installations created by using this tool or officially released archives. Therefore, validation just checks the presence and contents of files against a known list of those being part of an official release. This way this tool can help to check if everything needed by an official release has been successfully deployed.

Web installer

The web installer requires the PHP extensions "curl" and "Zip" to be installed in order to download and extract the latest Contao release.

check's People

Contributors

adoebeling avatar fritzmg avatar leo-unglaub avatar leofeyer avatar taca avatar tristanlins avatar xchs avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

check's Issues

Check 2.1 - Fehler in isFastCgiEaccelerator

Wenn $fast_cgi = true und $eaccelerator = false ist, wird trotzdem die function mit return true beendet und dadurch gemeldet, man hätte FastCGI und eAccelerator am Laufen.

Was ist denn das Problem? der eAccelerator oder FastCGI oder nur wenn beides zusammenläuft?
Auf alle Fälle muss die nachfolgende Auswertung abgeändert werden in der function.

Abschnitt Installation

Im Forum oft zu merken, das besonders der letzte Punkt von

  • Install the latest Contao version
  • Validate an existing Contao installation

nicht als Link war genommen wird.
Die Nutzer sind der Meinung, wenn alles grün, wurde die Validierung bereits durchgeführt.
"Install" und "Validate" als Link und deutlicher gegenüber den Rest, oder nach dem Text noch ein "-> Start" oder ähnliches wäre jetzt ne Idee auf die Schnelle, aber ich bin kein Designer :-)

Web-Install ruft falschen Pfad für Installation auf

Ich hab den Check mal verwendet um contao 2.11.5 zu installieren... gestartet, dateien geladen ok.
dann beitet mir das Install-Tool an, die Installation gleich zu starten. Das ist klasse, jedoch funktioniert das nicht.

Contao 2.11.5 wurde ins Verzeichnis "/contao-check-6295bf7/contao-2.11.5" entpackt, der Link zum Aufruf der Installation für aber einfach nach "/contao-check-6295bf7/contao/install.php"

Web install does not install hidden files in the root directory

When I install the newest (or any other version) of Contao in the web install of the check tool, there isn't any .htaccess.default and .gitignore file in the installation. Checking the installation with the check tool results in a message about these two missing files, too.

'Unknown locale de_de'

Im Forum kam bei jemandem heute die Meldung:

Fatal error: 
Uncaught exception 'Exception' with message 'Unknown locale de_de' in /www/htdocs/check/bootstrap.php:150 
Stack trace: 
#0 /www/htdocs/check/bootstrap.php(36): Bootstrap->setLocale('de_de') 
#1 /www/htdocs/check/bootstrap.php(180): Bootstrap->initialize() 
#2 /www/htdocs/check/index.php(13): require('/www/htdocs/ch...') 
#3 {main} thrown in /www/htdocs/check/bootstrap.php on line 150 

Add a connection test in the file repository.php

Im Forum gibt es nicht wenige, die SOAP installiert haben, aber eine Firewall die Verbindung verhindert.
Daher wäre es von Vorteil mittels Testverbindung zu prüfen ob der Verbindungsaufbau funktioniert.

Als Beispiel wird dieser Test verwendet, den müsste man natürlich noch etwas anpassen:

<?php
$fp = fsockopen("www.contao.org", 80, $errno, $errstr, 10);
if (!$fp) {
    echo "$errstr ($errno)<br />\n";
} else {
    echo 'contao.org aufgelöst (DNS OK) und Verbindung erfolgreich.';
    fclose($fp);
}
?>

The french language is not loaded

The french language is not loaded, because $this->getAcceptedLanguages() returns 'fr_FR' and this language is not in the 'locale' folder.

To work, I change the line 66 of boostrap.php with :

// Find the locale or ISO language code
if (in_array($tag, $locales) || in_array(substr($tag, 0, 2), $locales)) {

instead of :

// Find the locale or ISO language code
if (in_array($tag, $locales) {

Show the detected Contao version

Ich würde es gut finden, wenn der Contao-Check die Konstanten VERSION und BUILD aus der constants.php beim Validieren einer bestehenden Contao-Installation irgendwo als Hinweis/Bestätigung ausgeben bzw. anzeigen könnte.

In der Validator::findConstants() wird ja geprüft, ob die constants.php existiert und - falls dies zutrifft - eingebunden. Über die beiden abgefragten Konstanten VERSION und BUILD wird dann in Validator::checkVersion() zunächst überprüft, ob es für die erkannte bzw. identifizierte Version auch eine entsprechende JSON-Versionsdatei gibt, welche dann in der Validator::validate() für die Validierung einer bestehenden Contao-Installation verwendet wird.

Das Problem bei der ganzen Sache ist: Wenn die constants.php nach einem Update nicht richtig aktualisiert wurde (aus welchen Gründen auch immer), prüft der Contao-Check die aktualisierte Installation möglicherweise mit dem falschen JSON-File und wird dann ziemlich sicher eine Vielzahl an Dateien (fälschlicherweise) als "Corrupt" oder "Beschädigt" beanstanden. Würde der Contao-Check aber irgendwo anzeigen, welche Contao-Version identifiziert wurde bzw. gegen welchen Versionsstand die Validierung durchgeführt wird, hätte man zumindest einen Hinweis darauf, dass hier offensichtlich etwas nicht stimmen kann. Wenn man beispielsweise gerade erst ein (manuelles) Update von Version 2.11.5 auf Version 2.11.6 gemacht hat, der Contao-Check aber nach wie vor als Versionsnummer die 2.11.5 ausgibt, dann sollte/könnte man dieser Diskrepanz auf den Grund gehen und die constants.php entsprechend selbst überprüfen.

Valid Check

Invalid Check

Better overview - feature request

I like this tool.
Just from the point of view as a fist level sporter i miss a overview where i can see if there is everything OK or not. With the old tool it was a matter of scrolling to see everything. With the new tool it is a matter of clicking min. 4 times to see it :-)

I would propose a overview like this:

Contao Check

I still need to click 4 times to get the info, but at least next time i open the check I see what's up.
( - Validate an existing Contao installation (Contao 2.11.5 / 0 Errors) )

As a alternative a link who brings up a contao-check.txt (overview) would be great to.

Improve permission check

I just got the following notice regarding requirement of the safe mode hack.

The test folder is owned by xxx (should be xxx) and has the chmod settings 770 (should be 775, 755 or 750).

I assume 770 is also a valid permission, if 750 is?

Validierte Version anzeigen

Hallo Leo,

die folgende Zeile ist irgendwie lustig... 755 should be 755

The test folder is owned by xyz (should be root) and has the chmod settings 755 (should be 775, 755 or 750).

Ich hätte gerne bei einem positiven Test trotzdem die Version angezeit

validate.php:272

Check extensions

Extensions add extension_name/config/check.txt with the hashes for their files (possibly generated by the autoload creator or alike). The Contao check tool can now also verify extensions for missing, extra and corrupt files.

Checking for SMH: Creating folder returns false negative

I'm running a Debian server with PHP 5.2.6 (yes, it's old, but it's a Debian-patched version) under Apache with suPHP. Apache runs as www-data, the PHP scripts run as the specific user (in my testing case: rabp).

Result from "Do I need to use the Safe Mode Hack?" in Contao Check 4.1:

  1. safe_mode NOT enabled (GREEN).
  2. Test folder could be created but does not have the correct owner (RED). Should be: root, is: rabp.
  3. Test file could be created (GREEN). Owner is: rabp.

I never had a problem with Contao running without the Safe Mode Hack and the former Contao Check also returned ALL GREEN. Thus, the new Contao Check most likely returns a false negative. The code testing the folder permissions must have changed compared to the old Contao Check. Why is the file checked for a different owner than the folder?

More strict check is needed to "download" file.

Currently, install() in check/install.php check the downloaded file with file_exists() function.

But when download is failed (by wget or curl), file "download" with zero size may exist. So, size of the file should be checked at least.

Languages for Contao

It would be nice if we can choose the languages for our installation. We can select only the languages we need before the download.

check für ältere Installationen

Hallo Leo,

die Versionsabfrage in der index.php sollte nur als Hinweis kommen.
z.B. You need at least PHP 5.3.2 to run Contao (you have version 5.2.0-8+etch16).

Auf diesem Server läuft noch eine 2.10.4 die so nicht gecheckt werden kann.

Änderungen in der index.php
Zeile 33 ändern in
Zeile 50 löschen

Die Fehlermeldungen wie phar not enablend sind ja zutreffend.

Herzlichen Dank

Provide a language switch

There is a routine to switch the language already, which can be triggered with a URL parameter:

  • ?lng=en
  • ?lng=de_DE

However, there is no clickable language menu yet.

Check 2.1 - Webinstaller - Zwei Hinweise

Nummer 1
Beim Webinstaller kommt der folgende Hinweis: "Achtung: Veraltete Versionen können Sicherheitslücken enthalten! Installieren Sie die aktuelle Version oder die aktuelle Long-Term-Support-Version."

Wenn man am Ende der Meldung noch das Kürzel LTS hinzufügt "Long-Term-Support-Version (LTS)" und dann in der Dropdown-Liste die letzte LTS-Version ebenfalls kennzeichnen: "Contao 2.11.5 (LTS)" wird die Meldung für nicht Contao-Experten vielleicht etwas aussagekräftiger.

Nummer 2
Könnte man nach einer erfolgreichen Installation nicht noch die Contao-Version erwähnen:
Installation abgeschlossen
Contao 2.11.5 wurde im Ordner /home/www/blabla installiert.

download file has a wrong content

Hi,

i've tried the new Contao Check 2.2. All requirements are green and working.
If i try to install Contao through "Install the latest Contao version", everything works fine until the installer is download the file "download".

You can find the content of the file in http://pastebin.com/ZaEnLVBX

I think Sourceforge redirects the installer, so the wrong content is written to the "download" file.
The URL at line 249 is http://sourceforge.net/projects/contao/files/2.11/contao-2.11.5.zip/download

Thanks.

Check outgoing connections to the installation

The Contao check validates outgoing connections for the live update service. However, it does not check for the installation. A client has manually enabled live update service access, but everything else is blocked.

Can we add a check for the install.contao.org domain too, and disable the install button (with a warning) then?

Fatal Error unter PHP 4.4

Wenn am Server PHP 4.4 installiert ist wird beim aufrufen des Checks folgender Fatal Error ausgegeben:

Parse error: syntax error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or '}' in /web/WebSites/d/f/o/n/fontana-international.com/htdocs/contao/check/bootstrap.php on line 27

Man sollte hier einen Error Ausgeben damit man versteht das eine andere PHP-Version benutzt werden muss.

Define some files as optional

An installation is up to date even if the files for "Music Academy" are not installed.

With ".gitattributes" and ".gitignore"

Maybe add a section "optional files".

capture decran 2013-10-27 a 15 59 33

Falsche Bewertung der Berechtigungen

'Owner' des html Verzeichnisse: 'ftp-user'
'Gruppe' des html Verzeichnisses: web

Verzeichnisrechte: 2775
Dateirechte: 0664

umask: 002

webserver-user und 'ftp-user' sind Mitglied der Gruppe web, somit haben beide das Recht Dateien/Verzeichnisse anzulegen.
Mit dieser Konfiguration braucht man keinen 'Safe Mode Hack' aber das 'check' programm ist der Meinung man braucht ihn, was schlicht falsch ist.

Improve Output

The current check returns something like

Creating a test folder

The test folder does not have the correct owner or chmod settings.

The test folder is owned by u48155769 (should be u48155769) and has the chmod settings 705 (should be 775, 755 or 750).

which is technically correct. Still I suggest changing this to something like

Creating a test folder

The test folder does have the correct owner u48155769 (with class="confirm")

but does not have the correct chmod settings. (with class="error")

Settings are 705 but should be 775, 755 or 750.

which would be more idiotproof (for guys like me ;-)

Imagick::resizeImage mit prüfen

Habe aktuell auf dem Asteroiden ursa das Problem, das dort die Bilder in der Orginalgröße dargestellt werden.
Umzug von meinem Server auf Uberspace.

Daher wäre es schön, wenn der Contao-Check dafür eine Warning ausgeben würde.

Missing cron.txt

I installed Contao 3 with the new Contao Check. Immediately afterwards I did the validation check. However, the Check complains about a missing file system/cron/cron.txt. Is it necessary to check this file?

Contao Check

Please add 2.11.9.json

passt zwar nicht ganz hierher aber bitte auch im ER die 2.11.9 auswählbar machen bei Versionen.

Web-Installer installiert in einen Unterordner

Wenn ich den Ordner /check/ auf meinen Webspace hochlade, dann erzeugt der "Web-Installer" einen Unterordner mit dem Namen der Contao-Version, zum Beispiel

/check/contao-3.0.RC1/

Die Pfadangaben auf dem Server werden dadurch ein bisschen konfus, besonders wenn ich in der neuen Installation wieder einen Check-Ordner anlege, um die Installation zu überprüfen...

Klar könnte ich die Dateien aus dem /check/-Ordner in den Root-Ordner kopieren, aber dann hätte ich immer noch einen Unterordner namens /contao-3.0.RC1/.

Wäre es möglich, den Ordner-Namen selbst eingeben zu können?
Eventuell sogar eine Ebene höher, also als Brüderchen von /check/?

Verschieben der Daten bei der installation schlägt fehl.

Ich habe es auch gerade noch mal getestet. Und zwar wieder mit contao2go. Es muss ja wohl schon was mit dem Pfad sein:

localhost/vhosts/contao301/check    >>Ausgangslage
localhost/vhosts/contao301/check/contao-3.0.1    >>hierher werden Daten entpackt
localhost/vhosts/contao301/contao/install.php    >>Pfad zum aufrufen von install.php

Ich musste den Inhalt von contao301/check/contao-3.0.1/ nach contao301/ (Projekt-root) verschieben.

Es kommt wenn ich (nach dem downloaden des Archives) das Installationstool starten will dass er die localhost/vhosts/contao301/contao/install.php nicht findet.

Das Verschieben der Daten scheint nicht stattzufinden (gibt es ein Skriptschnippsel wo ich die Pfade testen kann von<>nach?).

Mit 4.2 hatte noch es geklappt in contao2go.

https://community.contao.org/de/showthread.php?33341-Neuer-Contao-Check-mit-erweitertem-Funktionsumfang&p=235245&viewfull=1#post235245

Check existence of InnoDB

I got the following information from one of my customers:

das Rätsel, weswegen bei One.Com die Contao-Installation nicht klappte, ist gelöst.
InnoDB wird von One.Com nicht unterstützt.

Das kam heraus als ich ein anderes CMS installieren wollte, denn bei diesem CMS wurde nach Eingabe der DB-Daten die vorgenannte Fehlermeldung geliefert. Danach startete ich eine Anfrage an One.Com und kam dabei auch auf die versuchte Contao-Installation zu sprechen.
Antwort: Contao-Installation bei One.Com nicht möglich, weil man InnoDB nicht anbiete, nur MyISAM.

Anregung:
Da Sie Contao-Meister sind, regen Sie doch an, dass man bei der Contao-Installation auch eine solch aussagekräftige Fehlermeldung vorsieht.

Noch besser wäre, wenn schon im Contao-Test ermittelt würde, ob InnoDB unterstützt wird. Wenn nein, kann man sich den Installationsversuch ersparen und muss entweder auf Contao verzichten oder zu einem anderen Provider wechseln.

Und: Man sollte m.E. bei Contao (wie auch bei anderen CMS) unter Anforderungen angeben, welche DB-Struktur (InnoDB oder MyISAM) verlangt wird. (Diese Information sollten auch die Hoster aufnehmen, denn nur die Aussage PHP MySQL bringt einen nicht weiter, wenn die benötigte Tabellenstruktur nicht unterstützt wird.)

Mark the LTS version

It might be useful if we could show/mark in the "Target version" select menu the respective LTS version, too.

target_version

Language detection issue

I wonder why the language detection does not work sometimes. I have to run the Contao Check with an URL parameter ?lng=de_DE to switch the language strings from English to German.

HTML Request header:

GET /check/?lng=de_DE HTTP/1.1
User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:16.0) Gecko/20100101 Firefox/16.0
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
Accept-Language: de-de,de;q=0.8,en-us;q=0.6,en;q=0.4,it;q=0.2
Accept-Encoding: gzip, deflate
DNT: 1
Cookie: PHPSESSID=dt9f7ih8f9no2ag2r9ifmnp4s6; BE_PAGE_OFFSET=0
Connection: keep-alive

[Contao Check v4.1]

web install but no write permission

If i try to install the latest contao version with the web installer it seems everything works fine and it shows me that the installation succeeded. but as i do not have write permissions in fact the installation did nothing (install.php line 238).

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.