Installing x84 BBS on Raspberry Pi Zero running FreeBSD 11

19, Feb, 2017

Back in the 80s, I had an Apple ][gs with a 1200baud modem. I lived in farm country and everything was long distance. The next town over was 9 miles away. Because there was a county line there, it was an intraLATA call and long distance. I did have a friend in the next town and we connected via modems to chat and transfer files. Everything was all manual modem AT commands but it was fun. The problem was that my parents didn’t like me tying up the phone line for too long. Plus it got expensive for teenager with little extra cash to pay for the phone bill. Kids and parents worrying about overages is not a new thing. ;-)

I had a subscription to The Computer Shopper and it was a massive catalog packed with articles and ads from every computer company of the time. It took a lot of time to go through every month (usually the next issue was here before you were done). It was a great wealth of computer information in the pre-Internet days. I learned about dialup Bulletin Board Systems (BBS) and tried dialing up a few free boards but rarely staying on for very long at a time because I knew it was going to rack up the bill quickly.

Bulltin Boards started falling out of popularity as the Internet came on the scene. A lot of the functionality provided by a BBS was now available on websites. Many shut down and a few added telnet so you could reach them over the Internet. There’s still many BBS that are still running today. I decided that maybe it’s time to finally go play with some BBS since I didn’t get much of a chance the 1st time around.

I decided to run this on my Raspberry Pi Zero because the single core ARM runs the ANSI screens at a reasonable speed. The original Raspberry Pi A or B model would be good candidates too. I tried it on a quad core system and the screens went by way too fast to read/see properly. Logins are a little slow but that’s keeping with the feel of how things used to be. I bypassed a lot of proprietary BBS software because it wasn’t going to be able to run on my hardware/OS and didn’t give you much room to tweak. I wanted to keep to software that could run on many platforms (python, ruby, etc.). I did find a node.js BBS that looked nice but there’s not a lot of node packages for FreeBSD/ARM. Then I ran across x84. It’s written in Python and thought it looked very promising. I tried it out and decided it’s a keeper (as long as I don’t find something better).

Down to the actual install: (finally)

Let me help you setup all the pre-requisites and tweaks so you don’t have to spend hours of googling and trial & error. I went through 3 or 4 installs to figure this all out. Here’s some packages to get everything prepped for the install.

sudo pkg install gcc py27-pip py27-sqlite3 py27-gmpy 
py27-wcwidth py27-requests py27-six py27-more-itertools  
py27-jaraco.timing py27-jaraco.util py27-irc py27-dateutil 
py27-feedparser py27-html2text py27-pycparser py27-cffi 
py27-bcrypt py27-idna py27-pyasn1 py27-enum34 py27-ipaddress 
py27-cryptography py27-ecdsa py27-paramiko py27-openssl 
webpy py27-cherrypy curl bash

FreeBSD uses some cross-compile tools on some embedded platforms (mips, arm, aarch64, etc.) which aren’t used in this setup and will cause build errors. Change all references of /nxb-bin/usr/bin/cc to /usr/local/bin/gcc in /usr/local/lib/python2.7/ to remove the cross-compile dependencies and allow gcc to build the remaining modules.

sudo sed -i 's//nxb-bin/usr/bin/cc//usr/local/bin/gcc/g' 

Install x84 via pip. The option with_crypto enables ssh and ssl if you want to use the embedded webserver. You can omit this if you want telnet only though ssh would be recommended.

pip install --user x84[with_crypto]

Start it up (~/.local/bin/x84) to generate the default config. Let it finish starting up then control-c to kill the BBS.

Edit ~/.x84/default.ini and change to the IP address of your network interface. You can also set bbsname while you’re editing.

Fire it back up in tmux (or screen if you prefer). Login with telnet on port 6023 or ssh -p 6022 new@bbsaddress (or anonymous@) to register a new user. The first user setup is automatically a sysop and can change system settings from within the BBS.

Screenshot of default setup. I used cool-retro-term with DOS profile set to at least 80 column wide. Nothing like adding scanlines, phosphor refresh, static, etc. to make it feel more old school. Hyper Term has a similar retro theme.

Now you have a default install of x84 BBS running on your Raspberry Pi. Time to read the docs to learn how to use and customize your setup. Read the doors section to figure out how to run any external ascii/curses program from the menu (returns to the menu after exit). I’ve played with silly apps like nyancat, cmatrix, etc. but have been messing with frotz to play old Infocom text adventure games too. I’ve looked through every command line, curses game for FreeBSD on Freshports to see what might be a good fit on my BBS.

The ansi screen files are in the following location:

You can view and edit ANSI/ASCII files with PabloDraw. It’s not a bad idea to have figlet, cowsay, etc. to generate some ascii art to get you off the ground. You can view and download some ANSI files from the Sixteen Colors ANSI Art site.

Moved from Wordpress to Flatpress

9, Jul, 2014

My website has gone through several iterations over the years (static, Blosxom, Seredipity, Wordpress).

There’s an old post detailing some of it: Install a weblog

I’m not sure how I missed posting about the change from Seredipity to Wordpress later but I’ve been running Wordpress for a few years now. I got tired of fighting with Wordpress and thought about changing for a while now. Every so often a plugin would screw up, throw blank pages and then starts the troubleshooting session. Then there’s the hammering of the server with bruteforce login attempts and cleaning up after hackers exploited the built-in theme editor (why is it even there?). It’s definitely been quite the love/hate relationship with Wordpress for me. I just wanted something simpler for this site, I still think Wordpress can be a great solution if you’re willing to work with it.

I went back to look at Blosxom (along variations like PyBlosxom, etc.). I saw several options like Octopress out there for people that were tired of dealing with the Wordpress (and other kitchen sink solutions) and the overhead in databases, security issues, etc. While the overwhelming number of themes and plugins of Wordpress were nice, they were also part of its issues.

I found Flatpress and loved how streamlined it was. There’s no database to worry about since it’s all stored in text files. It’s lean while still having all the basics needed. I familiarized myself with it and found a theme I liked (just added my header from the old site). I started copying and pasting posts from the Wordpress site. I had all the posts over in short time (there’s only a couple dozen posts to move). There’s some examples of scripts going in either direction out there. I couldn’t really tell you how well they worked. I’d probably have tried them if I had hundreds (or more) posts to convert.

I just needed to tweak the picture sizes to fit the theme width to be done. I was so happy with the results, I went ahead and made it the live site. I just needed to move a couple things over that were outside the Wordpress install and create a symlink to keep from breaking the picture path. I went back and edited out the wp-content out the path on the posts to move forward. I’m looking at doing some 301 redirects for the search engines to find the moves but am not seeing too many 404 on pages so I might just leave it alone.

I think it’s going to work great but I’ll just run it on my personal site for now to tweak and geek around for a while. I’ll consider moving the family site later if nothing else pops up with Flatpress. I doubt it will since it’s already doing everything I need. There might be a couple things to try (Twitter post integration, gallery integration, etc.) with the new site but no deal breakers since I’m happy with it the way it is at the moment.

Yes, I realize there’s a couple posts from ‘07 with broken pictures. They’ve actually been broken for 4 or 5 years when I combined and I wish you’d told me about it back then when I still had backups from then and could have restored it. Now I’ll just have to recreate them or just let it be.

Fixed the pictures. Well, figured out one, found a close one and copied the FreeBSD screenshot which was almost identical.

*edit again*
Put Redirect 301 (permanent moved) from the old URLs to the new URLs by hand (again, not *too bad* with a handful of posts) so the webcrawlers/bots can find the posts since they are my largest audience (hah).

  • Posted by dale in in Geek

It’s Dangerous to Go Alone

3, Oct, 2013

The original Legend of Zelda game started out with Link standing out in the open with a shield and no weapon. You walk into the cave on the first screen and this old man gives you a sword.

There was a graphic going around that had the old man and it said “It’s dangerous to go alone! Take one of these”. It had several swords across the bottom and you’re supposed to cut the bottom into strips so they can be torn off. It’s like the ads people put up with their phone numbers except you tear off a sword instead of a phone number. I put it up at work and several people loved it and took a sword (mine is still pinned to my bulletin board). I eventually ran out of swords and took it down.

Recently there was a Star Trek version of this going around. It has Captain Kirk and at the bottom is several expendable redshirt crew members. I put this up at work and got to thinking about other versions of this that I’d like to see. I came up with several different ideas and picked a couple to start with and that’s what I have posted today. Maybe I’ll get around to some more later. Enjoy

Gotta have some Dr Who and a sonic screwdriver. It’s the 11th, 9th/10th and 4th Doctor’s screwdrivers.

Star Wars is still one of my favorites. I originally was going to go with Obi Wan handing out the lightsabers but decided old-school Yoda and Yoda-speak would be better.

  • Posted by dale in in Geek