Ansibilized installer in 17

Breaking this out from a post in another thread:

Current issue discussion for this PR is ongoing. Recognizing that not everyone here may have a GitHub account (yet) so posting the TL;DR to get started.

Something like the next few lines will (ideally) replace the current script installer method, a sort of boot-strap of Ansible to run on the TARGET you are installing on:

su -
apt-get install ansible sshpass git
git clone https://github.com/chrsmj/sng_freepbx_debian_install.git
cd sng_freepbx_debian_install/
git checkout ansible-ize
cd ansible-role/sng_freepbx_debian/
ansible-playbook -i localhost, --connection=local playbook.yml

…normally, you would run Ansible on your CONTROL machine, and you still can, but for those who want a bash script or just a few copy-pasta lines to run on their TARGET – well there it is.

EDIT: to add some previous fine work by @jfinstrom and YT in this regard.

1 Like

The playbook for this would be much cleaner. That said I doubt this is the final form of anything. I think they simply want a way to get more people involved in testing. I have to imagine they have an iso in progress that just isn’t releasable yet. For early adopters and a certain level of user Ansible and bash scripts are perfect. For the majority of users that just find and use FreePBX one of the things that helps it maintain dominance is the fact that you can install in minutes with minimal knowledge and effort. Also having an ISO download is good for things like gaining marketing data which you don’t get from github. So I think the community should continue down the ansible road but I see it as that a community effort. Hopefully Sangoma will not discourage this route of install after the iso is released even though it becomes a touch of a support nightmare.

1 Like

Per previous FreePBX blog post and AstriCon presentation “FreePBX: A Year’s Journey and the Road Ahead” a couple weeks ago, the ISO Is So Over.

Ansible might be a bit overkill for this unless it is already being used in the infrastructure or mass deployments. I agree that it should be something available but as something for the community and those that might need it.

I missed that snippit. I know why they are doing it but it’s not going to turn out well.

Yikes, I hope not.

To quote @ncorbic

Debian OS : A move to Debian will allow FeePBX customers and users to perform inline upgrades in the future as well be able to install FreePBX on any public cloud debian native image. FreePBX will rely on vanilla Debian ISO images going forward which will remove the need for Sangoma to build custom ISO and custom packages, which will result in faster OS and Security updates.

Lots of cloud providers offer Debian 12 VMs that you install by selecting the OS from a drop-down menu. Most cloud users probably don’t even see the ISO anymore (nor is it always that easy to upload your own.)


However, getting deeply off-topic here, if you are using the Debian 12 ISO to install, then you can make it even better than the old ISO by taking advantage of the installer’s preseed system for “Hands-off” installations eg. pre-configure away the prompts for almost any package, fine-tune the disk partitioning, run arbitrary extra scripts at late install, etc.

From "Hands-off" Debian Installation …

For example, you can type something like the following at the boot prompt:

boot: auto url=hands.com classes=desktop;loc/gb

and get a Gnome (default desktop) machine installed, with a UK keyboard and timezone, without having to type another keystroke until the login prompt pops up about 10 minutes later.

1 Like

Fleshed out the bootstrap ansible-ized installer on the PR:

https://raw.githubusercontent.com/chrsmj/sng_freepbx_debian_install/ansible-ize/alt_sng_freepbx_debian_install.sh