Download the PHP package lucatacconi/crunz-ui without Composer
On this page you can find all versions of the php package lucatacconi/crunz-ui. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download lucatacconi/crunz-ui
More information about lucatacconi/crunz-ui
Files in lucatacconi/crunz-ui
Package crunz-ui
Short Description User interface for lavary/crunz. Integrate Crunz library and funtions: Tabular, monthly or weekly interface to view the scheduled and executed tasks. Quick display of the execution result of the tasks that have been executed (Indicator icons easily show the result). Upload, download, edit or delete tasks. Forced run of the task, even outside the scheduled time with eventual display of the log once the execution is completed. It can be used with integrated Crunz or with a version of Crunz already installed on the system
License MIT
Homepage https://github.com/lucatacconi/crunz-ui/tree/master
Informations about the package crunz-ui
Crunz-ui
Crunz-ui starts from the most famous GitHub Crunzphp/Crunz project and it's proposed to be its natural graphical interface, developed to make its usage more accessible and easy to use. Designed to be extremely light, it uses lucatacconi/silly-vue-scaffolding which guarantees the project its elastic and dynamic structure.
Table of Contents (click to expand)
- [What Crunz is and how Crunz-ui connects to it](#what-crunz-is-and-how-crunz-ui-connects-to-it) - [What else can Crunz-ui do](#what-else-can-crunz-ui-do) - [Browser Support](#browser-support) - [System Requirements](#system-requirements) - [Pre-installation safety warnings](#pre-installation-safety-warnings) - [Installation and application setup](#installation-and-application-setup) - [Docker setup](#docker-setup) - [Composer setup](#composer-setup) - [Never used Crunz before](#never-used-crunz-before) - [Usage on a previous installation of Crunz](#usage-on-a-previous-installation-of-crunz) - [Custom log directory configuration](#custom-log-directory-configuration) - [Accounts configuration](#accounts-configuration) - [Ubuntu/Debian setup example](UBUNTU_EXPL.md) - [First login](#first-login) - [Contributing informations](CONTRIBUTING.md) - [Roadmap](ROADMAP.md) - [FAQ / Troubleshooting](FAQ.md) - [Lazy Developer Shortcuts](LAZY_AREA.md):information_source: Use the link below if you want to skip information about Crunz and Crunz-ui and go straight to setup procedures:
Shortcuts to Docker and Composer setup procedure
What Crunz is and how Crunz-ui connects to it
Crunz is an application that allows users to schedule tasks natively written in PHP, programming date and time of start, interval and conditions of execution, and init.
You can find details about Crunz and how to write and schedule tasks at the following address: https://github.com/crunzphp/crunz
Crunz task example:
Crunz-ui natively uses Crunz libraries and functions to read and interpret the configured tasks; then presents tasks in a tabular or graphical display, showing them on a monthly or daily view.
What else can Crunz-ui do?
In addition to displaying tasks in tabular or graphic format, Crunz-ui allows you to:
- Manage tasks through easy-to-use interfaces (create, modify, archive, delete tasks)
- Upload or download tasks with an intuitive and simple file manager system
- Quick display of results of the tasks that have been executed (The indicator icons easily show whether the task was performed with errors or successfully)
- Search and display the outcome of task execution on a specific date or selected through various search parameters
- Forced run of the task, even outside the scheduled time with an eventual display of the log once the execution is completed
Browser Support
Latest ✔ | Latest ✔ | Latest ✔ | Latest ✔ | Latest ✔ | No |
System Requirements
- Linux OS and Bash shell
- Service ntp enabled
- Apache and PHP 7.4 or newer, with rewrite.load module enabled
- Composer
- Sudo capabilities
Pre-installation safety warnings
:warning: Crunz and Crunz-ui need that the operator has the permissions to set up crontab entry to schedule the regular execution of the task management process. Crontab entry owner must be carefully selected: using high permissions level user (ex root) could allow tasks to access sensitive files or perform malicious operations on the entire server file system.
:warning: It is very important to change as soon as possible the default password of the Crunz-ui admin user. Leaving the default password could allow malicious users to access the Crunz-ui task manager and load dangerous tasks with the capability to access sensitive files or perform malicious operations on the entire server file system.
:warning: It is important to keep system clock synchronized. In the case of an unsynchronized clock, there could be misalignments in the execution of the tasks or the management of the user sessions.
:warning: For browser security configurations, copy to clipboard buttons are available only if Crunz-ui is released in localhost or in an https domain.
:warning: In countries where is present daylight saving time switch, there may be discrepancies in the task execution time and task outcome display on the day of the time switch.
Installation and application setup
The two quickest ways to install Crunz-ui are with a Docker container or by installing via Composer
Docker setup
If it is not necessary to install Crunz-ui alongside an existing Crunz installation, the simplest way to install it is to configure the software and do its startup through Docker. The Crunz-ui Docker container is the quickest way to have a running and ready-to-use application.
First of all, download both files to Github server.
- Dockerfile - Docker container configuration file
- Crunz.yml - Crunz standard configuration file
Manually edit Crunz configurations present in the Crunz.yml file. Inside the file, there are suggestions about the individual configuration parameters. Please refer to Crunzphp/Crunz for more details on the configuration.
Initialize Crunz-iu Docker container. Be careful to select the correct timezone before running the command. (ex. TIMEZONE=Europe/Rome)
Start Crunz-iu Docker container indicating the port through which to access the web interface (ex. DEST_PORT:ORIG_PORT 80:80 ):
Access the application via browser (Refer to First login section for connection details)
Please refer to Ubuntu/Debian Docker setup example for suggestion.
Composer setup
Otherwise It's recommended that you use Composer to install Crunz-ui.
Starting from your Apache Server's Document Root folder or from a directory served by a virtual host, begin the application setup by Composer command:
This will install Crunz-ui and all required dependencies.
:information_source: There is no need to set a large max_execution_time property in your php.ini: Crunz performs tasks as if they were run from the console. When running PHP from the command line the default setting is 0 therefore without time limits.
Cruz-ui installed by Composer can work using the Crunz embedded in the packages or using the tasks and configurations of Crunz previously installed on the user's system.
If you have never used Crunz before or want to use the Crunz integrated into the packages, refer to the Never used Crunz before section. If you want to use Cruz-ui on a version of Crunz previously installed on the user's systems, refer to the Usage on a previous installation of Crunz section.
:information_source: By default Crunz checks the correctness of the php code before considering the task file. In case of servers with less computing power, checking the syntax of the tasks considerably slows down the display of tables and statistics. You can set the .env parameter CHECK_PHP_TASKS_SYNTAX to false to inhibit syntax checking. In case of syntax errors in the tasks, configuring parameter CHECK_PHP_TASKS_SYNTAX to false could cause anomalous behavior in the Crunz-ui interfaces
Crunz-ui can also be used with Xampp. However, it is necessary to create a symbolic link of the Xampp's PHP in your system executables folder:
Using Crunz-ui on Xampp with PHP already present on the server in a separate installation from XAMPP, functions "Execute and wait log" present in the Tasks table section menu will fail with the following error: Unable to load dynamic library 'curl.so'. Check FAQ to solve the problem.
Never used Crunz before
Cruz-ui has Crunz packages embedded in its libraries. Once configured, the application can then start viewing, managing and executing tasks.
To configure the application in this way, once Crunz-ui is installed, proceed as follows:
By accessing the project folder, you can use the specific function of Crunz to generate the basic configuration file of Crunz itself:
The procedure will ask the user to provide default timezone for task run date calculations; execution will generate the Crunz configuration file with the default settings. For more advanced configurations, refer to the Crunz manual.
At this point it is necessary to configure all the users who must be able to access the application. Refer to Accounts configuration section to configure users. By default, in the basic configuration, the admin user is configured with the temporary password password.
Then set an ordinary cron job (a crontab entry) which runs every minute, and delegates the responsibility to Crunz-ui event runner:
By default the configured log folder is ./var/logs inside Crunz-ui folder. To use custom log folder configure the .env file with the path of new log folder. The folder must be accessible and writeable by the Apache user.
If you have configured a custom log folder, the crontab configuration must be changed as follows:
Please refer to Ubuntu/Debian setup example for suggestion.
Usage on a previous installation of Crunz
First of all you need to tell Crunz-ui the exact location where Crunz is installed. To do this, edit the .env file inside the main folder of Crunz-ui by un-commenting the entry CRUNZ_BASE_DIR and indicating into that the value of the absolute path of Crunz installation. In order to be able to insert, modify and delete tasks, the Apache user must have access and write permissions to the tasks folder.
Then copy crunz-ui.sh file and TasksTreeReader.php into the Crunz base folder:
By default crunz.ui.sh batch will search for standard log folder ./var/logs inside main Crunz folder. Therefore, if you want to use standard configuration, you need to create default folder for logs. The folder must be accessible and writeable by the Apache user:
Modify the Crunz process, configured in Crontab during the Crunz installation, replacing it with the Crunz-ui process:
Configure, if needed, Crunz-ui .env file with a custom path of the log folder. In this case too it is important that the folder is accessible and writeable by the Apache user. If you have configured a custom log folder, the crontab configuration must be changed as follows:
At this point it is necessary to configure all the users who must be able to access the application. Refer to Accounts configuration section to configure users. By default, in the basic configuration, the admin user is configured with the temporary password password.
Custom log directory configuration
By default, the configured log folder is ./var/logs inside Crunz / Crunz-ui folder. The folder must be accessible and writeable by the Apache user.
To configure custom folder set the .env file with the path of new log folder.
If you have configured a custom log folder, the crontab configuration must be changed as follows:
Accounts configuration
All users enabled to access the application are configured in the configuration file /config/accounts.json.
The accounts.json configuration file has the following format:
Among the various information listed, the type of user is also induced, information that is then used to filter the menu items enabled for the user. For simplicity's choice the access configurations have been inserted in a file. However, nothing prevents the implementation of user management based on database reading.
First login
The application is preconfigured with a single access user to verify the login procedure and access the dashboard and the main menu.
To test access use the login admin and password password
Contributing
This project is maintained by a group of awesome contributors. Contributions are extremely welcome :heart:. Please see Contributing informations for details.
Roadmap
Please see Roadmap for details.
FAQ and Troubleshooting
For help, FAQ or troubleshooting please refer to FAQ and Troubleshooting.
Credits
License
Crunz-ui is licensed under the MIT license. See License File for more information.
All versions of crunz-ui with dependencies
slim/psr7 Version ^1
nyholm/psr7 Version ^1
nyholm/psr7-server Version >=0
guzzlehttp/guzzle Version ^7
laminas/laminas-diactoros Version ^2
php-di/php-di Version ^6
monolog/monolog Version ^2
tuupola/base62 Version ^2
tuupola/slim-jwt-auth Version ^3
tuupola/slim-basic-auth Version ^3
vlucas/phpdotenv Version ^5
twig/twig Version ^3
crunzphp/crunz Version ^3
lorisleiva/cron-translator Version >=0.3.2