Just a quick one.

I’ve been playing about with Node.js some more, and very quickly (alarmingly quickly) hacked together a very simple Node library for talking to the Known API.

The main.js has an example where I will post a status update, but obviously other updates are possible.

Have a play!

» Visit the project on Github...

Known allows you to install Known via the command line, this can be handy for scripted installs, using non-MySQL database backends, or when installing over a terminal connection to a remote server.

The Basics

Go in to /warmup/CLI, and you’ll see CLIInstaller.

To install a brand new Known using an interactive install simply run

The Manifest

A manifest is used to pass configuration options to the CLI installer so that you won’t be prompted for them. This is useful for scripting installs.

First, generate a manifest template:

Next, edit that file and fill in the appropriate option.

Now, you are able to pass these options to the installer:

You’ll also notice I’m specifying the config.ini ini file to write to, you can write this config to other files as necessary, which is handy if you’re using per-domain configuration.

Other options

The CLI installer has a few other options that might be useful:

Checking requirements

If you just want to check that your server has the necessary requirements to run Known, you can execute:

Generate config from manifest

If you want to generate a config file, but without going through the full install (useful if you want to generate a new domain config in a script), you can use the following command to do so

This will output the new config to stdOut. You can save it to an ini file as appropriate.

It was about time I got to grips with Redis, so I put together a quick plugin for Known to add Redis support.

It provides a PersistentCache derived cache, suitable for using with Known, and also
makes it easier for you to use Redis from your code.

Installation

Drop the Redis folder into the IndoPlugins folder of your idno installation.

Due to the way Known loads classes, you don’t need to activate the plugin in order to be able to use the class.

If you want to use the Cache system wide, modify your config.ini as follows:

Note, you need to use at least Known build 20180630.

Have fun!

» Visit the project on Github...