Download the PHP package wunderio/drupal-ping without Composer

On this page you can find all versions of the php package wunderio/drupal-ping. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package drupal-ping

Drupal ping helper

Build Status Latest Stable Version Total Downloads Latest Unstable Version License

This script can be used for Drupal8 and Drupal9 health-checks.

Installation

  1. Add this to your composer.json:

  2. Then install the composer package as usual with:

  3. Add _ping.php into the main project's .gitignore.

Changelog

See Releases.

Usage

Checks

Main database

User #1 record is fetched from the database.

Memcache

Assumes $settings['memcache']['servers'] presence in the settings.php.

Following statuses are issued:

Basic networking is used, no Memcached or Memcache class.

Redis

By using Redis class, connection is established to the server.

In settings.php following has to be defined:

This test works on both TCP and Unix Sockets. For the latter only host has to be defined as path.

Elasticsearch

In settings.php following has to be defined:

Elasticsearch check requires separate setting, because there are too many ways how Elasticsearch config can be defined in the settings.php file, depending on many factors.

The connection is establised by PHP curl, and then /_cluster/health is being visited. The check expects to get green status in the response.

Following statuses are issued:

FS Scheme

Consists of 3 tests:

Custom ping

If a site needs any custom checks, then just create _ping.custom.php. Use of $status->setName() and $status->set() to define the result. The PHP file does not need to contain functions, just plain PHP is enough. Check it out how other checks are created in the _ping.php.

Debug Mode

_ping.php can be accessed over the web. For example https://example.com/_ping.php. It can also be accessed from the shell cd /path/web ; php _ping.php. From the shell output the debug token can be attained. Then visit the ping again with https://example.com/_ping.php?debug=token.

The token is generated in one of the following ways. These methods are listed by precedance. If earlier fails (is empty), then next one is tried.

Ping Development & Testing

Setting up development environment

  1. Clone development and testing environment
    • git clone [email protected]:wunderio/drupal-project.git ~/projects/drupal-ping
    • Yes, save it as drupal-ping.
  2. cd drupal-ping/
  3. Clone the ping project itself
    • git clone [email protected]:wunderio/drupal-ping.git
    • Yes, save it as drupal-ping too, inside the folder of the same name. It is the actual repo we are going to work with.
    • Checkout or create your development branch.
  4. Link .lando.yml
    • rm -f .lando.yml - at the top-level folder, remove the Lando conf file.
    • ln drupal-ping/.lando.yml - link the Lando conf from the ping repo folder. Don't create this as a soft (-s) link because Lando would mount the project where the original file is. Therefore create the hard link which is indistinguishable for Lando.
  5. Link .lando/
    • rm -rf .lando - at the top-level folder, remove the Lando folder.
    • ln -s drupal-ping/.lando - link the Lando scripts folder from the ping repo folder.
  6. lando start
  7. Note that the Drupal install will mess up settings.php a bit, don't commit.
  8. https://ping.lndo.site/_ping.php
  9. lando scan
  10. lando test

Development commands

Maintainers

License

MIT


All versions of drupal-ping with dependencies

PHP Build Version
Package Version
Requires drupal/core Version ^8 || ^9 || ^10
koodimonni/composer-dropin-installer Version >=1.0.1
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package wunderio/drupal-ping contains the following files

Loading the files please wait ....