Workshop updates

The Maker Faire workshop was a lot of fun, and many lessons were learned!

On the plus side, I think that all of the robots went home able to dispense liquids. Yay!

I am working on some tweaks, improvements, patches, and bug fixes. I will be uploading a new sdcard image, and instructions to write it to your sdcard. Or I can send you a new sdcard. Email me at Rich.Gibson at gmail.com if you would like to swap out your sdcard.

The initial ‘big changes’ to get the Bartendro admin mode to work is to change your /etc/hosts file.

 127.0.0.1    localhost
::1 localhost ip6-localhost ip6-loopback
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
127.0.0.1 hellodrinkbot

And to update your file /etc/nginx/sites-available/bartendro.conf to look like this. This is a bit of a kludge, where I am tweaking a sample conf file and I am pretty sure that there are better ways to do this. So please let me know if you have a better version.

upstream hellodrinkbot {
server 127.0.0.1:8080;
}
Listen on all interfaces of eth0
server {
root /usr/share/nginx/www;
server_name hellodrinkbot;
access_log /var/log/nginx/bartendro-combined.log combined;
error_log /var/log/nginx/bartendro-error.log notice;
location / {
proxy_pass http://hellodrinkbot;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
# This allows you to use Bartendro via its IP address. This is good for setting up # for the first time: proxy_set_header Host $server_addr; # If you have set a custom DNS record for your Bartendro, uncomment the following # line and enter the DNS name for your bartendro and then comment out the· # proxy_set_header line above:· #proxy_set_header Host "bartendro.example.com"; proxy_redirect off; }
}


listen on the bartendro private wifi and redirect all traffic to bartendro
the server name here is always set the "bartendro".
server {
listen 10.0.0.1:80;
root /usr/share/nginx/www;
server_name hellodrinkbot;
access_log /var/log/nginx/bartendro-combined.log combined;
error_log /var/log/nginx/bartendro-error.log notice;
error_page 404 /404.html;
error_page 500 502 503 504 /50x.html;
location / {
proxy_pass http://hellodrinkbot;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host "hellodrinkbot";
proxy_redirect off;
}
}
server {
listen 10.0.0.1:80 default_server;
server_name _;
rewrite ^ http://hellodrinkbot? redirect;
}

Join the Conversation

1 Comment

  1. Great to see the first post-Maker Faire update! I’ve added four more pumps to my Drinkbot and it seems so much more complete now. I attempted these modifications tonight but I’m getting a 502 Bad Gateway error when I try to connect to hellodrinkbot.local. I’ll troubleshoot more tomorrow but I’m not too familiar with nginix, so I may just wait until the next SD card image release to do the full upgrade.

    On a somewhat unrelated note, do you know how to remove a drink or booze item from the database? I seem to be making duplicates every time I try to modify a booze or drink I added.

    Thanks,
    Kevin

Leave a comment

Your email address will not be published. Required fields are marked *