First we export the checks on the nodes we want to monitor: @@nagios_service { “check_unicorns-${::hostname}”: host_name => $::hostname, service_description => ‘Unicorn Status’, check_command => ‘check_unicorn-${::hostname...

...Then we realize the resources on the Nagios server Nagios_service <<| |>> Now it is quite easy to create new monitoring checks with Puppet. With the ease of creating monitoring checks...

gaslight.co

We’ve been working on one of our first Angular projects with a Rails backend. It’s been a great...

makandra dev
github.com

A small library to provide the Rails I18n translations in Javascript clients.

integrityapp.com

Integrity is the angel watching over your shoulder while you code. As soon as you push your commits, it builds...

...reset between examples. You know what running tests in parallel and on a CI server requires from your test setup. Resources Read what's new to you, skim what's...

...synchronize method — matchers poll, actions run once; the three processes involved (test runner, app server, browser); synchronize for coupled interactions 📄 Capybara::Node::Finders and Capybara::Node::Matchers — the API reference...

...Eventually you will want want the same detection logic to be available on both server and client side. This card shows how to get a Ruby method touch_device? for...

...code, it can just merge all files together. You may need to restart your server if you add files to config/locale. Using subfolders You can also use subfolders, but then...

makandra dev

...origin requests. It defines under which circumstances a cookie should be sent to the server, putting cookies into three different classes: SameSite=None Send the cookie whenever a request is...

...a very narrow scope Has no separate build process in development. Instead the Rails server directly compiles the asset whenever it renders a javascript_tag, stylesheet_tag or image_tag...

...example project and resources below: What "packs" are How to use the webpack dev server How to add and remove npm packages with yarn How import and export of relative...

...the xlog.db file? The file contains metadata about your wal archive on the barman server. It's updated when new WAL data arrives or when barman deletes outdated WAL data...

...BY c.relpages DESC; This requires superuser permissions to install the amcheck extension to the server. If you're a makandra customer, we've already added this extension for you.

...Test All Indexes In All Databases? If you have admin permissions on your database servers, you can use this script to check all databases on your server: #!/usr/bin/env bash

...and other secrets available to the job. The output is uploaded to the GitLab server and visible in job logs...

...good thing. It's possible to configure this requirement at the web- or proxy server level, where nginx or apache will just redirect every request on http to https. Some...

...application directly on the VM it's running and usually it's the proxy server or webserver that does handles SSL, the port where the application is running is often...

Getting an entire test suite green can be a tedious task which involves frequent switches between the CLI that is...

...use to describe nontrivial migrations in Rails / ActiveRecord. Note that the techniques below should serve you well for tables with many thousand rows. Once your database tables grows to millions...

...Network tab: request rows, timings, response sizes, throttling Exercises Work on your local development server throughout — no staging needed here. Create a slow page Create 7500 movies in MovieDB (hint...

...doing it in a single transaction is much faster). Measure the server tail -f log/development.log and load the movies index. Learn to read the request log: which queries ran, and...

...an exception has no mapping, Rails will assume a status code of 500 (internal server error) and will render a red "We're sorry, but something went wrong"

...value and produce a lost update. The Postgres-native fix is to compute the increment server-side inside an atomic INSERT...

...ON CONFLICT DO UPDATE statement and gate it by...

...already entered something into the next field before Unpoly updates that field with a server response, discarding your changes. The steps I wait for active ajax requests to complete (if...

You can choose not to care. Since e.g. making JSON requests for HTML services is not supported use of your page, you don't have to support them with...

...Not found error, which is slightly less correct than a 406, but will serve your purpose. Option: Check the format in your actions You can write something like this in...

...maximum number of Passenger workers and Sidekiq worker. If you have a shared database server many possible connections are "expensive", so setting the pool size to a very high number...

...is no good idea (also consider the number of servers you when calculating the total number of possible connections for the shared database server). Blowing up the fail inbox: If...

...or JS file to your application (e.g. app/assets/application/navbar.sass), you need to restart your development server for it to show up in your browser. This is caused by a limitation of...

...in your application.js. Direct import statements like import 'app/assets/application/navbar.sass' would work without restarting the server. You'll learn the details of esbuild and the frontend build pipelines in a later...

...a custom pretty_inspect as well. It's fairly simple to do and can serve as a fallback if pretty-printing is not applicable. This can also be an alternative...