User:Maffblaster/Infrastructure

Article description::A place where I keep some infrastructure tips.

CLI
Get the CLI program from the GURU ebuild repo:

Download and import the blockchain (optional). Download will take a while. As of Nov 10, 2021 the blockchain is just over 80 GBs and downloads on average of 2 MB/s.

Blockchain import does not appear to be working when run as a non-root user... Simpler to do a P2P download through the daemon.

Generate a wallet (if not done already).

Add the wallet to the daemon's configuration file:

GUI
Add  to global use flags for Qt:

Add the following

GemNotFound errors
Problem: Attempting to run a ruby program results in strange errors

Backups

 * Disk images

guacamole
Upcoming...

sr.ht
Upcoming...

Fixing memory issue
From the commandline, first check for proper dependencies:

In this instance, the current PHP memory limited is advised to be adjusted up, so make the correction for the currently selected PHP implementation:

Restart PHP and then rerun the check above to verify the memory limit has been resolved.

Running the installer
Run the installer from the commandline:

Connecting to Nextcloud
Before connecting via HTTP on any host other than localhost, the trusted domain will need to be configured. This is located in the Nextcloud installation directory, followed by. Edit the file to add additional trusted domains or IP addresses to the array of values.

Modifying the production database location
Depending on the amount of users, a production database may grow quite large. By default, MySQL stories creates its data directory under the directory. This directory may be modified via the datadir variable in the file. Unless the is large enough to hold the database, consider modifying the the datadir path to a suitable location.

Configuring a production database
My default Nextcloud will use an SQLite database. While this database implementation may be good for single user testing purposes, it is not good if the system will be used in any level of production. MySQL will be the database used in this guide.

Install the package:

Add SQL to the default runlevel (OpenRC):

Configure a new SQL database. Follow the prompts as necessary. Be sure to record the root user's password in a place where it will not be lost.

Start the SQL server:

Configure PHP to use MySQL
Upstream's guide

MySqli

Fill in the following as necessary, substituting  with a new username and   with a strong, random passwords. As stated above, be sure to record this information in a secure place.

Then, from the web root, run:

Sadly a workaround is required for database conversion on Nextcloud 21.

hief image preview support
In order for Nextcloud to include render support for hief images in the web browser, Imagemagick must support the hief file format.

External resources

 * Free Software Foundation Europe - Infrastructure living the ideals of software freedom