SELECT pg_size_pretty(pg_database_size('some-database')); Example SELECT pg_size_pretty(pg_database_size('cards_p')); ----------------

While working on a Rails application, your code base will grow a collection of different file types including: Ruby (business...

DevOps Curriculum

Beim schreiben von Scripts ist es nützlich Tests zu schreiben um bei Änderungen nicht alles nochmals manuell testen zu müssen...

DevOps Curriculum

Bei Automatisierungsaufgaben kannst du dich nicht immer auf fertige Tools verlassen. Häufig musst du eine Schnittstelle zu einem bestehenden System...

DevOps Curriculum

Based on the Ruby Basics Card in the developer Curriculum Ruby is the programming language we use on the backend...

Instead of using Puppet exported resources you can use the puppetdb_query feature. This can result in more complex code...

makandra Operations

How can I configure virtual IP's? There are two parameter to set up virtual ips in Keepalived: virtual_ipaddress...

tl;dr Since Rails 6.1+ you can use .compact_blank or .compact_blank! to remove blank values from collections (e.g...

When paginating records, we usually need to know the number of total records in order to render pagination links. Popular...

You can use the code below to check whether the browser can make connections to the current site: await isOnline...

When changing code in mailers, updating the corresponding mailer preview can be forgotten very easily. Mailer previews can be tested...

When redirecting you should take care to use the right HTTP status code. From controllers When redirecting from a controller...

It might sometimes be useful to check whether your Rails application accesses the file system unnecessarily, for example if your...

I recently had the problem that embedded code boxes crashed my layout. It turned out that pres break out of...

Code quality can be measured in four levels: (Working code) Reliable code (minimum) Readable code (ok for short-lived code...

There is a way to use multiple databases in Rails. You may have asked yourself how you're able to...

You can use Unpoly's up.on with a named listener function and immediately unbind this event listener with { once: true...

github.com

ruby-warning adds custom processing for warnings, including the ability to ignore specific warning messages, ignore warnings in specific files/directories...

If you're deploying code for your lambda function via terraform, this code is usually zipped and uploaded to Amazon...

If you're using many terraform root modules in a repository, downloading common providers like the AWS one can quickly...

Due to the way we setup Jasmine tests in our projects, you may run into various errors when Jasmine boots...

Redis.current will be removed without replacement in redis-rb 5.0. Version 4.6.0 adds deprecation warnings for Redis.current and Redis.current=: `Redis.current...

While we are used to run our JavaScript tests on a test page within our Browser, it's also possible...

makandra dev

I recently was in a weird situation where my (Jest/CLI) tests were referencing a function that was no longer part...