New Blog Attempt
I’ve been playing around with a new blog format at http://www.connorberry.com.
I don’t know if it will end up replacing this blog or not.
I’d like it to in some ways, because I really want to have all the data from my
posts in a place that I can get the data easily if I want to try something
else.
Backlog of Old Posts
One of the reasons that I wanted to create my own blog software is so that I
would have easy access to all of my old posts. Currently I have a number of old
posts in a couple of online hosted blogs. I’m probably going to have to
manually capture the data out of those.
My hope is that going forward, I can do a better job of keeping all of my posts
available for any future blog format that I want to use.
Post Order
I’m not totally sure how best to deal with the idea of there being multiple
posts on a day.
It is simpler to treat each day as it’s own thing, but that makes it a little
stranger when I think about how to do indexing of specific posts.
Static Blog Stuff
So far it looks like PHP is the way I’m going for the static site. Actually
it’s a Frankenstein concoction of make, bash, php, and possibly awk.
The primary benefit of this approach is that it’s easy to add to incrementally.
The danger of this approach is that at some point it may well collapse under
the weight of all the hacks I’m doing.
There are ways in which the approach I was going after with Tcl would be
cleaner, but for the moment this seems like it will work.
Node + Frankenblog
So, now I’ve added node.js to the set of things involved in this particular
blog implementation. I know that if I’m using node as the webserver, that may
sort of defeat the point of having a static site, but it was simple to set up a
node webserver that just reads my static file.
I’ll almost certainly have to rework this as I get more entries. But for now, I
actually have a website up.
I could probably also have used any number of other small webservers, I’ve used
cherrypy in the past and I like it, but I’ve seen occasional strange errors
from chrome when using niche webservers. I may end up seeing the same issue
with node.js but so far it seems to be serving the page up correctly.
Node Permissions
So, one thing that’s not ideal with node is that running it on port 80 requires
that it be run with Root privileges. It can drop to a normal user once the
server object is created. But I haven’t figured out a way to have it run under
a normal user at port 80.
I can get it to drop to a normal user after it is started, but if I’m running
it in a dtach session (or screen or tmux), I don’t see a way to run that
session under the normal user. Possibly if the user was able to sudo that could
happen, but I’m wary of allowing sudo on my public server.
Node "http-server"
I found a package for node that implements a simple static http server called
"http-server"
(Exactly what it says on the tin)
I modified it to add the ability to switch to a non-root user if it is started
as root (so it can server on ports less than 1024).
My version with the changes is here.
The original is here.
Blog vs Journal Format
I guess this is actually a journal instead of a blog.
I prefer to be able to read all the posts in a day chronologically. I think it
makes sense for each day to be listed in reverse chronological order, but in a
particular day, I have so many short updates (at least right now), that it
really breaks the flow of thoughts to read a snippet, and then have to go back
up for the next snippet.
I’m not sure how I’ll communicate that to anyone that would actually read this.
Node for All
I am now thinking about trying to implement the pieces of this blog that are
currently done using PHP using node. I don’t really have any real need to do
that. But I’m intrigued by Node, now that I’m using it.
Conceptually, there’s a lot that I like about Javascript – it was one of the
first languages that really gave me a feeling of joy to work with. But it’s
been years since I was really deep into it. So much has happened in that time.
At the time I was into it, jquery was just begining to be used. I developed my
own Ajax library because I kept running into bugs in all the other ones that I
tried around that time. JQuery was really the first JavaScript library that I
came across that I was really impressed with. But it’s been so long, that I
really don’t remember much about it.
Moving Day
Today is the day Jayne and I begin moving into the new house. This one has been
nice, but it is really too small for us, and with a baby on the way, it’s not
practical to stay here.
Testing New Post Method
This a test to see if I can script a little of the posting processes.
Second Test
I’m not totally sure how best to deal with the idea of there being multiple
posts on a day.
It is simpler to treat each day as it’s own thing, but that makes it a little
stranger when I think about how to do indexing of specific posts.
Testing Publishing
This is a test to see if my change to how this blog publishes actually works
the way that I think it should.
Testing Seamless Publishing
Now I’m testing whether the scripts I’ve got installed will actually upload a
post without a lot of manual work.
New Blogging Thoughts
I don’t know whether I’ll actually find this method of blogging to be easier
than what I’ve been doing. I hope that it will inspire me to blog more, but it
may be that it will only inspire me for a little while and then I will be back
to being fairly passive regarding public writing
Github Editing
I’ve been editing this node.js "http-server" package directly on GitHub. That’s
probably not the "right" way to do things. I’ll have to look at actually
cloning my repository so that I can just commit working code instead of
potentially breaking things on the public repository as I’m playing around.
Testing a new post
This is a test to see what happens if I manually add a post other than my
automatic daily post.