Posts

Showing posts with the label YAML

https://www.vultr.com

The Everywhere Cloud

Deploy an instance.
Accelerate your application.


Disable Caching in Drupal 8

Image
The following procedure disables some caching features in Drupal 8 that prevent changes in the site from taking effect immediately. If  Drupal is chosen as the user interface , instances where its caching might be undesirable include (1) web-based Supervisory Control and Data Acquisition (SCADA) applications in engineering , and (2) real-time computational reports for scientific telemetry . ========== 1. In the Drupal folder, open the file that handles the Drupal settings. sites/default/settings.php 2. Scroll to the bottom of the file and add the lines marked "Drupal8" as follows. // BEGIN CODE // ... // Disable some Drupal caching. $settings['container_yamls'][] = DRUPAL_ROOT.'/sites/development.services.yml'; //Drupal8 $settings['cache']['bins']['render'] = 'cache.backend.null'; //Drupal8 $settings['cache']['bins']['dynamic_page_cache'] = 'cache.backend.null'; //Drupal8 // END...

Enabling REST Apps in Home Assistant

Image
The following procedure shows how to make Home Assistant communicate periodically [ every thirty (30) seconds, by default ] with other endpoints like remote devices or web services. This is made possible by the polling mechanism of its REST "sensor" platform. By default, the "sensor" polls those endpoints for new data every thirty seconds. ========== 1. Log in as the system account (-u), with $HOME "bin" included in $PATH (-i). user@host: $ sudo -i -u homeassistant 2. Go to the directory containing the YAML configuration files. user@host: $ cd ~/.homeassistant 3. BACK UP the main YAML configuration file. user@host: $ cp configuration.yaml configuration_yaml.back 4. Open the main YAML configuration file. user@host: $ nano configuration.yaml 5. Add the following YAML lines and save the file. # BEGIN CODE # ... sensor:   - platform: rest     name: "Dyn Check IP"     resource: http://checkip.dyn.com     method: GET...

Enabling HTTPS in Home Assistant

Image
The following procedure activates HTTPS for the Home Assistant server. The secure protocol uses TLS/SSL certificates to encrypt the data transferred between user and server. Although it is possible to make this home automation system, whether in  Linux or  FreeBSD , accessible over the Internet, Home Assistant is usually operated within private networks, either physical or virtual. In this case, self-signed certificates may be acceptable to use and quicker to deploy. ========== 1. Log in as the system account. 1.1. Linux, with $HOME "bin" included in $PATH (-i) of system account (-u). user@host: $ sudo -i -u homeassistant 1.2. FreeBSD, coming from "root" superuser. root@host: # su - homeassistant 2. Go to the Home Assistant configuration directory. user@host: $ cd ~/.homeassistant 3. Make a directory for SSL certificates. user@host: $ mkdir ssl 4. Ensure that only the system account and members of its group can access the directory. user@host:...