Ramblings of General Geekery

The Death of Google Reader

After the infamous announcement that Google was shutting down Google Reader, there was a lot of debates around the use of online services, especially free ones, and whether we can trust a company to keep such services up indefinitely.

Of course, nothing can last “indefinitely”, and probably nothing will last until you die. You have to expect that Gmail, Facebook, iTunes, Amazon Kindle and any other service you’re currently using won’t last for more than, say, 20 years (and that’s being generous). You need to plan accordingly.

Marco Arment sums this up on his blog:

Always have one foot out the door. Be ready to go.

This isn’t cynical or pessimistic: it’s realistic, pragmatic, and responsible.

That’s what I’ve always tried to do. I choose programs, services and products that don’t take my data away from me. It makes it easier to switch to something else if I need/want to, and it future-proofs what I spend money on.

But that’s where it gets interesting, because Google Reader was pretty open to begin with. Google may have become this data hoarding and privacy raping monster over the years, but one thing they always had going for them was the Data Liberation initiative. With it, you effectively always had one foot out the door. You could, at any moment, download a list of all your subscriptions in an open, standardized format, along with a collection of all your stars, comments, and shares. You may be disrupted for a while because you would need to adapt to a new feed reader, but you could switch, just like you can switch text editors or operating systems.

What’s wrong with the Google Reader situtation has nothing to do with your data, or with using a free service (although that is an important subject too). What happened is that Google Reader became a lot more than a free online feed reader. It became a single choke point for virtually every feed reader or news aggregator in the world. Google is of course to blame for making it a collateral damage of their social-wannabe delusions, but we are equally to blame for letting all those programs like Flipboard, Pulse or NetNewsWire rely on a single service that was never really intended to be used that way. It’s understandable it ended up this way, because relying on Google Reader meant easier adoption for new users and not having to worry about complex problems like data storage, metadata syncing, and interoperability… but it doesn’t make it the right decision either. We are to blame because we were constantly asking for Google Reader support. It became a feature you couldn’t ship without.

The death of Google reader is not about losing a product we love – it’s about breaking an entire eco-system of products and workflows.

Hopefully, we’ll recover and things will be better, but it does bring up another debate: the one about how we rely so much on other single choke points like Twitter and Facebook. Ideally, everything should be federated, like email, but I tried looking at distributed alternatives, and they’re just not working well enough. If the links you share and photos you post are of any value to you, I’d suggest you start looking at data harvesting solutions. I know I am.


The Problem with iOS

These past few months I’ve seen a fair number of articles about people who switched from iOS to Android. Most of those articles talk about the differences between the 2 operating systems, and how some of those differences proved to be significant enough for whoever was switching: multitasking, notifications, the so-called “open vs. closed”, etc. That’s fine, but these specific bullet point list vs. bullet point list comparisons seem to be missing the higher level view of what’s really going on: iOS is just not working the way it should anymore.

When iOS was released in 2007, it made a lot of things easier to do on a phone, compared to the existing competitors. A lot of tasks just felt “right”, or at least “way better”. But it basically stayed there since then. The only real additions, like the notification center or iCloud, are either incredibly badly designed, or are only usable if you have an almost exclusive Apple-based household (which you shouldn’t). When I look at my iPad now, I feel like I’m looking at a computer that hasn’t been updated in years.

If I’m reading something in Safari, I should be able to quickly send it to Pocket, Buffer, Dropbox, or whatever other service I choose to base my workflow on. But on iOS, the only “sharing” services I have access to are those that Apple thinks I should use. For everything else, I need to copy the URL, switch to another app, and find where to paste it. Why?

If I added a few articles to read on Pocket late yesterday evening, I should have them ready on my phone or tablet the next morning so I can read them during the commute. But on iOS, I have to remember to open the Pocket app so it can sync. Why? (note that other apps like Instapaper try to use the Location Notification API but frankly, by the time I leave the house, and therefore lose any WiFi connectivity, it’s already too late).

If I just bought a bunch of PDFs from DriveThruRPG, e23, Arc Dream or Pelgrane, or some comicbooks from Panel Syndicate or Thrillbent, or whatever else I want from whoever I feel like giving money to, I should be able to just download those files onto my device and open them with any application I like. But on iOS, unless it’s coming from iTunes (directly or via in-app purchases, all of which also means 30% of my money doesn’t even go to the people I want to give my money to), I have to jump through many hoops, going first through Dropbox or FileBrowser and then having to re-transfer every. single. file. to each of their application’s sandbox storage. Why? Oh why?

You may not be surprised to learn that all of those things “just work” on Android. And those are just examples of the frustrations I’ve had with my iPad in the past few weeks. You don’t just go “BOOM!” anymore – quite the contrary: you actually have to work harder to make things happen.

Some people might be tempted to boil this down to a simple list of features, like “iOS needs a background service API, shared storage, and more extensibility points for 3rd party apps”. This sounds to me like going back to 2007 and saying “Windows Mobile needs to make the stylus optional, have a grid of icons on the home page, and remove copy/paste”. Really, it’s not just about a bullet point list of features. It’s about the whole philosophy of the system, and of the company behind it. And although Apple seems to be occasionally bowing down to the pressure of the market, like when it released the 7″ iPad Mini, I don’t expect it to change this radically on the design of iOS.

Would I rather have an iPad Mini instead of my Nexus 7 to bring with me everywhere I go? Of course I would. The iPad Mini is thinner, lighter, and has a better screen. But as someone famous once said, “[design is] not just what it looks like and feels like. Design is how it works”. And for me, iOS is just not working well enough. And it never did, really – it’s just that until the competition caught up with the basics, only a minority of users noticed it.


Todon’t

Jeff Atwood posted another one of his controversial, opinionated articles on his blog, this time about To-Do lists. It’s a long rant about the failure of To-Do lists.

As a former Remember The Milk user and fan, I can totally relate. I just stopped using To-Do lists altogether a couple years ago. I just didn’t need them anymore – I knew what I needed to do most of the time:

If you can’t wake up every day and, using your 100% original equipment God-given organic brain, come up with the three most important things you need to do that day – then you should seriously work on fixing that.

But the truth is: I’m still using some form of list, especially since Trello came around. It took me a while to realize the difference between the Getting-Things-Done-ish productivity I tried to achieve in the past, and the more zen-like – and effective – process I have now.

Patrick Rhone eventually wrote it for me:

[…] increasingly, my to do list is full of the things I park there that otherwise get in the way of what I’m actively focused on.

My To-Do lists (hosted on Trello) are filled with stuff I don’t want to do right now, but need to remember for later. I know what I need to be working on right now, but I may forget about stuff I may want to do later. It’s more like a notebook than a To-Do list, really, but the To-Do list format makes it easier to cross things out if they become invalid or if I already did it.


The post-PC era

You can see this kind of headline all over the web these days, especially with Apple fanboy tech bloggers: the PC is dead, all hail tablets and smartphones. The argument is also made for video games consoles, who are supposedly on the way out to be replaced by, guess what, tablets and smartphones. Even Jeff Atwood is getting on the bandwagon.

I don’t disagree with the facts here: most indicators we have on the market right now show that, indeed, desktop and laptop computers have declining sales while mobile products have an ever-accelerating growth.

Untitled

Some tech bloggers, however, are a bit too quick to equate opposing trends with replacement – in reality, people still own PCs and Macs, but complement them with mobile devices. As far as I know, there’s no evidence that anybody is actually getting rid of their laptops and desktop computers after buying an iPad… yet.

Main device of choice

Interestingly enough, Jeff Atwood recently posted an article about the ASUS Zenbook Prime (which, incidentally, is the laptop I bought my wife) as being “the last laptop he may ever buy”. He argued that, more often than not, he would choose a tablet or smartphone when deciding what device to use or take with him, leaving the laptop behind (which sounds dubious from a guy who must spend most of his time in Visual Studio, but whatever).

This, indeed, points at actual replacement. But look at the way he supposedly makes his decision:

  • Want 10 hours of real world battery life?
  • Want to start doing stuff immediately?
  • Want the smallest most portable device you can get away with?
  • Want to be always connected to the Internet?
  • Want easy access?

Those are never the questions I have in mind when deciding what to put in my backpack, or what to take with me around the house. Those are just specs. Some are laughable (seriously, you can’t wait 2 seconds for the laptop to resume from sleep?), and some are kind of obvious (well yes, I won’t take anything too bulky or impractical on the bus, but that’s as applicable to a laptop as it is to a large book, my drawing equipment, or my bass guitar, which I would otherwise very like to take with me always), but they’re all besides the point.

Instead, there’s only one question I ask myself: what do I want to do? And then just take what lets me do exactly that, given the environment in which I intend to do it.

For me, this is almost always the laptop – and I’m not the only one. Some of it is my own personal tastes and workflows (the need for a real keyboard, a big enough screen, a connection to my file server), some of it is because of the software I need to run (Lightroom, Visual Studio or any other development environment, Mercurial or Git, Pro Tools), and some of it is the necessities of the task at hand (using a Wacom tablet or Cintiq, using a high-speed audio interface with several music instruments and microphones plugged-in). All of this basically prevents me from using a tablet even if I wanted (which I don’t really).

What goes in the bag?

The only task for which I consistently pick the tablet is consuming content, like catching up with my “to read/to watch” list, going through social networks and feeds, and enjoying comicbooks.

It’s also the only device I take with me to bed or when leaving the house. Is that a shortcoming of laptops then? Absolutely not. I never planned to write code or tag photos or record music in a crowded subway before, and that hasn’t changed. What I would plan to do is read something, and that’s why I always carried a couple books with me all the time.

Now I just carry one small tablet. It’s not because it’s small or because it has better battery life or because it turns on right away. I have it because it’s the best digital replacement for books (I don’t carry a Kindle or other e-book reader because I tend to read a lot of comics or other illustrated books like RPG books).

For me, the tablet is a definitive improvement (less physical books cluttering the house, lighter and smaller backpack, more pleasant reading experience), but it has barely replaced anything I do on the laptop. The only thing it did replace is Google Reader/Facebook/Twitter in a browser.

I also hear a lot of people saying a phone or tablet is better for quickly checking emails, or looking up something on the web, or whatever. Although I did use my mobile devices for that at the beginning, I found that it was not that much of an improvement. This is because:

  • I stopped compulsively checking my emails and notifications through the day. Now I’m only doing that a few times a day, which means that when I do I will probably have several things to delete/archive/reply to, and that’s just quicker to do on the laptop (you do use keyboard shortcuts, do you?).
  • I have a lot of productivity shortcuts set up on my system. I can look something up on a map or on Wikipedia or IMDB or whatever in less time on the laptop than on my iPad. I know, I actually tested that.

One of the exceptions is looking up recipes. My wife got me a fridge stand for the iPad for when I’m cooking. It’s also easier to clean grease marks on a screen than on a keyboard. But, again, that didn’t replace using a laptop: before I would have a recipe book open on the counter.

The post-PC era

Now, we can try to imagine how this is going to change in the next few years. I wouldn’t be surprised if, at some point, your phone could be paired with an external display, on top of a mouse and keyboard, and get into a mode where it’s running a full-fledged (or legacy) OS that can run more complex applications. In the future, your phone could very well be your wallet, your identity, and your one and only computer, with some storage and possibly computing power extending to the cloud.

Is that when the PC will effectively be dead? No. That’s just when your phone will have evolved into your PC. That’s what Jeff Atwood really hints at:

Our phones are now so damn fast and capable as personal computers that I’m starting to wonder why I don’t just use the thing I always have in my pocket as my “laptop”, plugging it into a keyboard and display as necessary.

The “post-PC” era is really about moving past some existing form factors and into new ones. But if you could plug your phone into a keyboard and display to run Visual Studio or Lightroom or whatever, what do you really have? Well: a very small desktop computer.

We went from cabinet-sized PC to desktop PC to smaller PCs to, well, phone-sized PCs (yes, they already exist), but only with smartphones and tablets did the industry embrace new UI designs and input methods. And the danger, here (apart from the attached problems of vertically integrated services and other monopolies), is to think it’s a panacea.

I’m looking forward to see how it will continue changing the market, but meanwhile I’ll keep using my laptop. You know, the one that keeps getting lighter and thinner while gaining multi-touch trackpad capabilities. Thanks a lot for that, by the way.


This is why people buy Macs

A few months ago I set out to get a new laptop for my wife. She only had one requirement, after having shared a Macbook Pro with me for the past couple years: that it ran Windows (queue OS flamewar).

I quickly decided I wanted to give her something slick and light, and look at the new line of ultrabooks. I then narrowed the choices down to the Samsung Series 9 and the ASUS Zenbook by reading reviews online… but that was just the easy part.

IMG_8094.jpg

Much has been said already about the shopping and out-of-the-box experience of PCs, compared to that of Macs, but I think we should keep beating that dead horse until it’s underground. So keep reading for much deceased equidae action.

Getting your hands on the stuff

The first step is to actually get your hands on the models you’re looking for. But if it’s easy with a Mac – just walk into any Apple store or Best Buy or whatever – it’s not that easy with a PC.

Different stores carry different models, have different deals with manufacturers, and have different supply chains. Even given one store franchise, the availability of models will vary from store to store, and that’s not counting which ones are actually available on display: for some reason, a lot of stores wouldn’t let you touch expensive laptops like the 2 ones I wanted to try. Paradoxically, the Apple mini-store located in the next aisle would always happily provide multiple copies of each of their devices for people to play with.

In my case, London Drugs (here in Vancouver, Canada) was one of the only stores to carry the 2 models I was looking for – the whole point being to compare them side by side. But it still took me several visits to several stores all around town to find one with both units actually on display.

During my search, I got some interesting tidbits of information from sales people:

  • High-end laptops are already well taken care of by Apple, so shelf space is reserved for feature, mainstream, or budget oriented models from PC brands. Windows power-users therefore get forgotten in the process.
  • Some stores have issues securing those new ultrabooks, so they end up not having them on display at all. Unlike Apple, which provides appropriate locks for the Macbook Air, other manufacturers leave it up to the stores, who often use generic, bulky locks. But those locks often don’t work with ultra-thin cases… and when they do, they’re almost as heavy as the laptop itself, which completely ruins the experience of trying it out.

I eventually managed to test the models I was considering, and quickly decided the ASUS Zenbook would work better. Good news: the Zenbook Prime was just about to be released, with a much nicer body design and a supposedly better trackpad… so after a couple weeks waiting for that one to show up in store, I came back home one day with my precious gift.

IMG_8106.jpg

Stickers

The Zenbook is a beautiful machine, but like many PCs it comes with a bunch of ugly stickers. This is always totally baffling to me: what’s the point? Are people going to look at your laptop at Starbucks and go “I see your laptop has an Intel CPU inside! Mine too, this is so awesome! Much better than AMD, don’t you think?”.

No, all they do is waste 5 minutes of your time as you remove them and then clean up the sticky bits that they leave behind.

IMG_8103.jpg

The silver lining in this case was that all 3 stickers that come on the Zenbook are mostly in grey-ish tones similar to the laptop’s body – no flashy ugly colors here. So it’s not completely horrible. Just annoying.

Bloatware

Another expected downside of buying a PC: all the bloatware that comes pre-loaded with it. Everything, from the moderately useful to the totally useless, can be found on the Zenbook once you boot it up. I counted around 20 “utilities” installed.

Of course, I opted for the usual practice of wiping everything and installing a fresh Windows on it. I had to fight the BIOS for a long time, trying to get the default GUID Partition Table to work with my bootable USB key. But the UEFI boot mode wouldn’t work for some reason, so eventually I gave up, re-allocating the whole hard drive as a more classic Master Boot Record partition. It’s kinda sad, this being 2012 and all, but as I understand it, I’m not losing much when it comes to a single 128Gb partition.

Of course, once Windows is installed, the fun has only begun: you still have to go to ASUS’ website to get the drivers for all kinds of components, along with downloading a whole bunch of updates from Microsoft.

Conclusion

The Zenbook Prime, once you’ve been through all those hoops, is a wonderful little machine. It looks gorgeous, is very portable, and the performance is pretty good. The accessories are also nice, especially the leather-ish case for both the laptop and some of the cables. The power cable is the only poorly designed component in the whole package in my opinion, but overall, I recommend this laptop highly.

IMG_8098.jpg

But going through all these steps was pretty tedious. In comparison, the shopping and out-of-the-box experience of a Mac goes along these lines:

  • Go into any computer store.
  • Try any Macbook.
  • Give lots of money.
  • Boot it up.

I guess Microsoft Stores and Samsung Stores and the like are trying to address the issue, but it’s a long way away.


The state of Diaspora

In the main article about the road to Diaspora, we looked at setting up our own pod to interact with the Diaspora federated community. Now we’re going to look at how that actually works. Or not. Because since I set up my pod a few weeks ago, I’ve had nothing but problems.

The river of problems

To give you an idea of how bad Diaspora is, even after a couple years of development, look no further than the bug tracker on their Github project page. After a week of using my pod, I had already posted half a dozen issues – and that’s for just one user on a lonely pod. I wasn’t following a lot of people either. Some of those issues have been closed, some are still open. But the point is: this is not good for a project that’s been in beta testing for so long.

Then, there’s the performance issues. Ruby on Rails has never had a very good reputation in this department, but I thought it was mostly a “haters gonna hate” kind of reputation, or some remnant of the framework’s early days, when it was not necessarily very optimized. But after running Diaspora, I’m revisiting my opinon. On an Ubuntu VM with 512Mb RAM, the thin server that runs Diaspora is the only process that ever got killed for running out of memory – neither WordPress or MediaWiki or anything else ran into this situation. And that happens on a regular basis. We’re talking a couple times a day on average. And don’t even think of running a Rails console at the same time: it may work for a while, but you better get done quickly because one of the 2 processes will die soon enough.

And then there’s the whole “federation” aspect, which is the whole point of Diaspora. Spoiler warning: it doesn’t work. I don’t know if it’s related to the performance problems above (the process could be dropping important bits of information when it gets killed) but I always seem to be missing posts and updates from anybody else that’s not on my pod. Doing some testing between my pod and a few other well-known pods like joindiaspora.com or diasp.org, I get completely random results: sometimes a comment or “like” gets propagated in a few seconds, sometimes it takes hours, and sometimes it just doesn’t show up at all on one end or another.

I could go on and on about all kinds of little problems, from the completely stupid “PersonName started sharing with you!” email that doesn’t make any sense (because it means they’re following you, which means they won’t share anything with you unless you follow them back) to some weird design decisions around hashtags (try figuring out how to follow hashtags from other pods) to some obvious problems that never seem to get fixed (like useless Diaspora links to your Twitter cross-posts, or the inability to cross-post public posts to Facebook). I guess that’s what the Github bug tracker is for but, again, this really doesn’t look like a project that’s more that 2 years old.

Diaspora’s future

The original Diaspora founders recently left the project, saying they’re “giving it back to the community” while they “take the back seat”, a.k.a. Makr.io, a very stupid website concept. Some people say that’s the death of Diaspora, but judging from the state of it, it may actually be what saves it. The project was obviously badly managed and designed from the start, so maybe, just maybe, having a community of better programmers take over the codebase would make it viable.

There’s also the very, very slim possibility of someone either re-implementing Diaspora using a different framework than Ruby on Rails. Diaspora is mostly based on open standards – although the keyword here is “mostly” – so it would be possible to rewrite something from scratch that’s compatible.

There’s also the very, very slim possibility of someone writing something else that works better. Mike Macgirvin, the creator of Friendica, recently started working on “Project Red”, which is “Friendica taken to the next level”. His announcement didn’t hesitate to make fun of Diaspora:

Friendica WORKS today (unlike similar projects which are still struggling at basic communications after two years, and after squandering huge amounts of money).

Seeing how Friendica works and is easily installed – even though it’s ugly and useless to me – Project Red could be a good thing if it’s based on asymmetric relationships and Mike can enlist the help of a moderately talented web designer.

In the meantime, I don’t think we’ll get people away from Twitter and Facebook any time soon.


The journey to Diaspora: setting up your own pod

The first step in the journey to Diaspora is to get your own Diaspora server because, well, that’s the whole point of a distributed social network: you get to own your stuff (you could argue that, on the other hand, I’m not running my own email server, but, err, whatever, indulge me).

Unfortunately, setting up a Diaspora pod is insanely convoluted and complex.

After the jump, we’ll get into the meat of things and hopefully it will help you with the process (if you ever want to attempt it).

Follow the guide

Looking at the complexity of setting up a Diaspora pod, there’s something to be said about the Ruby community, who often seems to degenerate into a pile of over-engineered, over-complex set of weirdly named libraries and tools, all of which end up being very slow and memory hungry. Hipsters was the worse thing that ever happened to the Ruby language.

Anyway, enough trolling, you probably want to start by following the installation guides, over at Github. My server is an Ubuntu virtual machine so I followed the Ubuntu guide which will make you apt-get install a whole lot of packages, from system libraries to Ruby and the usual suspects (gem, bundler, rake, etc.). Once that’s done, you move on to the Diaspora installation guide itself, which is where things get fun (given a certain definition of “fun”), and where I’ll try to hold your hand (no homo).

Note that several “easy installer” initiatives are being worked on, mostly targeted at popular hosting companies like Heroku. By the time you read this, you may have something available for your situation.

Get an SSL certificate

The first thing you need is an SSL certificate for your domain. Since you’ll be exchanging potentially private communications between your pod and the other pods, it’s a good idea to go through https, which means getting an SSL certificate. You could usually use a self-signed certificate for this, but the bigger pods (a.k.a “community pods”) won’t accept that, so you need a proper certificate.

The documentation will point you at StartSSL, which delivers free class 1 certificates for your domain for a year. That’s enough to get you started. Just go to their website and follow the instructions – you’ll end up with a few keys and other serious-looking files. If you plan on hosting your pod on a sub-domain, don’t forget to add your top-level domain to the alternative domains falling under the certificate.

Getting Diaspora

If you keep following the installation guide, you will at that point have cloned the Diaspora repository on your server, run a few commands like bundle install, and edited a few configuration files. Here are a few tips, though:

  • Before you do all the RVM and bundler stuff, make sure you apt-get install libreadline-dev libncruses-dev. Hopefully this will make the readline gem work right away. We’ll talk about that later.
  • For some reason, the config/application.yml.example file features a pod_url with a port 3000 specified. Make sure you take this out when you replace it with your own domain URL. This has to be the real, public URL (otherwise your Diaspora ID will have :3000 in it!).
  • For me, the ca_file was /etc/ssl/certs/ca-certificates.crt, but it of course depends on your Linux distribution.

Of course, you’ll need to follow the instructions for setting up a “production” server. Don’t set serve_static_assets to true, there’s no need for that – Apache will serve the static assets already. Set single_process_mode to false, too, because it looks like it’s mostly for development/debugging purposes.

I’d recommend setting up the mailer right away (it’s the thing that sends notification emails). For some reason, even when mailer_on is false, Diaspora will try to send some emails, resulting in errors and failed jobs. It’s not a huge deal (maybe), but I like to avoid false positives in my error logs. Here it goes:

  • Install sendmail with some apt-get or something.
  • Set the mailer_method to sendmail.
  • That’s it! (although you can optionally set some nice email address for the sender).

Setting up the database

For some reason, the config files assume you’re going to run the app with the root MySQL user. I don’t know what they’re smoking over at DiasporaHQ but there’s no way I’m going to do that, so instead I created a new database myself, called diaspora_production, and a user with access to that database. You could call the database differently, I guess, but you would have to go and change the default name in all the configuration files. And I’m not sure if there’s any hard-coded stuff somewhere that references that database, so I went with the safe route of using their naming convention.

Once that’s done, you don’t need to run the db:create Rake task. Just run bundle exec rake db:migrate. You should see your database filling up with tables.

Apache configuration

Now you’ll need a web server to actually get anything working. I’m using Apache for this.

The first thing is to make sure the SSL/https stuff will be working:

  • If you don’t have that already, add NameVirtualHost *:443 and Listen 443 to your conf files to make Apache listen to incoming connections on port 443 (which is used for https). You can put that next to the similar directives listening to port 80 (which is standard http).
  • You’ll need to open port 443, obviously, in case you have a firewall (which you should have). Again, just look for where it deals with port 80, and copy/paste. If you’re using iptables, you should end up with something like -A INPUT -p tcp --dport 443 -j ACCEPT.
  • Make sure you have mod_ssl loaded/enabled.

Then, add an entry for the new website (your pod). You can use this Apache configuration that they point to in the installation guide. The only modification I did is to add a reference to the SSLCACertificateFile I got from StartSSL. So all my SSL stuff would look like this at the end:

SSLEngine On
# You generated those with StartSSL
SSLCertificateFile /path/to/cert.crt
SSLCertificateKeyFile /path/to/private_key.key
# You got those from StartSSL
SSLCertificateChainFile /path/to/sub.class1.server.ca.pem 
SSLCACertificateFile /path/to/ca.pem

For the rest, you don’t need to change much except the path to the Diaspora repository you cloned with Git. Make sure you specify the path to the public folder, not the root folder, otherwise it won’t find all the CSS and images and such.

Also note that you’ll need mod_proxy, mod_proxy_balancer and mod_proxy_http loaded/enabled for this to work.

Running the pod

Holy shit. See, what did I tell you, that it was insanely complicated? Well, it’s not quite over yet.

Now you can at last run ./script/server, wait a bit, and go visit your brand new pod. If everything’s good, you should have a little “lock” icon in your address bar (and if you click on it, it tells you your domain is verified by StartCom Ltd.). You should also see the Diaspora welcome page.

Go and signup! It’s all yours!

When that’s done, you can go back to config/application.yml and set registrations_closed to true so that nobody else can create an account (if that’s what you want).

Kill the server with CTRL+C and, while it’s down, open the Rails console with bundle exec rails c.

Remember when I talked about the readline stuff? Well, if you didn’t do it well, that’s where it fails. If so, you’ll have to patch the readline gem like I had to.

Go to ~/.rvm/src/ruby-1.9.3-p125/ext/readline and then ruby extconf.rb, make, and make install. Make sure you’re using the same version of Ruby to run extconf.rb than the version you’re patching! (if you only have one Ruby installed, you don’t have to worry about that last detail).

Running the console is for adding your newly created user to the “administrators” role, so you can get access to the administration dashboard: go to this FAQ page and look for “Roles”. You should see a bunch of stuff you need to type in the console to make yourself an administrator.

When you’re done, start the server again with ./scripts/server.

Administration tips

On your pod’s website, in the top-right menu (where you have “Contacts” and “Log Out”) you should see a new entry called “Admin”. Click on it. The most useful page here is the last one: “Resque Overview”.

Resque is the background job manager, which takes care of a lot of important stuff for your pod. The overview page will show you, among other things, any failed jobs. This is useful to troubleshoot problems and send bug reports.

Another hidden page is at /admin_panel. This is the Rails panel dashboard, where you can basically hack into your database to fix things, compare values, or clean data. It’s a bit dangerous but can be useful at times.

Conclusion

That’s it! If you made it this far, congratulations, you have absolutely no life. You should, at this point, be able to send useless status updates to your so-called friends, with the warm feeling that comes with using open standards.

In the next post in this series, we’ll look at all the problems you will face with your Diaspora pod – and there are many, unfortunately.


The journey to Diaspora

Recently, app.net has gotten a lot of attention, but I just don’t see the appeal. It’s basically a Twitter clone that you have to pay, and all of this for what? So that the API is nicer to developers and you don’t see a couple of “promoted tweets” once in a while?

It sounds like a very shallow goal for a supposedly “disruptive” communication platform. Sure it has some kind of grand plan to get us to the next level of connectedness through, err, innovative apps and mashups or something. But it doesn’t make things better on the ownership level. It’s still yet another data silo. And I’m fed up with silos.

Remember when we used to communicate through free, open, distributed and standardized protocols? You know, like emails or phone calls? Or even snail mail? My problem with Facebook or Twitter is not that I’m the product, but that I don’t own my data, and that there’s no competition or choice between service providers. They’re not only data silos, but business model silos.

Other people also got fed up with the slow decline of the open and connected web, and started writing the building blocks for distributed social networks. Several projects emerged from this, with the most famous being Friendica and Diaspora.

  • Friendica: its main advantage is that it’s easy to install – like most PHP projects, you just copy files on your server, edit a configuration file, and follow the instructions on the web. You just have a couple of additional steps after that to setup your crontab so it can synchronize posts in the background. It also has very good interoperability with pretty much all the other social networks. The big problem, however, is that it’s batshit ugly. Also, as far as I can tell, it only allows bi-directional relationships, like Facebook, which means that if you want to “follow” somebody, you’ll have to send a “connection request”.
  • Diaspora: announced with much fanfare a while ago, it felt like vaporware for the longest time until it actually looked like they were shipping something. The selling point is a Google+-like “friendship” model, where relationships are asymmetrical and can be classified with “aspects” (Diaspora’s version of Google+’s circles). However, as we’ll see in the next post in this series, it’s insanely complex to install, full of bugs, and has poor performance. It also only allows to cross-post to select competitors (Facebook, Twitter and Tumblr).

With that in mind, Diaspora doesn’t seem to me like the best alternative to commercial social networks – it’s the only one so far. In this journey to Diaspora, we’ll look at:


Microsoft password fail

Almost 4 years ago, I wrote a short article on dumb websites who have a maxiumum password length.

Now, in 2012, there are still websites with such stupid policies. One of the most famous is none other than Microsoft’s Live Account service, which serves as the authentication hub for all things Microsoft. Basically, your Live ID, or whatever it’s called, can’t have a password longer than 16 characters.

Microsoft is, rightly so, getting a lot of criticism about that because the recently released Windows 8 lets you link your Windows user to a Live ID, for use with the whole Windows App Store thing and more. This means, in most cases, that your Windows password can’t be longer than 16 characters, and, in other cases, that you have all kinds of weird account related bugs and you may need to enter a truncated password.

Oh, Microsoft.


When Windows “just works”: part 2 (the work around)

Back in the first part of this 2-part post we looked in some detail at how MacOS mounts network shares, and how badly designed this feature is compared to its Windows counterpart.

We’ll now look at the solution I’m using to fix the problem, which is to mount network shares in a consistent way for a multi-user machine.

The work around

Thanks to the power of UNIX, you can get around the problem by spending hours reading boring documentation, searching useless forums, editing obscure configuration files and generally speaking wasting your time for something Windows gets right in 2 clicks.

If you do the research, you will find lots and lots of solutions – some clever and some completely stupid. Not all of them worked for me, so here’s the solution I came up with. It uses the autofs feature supported by most recent versions of MacOS, and has some pros and cons. “Your mileage may
vary
”, as they say.

Creating custom mount points

Start by editing /etc/auto_master. It should look like the following, but without that last line. Add it using your favorite text editor (which you may have to run as root):

#
# Automounter master map
#
+auto_master		# Use directory service
/net			-hosts		-nobrowse,hidefromfinder,nosuid
/home			auto_home	-nobrowse,hidefromfinder
/Network/Servers	-fstab
/-			    -static
/-              auto_smb

Now create /etc/auto_smb and write something like this:

/Users/user1/Volumes/MyStuff -fstype=smbfs ://username:password@server/MyStuff
/Users/user1/Volumes/media   -fstype=smbfs ://username:password@server/media

/Users/user2/Volumes/SomeOtherStuff -fstype=smbfs ://username:password@server/SomeOtherStuff
/Users/user2/Volumes/media          -fstype=smbfs ://username:password@server/media

This file tells the automounter to treat the folders specified at the beginning of each line as mount points for the network shares specified at the end of each line. The file protocol I’m using is smbfs, which is the Windows file-protocol. You could try to use afp here, which is the Apple File Protocol, but I ran into permission problems on files I was editing or creating on my server. Also, depending on your server, smbfs may be faster.

I’m mounting my network shares in each user’s home directory, in a ~/Volumes folder, but you can mount them anywhere else – the whole point here is to have one “mount sandbox” per user instead of the system-wide /Volumes.

Also, here I’m specifying network shares with a custom username and password. You may not need that if you’re using the same credentials on both the local machine and the server. Of course, replace server with your actual server name or IP.

Once that’s done, run sudo automount -vc to tell the automounter to refresh. If it doesn’t work, you may have to create the ~/Volumes directory, along with the mount points themselves. I also ran into problems where the automounter would still be a bit confused and had to reboot to make things work, so you can try that as a last resort.

Accessing the network shares

That’s the totally lame part: the mount points you created are not displayed in Finder until they are actually mounted. They will show up only after they’re mounted, which only happens when needed, i.e the first time they are accessed. So, at first, your ~/Volumes directory will be empty – at least in the Finder (if you go there using a Terminal, you will see the mount points, and you can cd into them, which would trigger the mount and make them appear in Finder! Yeah, it’s confusing, I know, welcome to the Apple ecosystem).

How do you access your network shares if you can’t see them in the Finder, then? Well you go directly to them with “Go > Go to Folder…” and enter, say, ~/Volumes/media:

You would only have to do this once in a while because once they are mounted, you’re unlikely to unmount them (you would actually need to use the command line for that). Also, once you gave that path to an application like iTunes or Lightroom, those applications can trigger the mount themselves by merely accessing the path: the next time you reboot and launch the application, it will all magically work (although you may notice a pause for a second or two as the system mounts the network share).

Alternatives

If you want the network shares to be visible in Finder as soon as you login, you can either:

  • Make a login item (a Bash or Apple script, for example) that will trigger the mount by accessing the path somehow.
  • Specify mount points in /etc/fstab instead of through the automounter.

I myself prefer staying with the automounter, because it means I won’t get a timeout when I log into my laptop but I’m not at home. Since I rarely reboot, it’s very uncommon for me to have to manually re-mount my network shares.

Conclusion

This is what makes it possible for me to use my home server along with sharing my Macbook with other users. It was a lot more complicated than I anticipated, but I guess making Macbooks play nice with custom servers would go against Apple’s new cash cow, a.k.a “iCloud”.