You need Kannel setup to report SMS messages to
kannel-sms.php?token=TOKEN. These instructions are out of scope.
- Install the LAMP stack on a Debian 12 box (tip: do not forget php-curl!).
- Clone this repo in your
/var/www/htmlor similar directory - Install PHP Composer and run
php composer.phar install - make a
../config.phpfile with the following content:
<?php
global $config, $content_path, $userupload_path;
$config = [
"db_hostname" => "localhost",
"db_username" => "blamba",
"db_password" => "SECRET",
"db_database" => "blamba",
// for security reasons, we want to run a sandbox with imagemagick.
// imagemagick is a pretty complex application and so it's easier to just debootstrap a full, empty debian:
// debootstrap --arch amd64 --include=imagemagick bookworm /opt/bookworm-imagemagick/
"imagemagick_root" => "/opt/bookworm-imagemagick/",
"tempdir" => "/dev/shm/blamba/",
"use_secure_cookies" => false,
"wap_domain" => "wap.blamba.de",
"smpp_sender_msn" => "YOUR NUMBER HERE",
"smpp_sender_alpha" => "Blamba",
"sms_sender_allowlist_override" => [
],
"log_token" => "SECRET",
];
$content_path = realpath(__DIR__ . "/blamba-content/") . "/";
$userupload_path = realpath(__DIR__ . "/blamba-usercontent/") . "/";-
Add
SetEnv ap_trust_cgilike_cl 1to your Apache VirtualHost config. Content-Length header is being set by PHP. Apache2 usually doesn't trust Content-Length headers, which then results in a missing progress indication on file downloads. -
Add
AllowOverride Allin your Directory config in/etc/apache2/apache2.confand runsudo a2enmod rewrite -
Make the database in MySQL
CREATE DATABASE blamba; -
Import the database
mysql -u root -p blamba <blamba_empty.sql -
Create a Kannel gateway in MySQL
INSERT INTO `gateways` (`id`, `name`, `enabled`, `token`, `type`, `sender_msn`, `sender_name`, `location`, `kannel_url`, `kannel_username`, `kannel_password`, `smpp_hostname`, `smpp_port`, `smpp_username`, `smpp_password`) VALUES (1, 'NAME', 1, 'SECRET', 'kannel', 'NUMBER', 'Blamba', 'Bevel', 'http://localhost:13014', 'kannel', 'SECRET', NULL, NULL, NULL, NULL);- Rename the assets folder:
cp -r assets-int assets - Edit your URL in
layout/header.html - Import assets
git clone https://github.com/blamba-de/blamba-content-ingest.gitand copy the folders to your filesystem root - Setup imagemagick in debootstrap:
apt install debootstrapthendebootstrap --arch amd64 --include=imagemagick bookworm /opt/bookworm-imagemagick/ - Install sandbox dependancies:
apt install bubblewrap libseccomp-dev - Compile the bubblewrap wrappers:
cd /var/www/html/vendor-native/bwrap-seccomp && make - Compile the ringtonetools:
cd /var/www/html/vendor-native/ringtonetools && make - Give PHP access to your tmp folder:
chown www-data /dev/shm/blamba/