Saturday, 12 November 2011
Monday, 17 October 2011
This morning my money transfer cleared into my Mt Gox account. It had taken two working days from the point I instructed the bank. I'm looking to buy 10 BTC, but I've got the maths wrong in the previous post. I'm going to make a first go at getting as many BTC as possible for my 3 GBP and transfer over some more funds.
The price this evening for BTC on Mt Gox is 1.71 per BTC. I'm going to put in an order for 1 BTC at 1.70 and another at 1.30 and see what happens. My 1.70 offer was immediately taken up. The 1.30 sat there.
Next I decided to get my new BTC out of Mt Gox. After my transaction fee I had 0.994 BTC left. I put in my Bitcoin address and submitted the request to Mt Gox. The option that I wasn't aware of was the "green address" This option seems to mean that the receiver can trust the transaction with zero confirmations. As I'm not that time sensitive I decided not to take the option. I fired off the request at 19:10 UK time. By 19:11 I had an unconfirmed transaction in my Bitcoin client. Next I went to the internet banking site, put 16GBP in the Mt Gox account, and then fired off an email to Wuala requesting 100GB of storage for 10BTC. By 19:28 I had my first confirmation of the Bitcoin transfer.
Sunday, 16 October 2011
Yesterday we went with Jess and her boys on a "a foodie, floating, family day out exploring the region's historic waterways". Really disappointing. It turned out to be a much delayed 20 minute canal trip from the Mark Addy to the Lowry theatre. As for the food, the kids got a carton of Vimto and a Chorley cake. Apparently it was celebrating the launch of some book. That passed me by.
Still, we had a nice time wandering around Media City and annoying the pettifogging BBC security personnel: "That is an official BBC prop".
Wednesday, 12 October 2011
Monday, 10 October 2011
- Work laptop - Keep Charged
- Nokia E71 - Keep Charged
- HTC Desire - Keep Charged
- Mifi (Huawei E585) - Keep Charged
- Asus Aee Transformer tablet - Keep Charged
Friday, 7 October 2011
#1 and #2 sons are both addicted to Minecraft. In our "Dad and son techie evening" this week #1 son said that he wanted to set up a Minecraft server. It was actually very easy.
- Follow the instructions from the Minecraft Wiki to get the Java files on to the server
- I had to reduce the memory footprint as I'm installing it on the Rimuhosting VPS server that is quite restricted on RAM. I went for starting with 500 megs and maximum of 800 megs
- Set up a white list file with the users we want to allow
- Kick off the server:
java -Xms500M -Xmx800M -jar minecraft_server.jar nogui
- Set it up properly to start at boot time following the Debian init.d approach
- Set up logrotate to manage the log file
- I really must set up iptables or equivalent to give me a suitable firewall
Wednesday, 5 October 2011
Tuesday, 4 October 2011
Saturday, 1 October 2011
I run a debian server with Rimu Hosting (highly recommended). Every week I've been going on to do a bit of house keeping. I realised that I could automate those tasks and get the server to send me an email to tell me what it had done. I decided the first problem to solve was to get the server to send me an email from the command line. After a little googling I tried this:
echo "This is a test" | mail email@example.com -s "Just testing from the server"
That didn't quite work as expected. The problem was that I run my email from Google Apps on my domain. I wanted @goopot.co.uk addresses to be picked up by Google's email servers. However, the debain server knew that it was goopot.co.uk so decided to handle the email itself. It very efficiently delivered the email to the linux user account on the server, and not my Google mail box.
I needed a way to tell the server that email to goopot.co.uk should be handed off to Google and not processed locally. A bit more googling led me to the Debian Wiki page about Gmail and Exim4. I followed those instructions to the letter and tried again:
echo "This is a test" | mail -v firstname.lastname@example.org -s "Just testing from the server"
Nothing seemed to happen at all. No email arrived either locally on the server or to Google. Hmmm.
Back to the drawing board. I next tried to send an email to my wife's account to see if I could figure out what was working.
echo "This is a test" | mail -v email@example.com -s "Just testing from the server"
That worked like a dream. So the Exim config is working fine, but the mail program doesn't know to go to the SMTP server rather than delivering locally.
Digging into the docs I figured out that I needed to make sure that the "local_domains" parameter was set correctly. I edited /etc/exim4/conf.d/main/01_exim4-config_listmacrosdefs and changed the local_domains parameter to be empty. I re-ran:
...and tried again. It worked. Yeah!
Wednesday, 28 September 2011
Friday, 23 September 2011
Wednesday, 21 September 2011
Tuesday, 20 September 2011
Monday, 19 September 2011
Sunday, 18 September 2011
Saturday, 30 April 2011
import textmagic.client client = textmagic.client.TextMagicClient('your_username', 'your_api_password') result = client.send("Hello, World!", "1234567890")
import textmagic.client client = textmagic.client.TextMagicClient('name', 'pw') received_messages = client.receive(0) messages_info = received_messages['messages'] print('%d messages in in-box' % len(messages_info)) if len(messages_info) > 0: first_message = messages_info print("Message from: %s" % first_message['from']) print(first_message['text']) client.delete_reply(first_message['message_id'])
import sys import textmagic.client client = textmagic.client.TextMagicClient('username', 'password') no = sys.argv result = client.send("Hello! What is your name?", no)
...and here's the receiving one...
import textmagic.client client = textmagic.client.TextMagicClient('username', 'password') received_messages = client.receive(0) messages_info = received_messages['messages'] print('%d messages in in-box' % len(messages_info)) if len(messages_info) > 0: first_message = messages_info from_no = first_message['from'] name = first_message['text'] print("Message from: %s" % from_no) print(name) client.send("Nice to meet you %s!" % name, from_no) print("I have sent a reply") client.delete_reply(first_message['message_id'])
All this needs is a main loop round it to keep polling for input and we're done.