1. Introduction
Here is described some notes on the process of building the Virtual Machine that hosts the main components.
That VM is initially based on Ubuntu 24.04 TLS, and host the main components, which are:
- Drupal 11, natively installed at the OS
- Dockers whith:
- Portainer to provide a GUI management of the containers
- Node-RED instances for: (one node-red instance for each)
- Data migration from former/legacy apps
- NetBox for IPAM management
- Synchronization via APIs with other components:
- Custom & extended features:
- Self-provisioning script for configurations beyond ACS/TR069 capabilities.
- Extended API endpoints beyond the provided with the above-mentioned tools
As for the hardware requirements, initially the VM is configured with 16Gb RAM, 32Gb Disk & 8 cores
Back to top2. Preparation
Back to topa) System Update
sudo apt-get update sudo apt-get upgrade -y sudo apt autoremoveBack to top
b) apache2
sudo apt install apache2 -y sudo systemctl enable apache2 && sudo systemctl start apache2 sudo systemctl status apache2Back to top
c) mariadb
sudo apt install mariadb-server mariadb-client -y
sudo systemctl start mariadb && sudo systemctl enable mariadb
sudo systemctl status mariadbBack to top
i.- Secure mysql/mariadb
sudo mysql_secure_installation
d) php
sudo apt install php libapache2-mod-php php-dev php-bcmath php-intl php-soap php-zip php-curl php-mbstring php-mysql php-gd php-xml -y
sudo apt-get install ca-certificates apt-transport-https software-properties-common
sudo add-apt-repository ppa:ondrej/php sudo apt-get install libgd3
sudo apt-get --with-new-pkgs upgrade libgd3Back to top
e) verify php
php -v
3. Composer
cd /var/www/html
mkdir commons
chmod a+rw commons p
hp -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" php -r "if (hash_file('sha384', 'composer-setup.php') === 'c8b085408188070d5f52bcfe4ecfbee5f727afa458b2573b8eaaf77b3419b0bf2768dc67c86944da1544f06fa544fd47') { echo 'Installer verified'.PHP_EOL; } else { echo 'Installer corrupt'.PHP_EOL; unlink('composer-setup.php'); exit(1); }"
php composer-setup.php php -r "unlink('composer-setup.php');"
sudo mv composer.phar /usr/local/bin/composerBack to top
a) drush
composer require drush/drushBack to top
4. drupal
Back to topa) Download latest
(drupal 11 as for Dec 2025)
cd /var/www/html
sudo mkdir commons
sudo chmod a+w commons
composer create-project drupal/recommended-project:^11 commonsBack to top
5. Create Database
create database commons11 charset utf8mb4 collate utf8mb4_unicode_ci;
create user commons11@localhost identified by 'password';
grant all privileges on commons11.* to commons11@localhost;
flush privileges;Back to top
6. Install drupall
Back to topa) Initial composer
cd /var/www/html
sudo mkdir commons
chmod myuser:myuser commons
composer create-project drupal/recommended-project:^11 commonsBack to top
b) Apache virtualhost for drupal
sudo vim /etc/apache2/sites-available/commons.guifi.net.conf Alias /commons /var/www/commons/web
<Directory /var/www/commons/web>
AllowOverride all
</Directory>
<VirtualHost *:80>
ServerAdmin myemail@domain.tld
DocumentRoot /var/www/commons/web/
ServerName commons.guifi.net
RewriteEngine On
RewriteOptions inherit
CustomLog /var/log/apache2/commons.guifi.net.log combined
</VirtualHost> sudo a2ensite commons.guifi.net(backup vm w/prereqs)
Back to topc) Site install (drush)
vendor/bin/drush site:install(backup vm post site:install)
Back to topd) Install core modules
cd /var/www/html/commons
vendor/bin/drush pm:enable locale jsonapi rest vendor/bin/drush pm:enable language
vendor/bin/drush pm:enable content_translation config_translation
vendor/bin/drush pm:enable migrate_drupal migrate_drupal_ui migrate
vendor/bin/drush pm:enable telephone vendor/bin/drush pm:enable datetime_range
vendor/bin/drush pm:enable workspaces workspaces_ui vendor/bin/drush pm:enable content_moderation workflows
vendor/bin/drush pm:enable syslog
vendor/bin/drush pm:enable settings_tray vendor/bin/drush pm:enable responsive_image
vendor/bin/drush pm:enable navigation vendor/bin/drush pm:enable media_library media
vendor/bin/drush pm:enable contact content_moderation inline_form_errors layout_builder layout_discovery phpass(backup vm post enable core modules)
Back to tope) Contributed modules
- Back to top
i.- domain
- domain
- domain_config_pages
domain_accessdomain_access_logodomain_aliasdomain_configdomain_config_uidomain_contentdomain_source
- Book
composer require drupal/domain:"2.0.0-beta8" composer require drupal/domain_access_logo:"^2.0" 'drupal/dom'drupal/domain_config_pages:^1.0' 'drupal/domain_path_redirect:^1.8' 'drupal/domain_simple_sitemap:^3.0@RC' vendor/bin/drush pm:enable domain domain_access domain_access_logo domain_alias domain_config domain_config_ui domain_content domain_source
eof
Back to top