10 ms·
How I use my Raspberry Pis to help me work on with my side projects
- baroffoos 8y agoWith this many applications I would be looking at getting one higher powered server and running docker on it. Would be more power efficient as you only need one OS and one PSU as well as likely much cheaper.
- yjftsjthsd-h 8y agoI don't disagree, but I think that sharpens the learning curve.
- earthscienceman 8y agoWhy docker? Seems like overkill for not much gain.
- collinf 8y agoDocker has a multitude of benefits for single machine multitenant deployment strategy, namely resource and file system isolation. It also has the benefit of being self documenting of dependencies via layers, which is a nice thing to have. To be honest, running just about anything self-hosted can be deemed overkill when there are so many free hosted solutions. But that’s why we’re engineers because sometimes it just scratches an itch for us :)
- baroffoos 8y agoDocker is not overkill at all. Having 20 servers to run a few very low utilization is overkill. When you run a whole bunch of stuff on the same server it becomes a lot simpler than installing them the traditional way. A lot of self hosted server software is not in the repos so you end up having to add extra repos and after you do that a few times I find that something always ends up breaking and ruining the whole OS. Its much simpler to keep the host os basically stock debian with docker installed and then if anything goes bad its contained.
- kkarakk 8y agobut then you have to learn docker and how docker does networking is the overhead they're talking about.
- yjftsjthsd-h 8y agoSo basically, it's a tiny Linux server, and can run various server stacks/webapps, and is relatively accessible to beginners.
- SpaceInvader 8y agoExcept is not x86 therefore less packages available.
- patrickdavey 8y agoI have always been quite paranoid about port forwarding anything into my home network.
- YaxelPerez 8y agoI've found ngrok [1] useful for hosting stuff without opening ports. The only problem is you need to pay to get a fixed domain name. 1. https://ngrok.com/ https://ngrok.com/
- patrickdavey 8y agoAh very good. Yip, I've used ngrok before, and it's a beautiful piece of software.. nice! I do control my pi through telegram (polls a bot), which works nicely for the things I do want to control. I think for me, I'll just stick with my little linode VPS for hosting side projects :). But, I like the idea of ngrok!
- throwaway2048 8y agoThis is effectively exactly the same as opening ports from a security perspective.
- berti 8y agoLikewise, I preferred to setup a VPN (well, that still needs dnat but...) with the benefit of my devices always going through my trusted home network when I'm out and about. It's super simple with wireguard, and the iOS client app [0] is great when you're away from home. [0] https://itunes.apple.com/us/app/wireguard/id1441195209 https://itunes.apple.com/us/app/wireguard/id1441195209
- patrickdavey 8y agoThanks for that - I'd never heard of wireguard -> http://jonathanhamberg.com/post/2018-10-17-wireguard-behind-nat/ http://jonathanhamberg.com/post/2018-10-17-wireguard-behind-... that post was quite interesting - it's quite different the way it seems to work With WireGuard there is not necessarily a central server. There are many peers and any peer can connect to any other peer assuming they have the correct authentication credentials. Every peer has a private and public key used to identify its self.
- twtw 8y agoI always used to use various dusty old netbooks for this kind of stuff, and would run many applications on the same one. A dedicated raspberry pi in a nice little case for each is certainly modern and cool, but it doesn't give me quite the same nostalgia as a ancient laptop shoved in a corner...
- ekianjo 8y ago> Undeniably, Raspberry Pi has revolutionised the way we use computing technology in our lives ??? Shouldn't that be "Smartphones" instead? Even if the Raspberry Pi is popular among a certain segment of people, it is nowhere close to being as mainstream as smartphones which have revolutionized the way we use technology.
- pard68 8y agoWhy can't both statements be true?
- kkarakk 8y agocan't quickly deploy a service on my smartphone
- danieldk 8y agoAlso, most of my developer friends who have one booted theirs once or twice before disappearing in the closet. We used one as a home server, but replaced it by a NUC, since IO on the Pi is too constrained. The Micro:Bit at least actually got a foothold in UK education.
- eropple 8y agoYeah, IO constraints have made me dial back my use of Pi-alikes and have put a bunch of NUCs (or Gigabyte BRICs) in their place. I do still use my ODroid XU4 as a gimmicky little cluster for testing stuff, but nothing serious. I do have one project idea for using my stack of RPis, though (a badging/console login system for fighting game tournaments) but that is waaaay on the back burner.
- ekianjo 8y agoI think the Raspberry Pi had a good use though: it served as a stepping stone for people who wanted to try out home servers but did not want to spend a lot. After getting one's hands dirty with the Pi, it's fairly easy to move on to better hardware and feel confident doing so.
- jdietrich 8y ago
- thinkmassive 8y agoI have been experimenting with RPi for the past few months, and when I first got back into it I lost a couple hours diagnosing strange issues that ultimately all led to faulty SD cards. These are decent Samsung cards that work fine in an action camera, but the Pi was frequently dropping SSH sessions and even disconnecting from the network intermittently. Eventually I tried other cards with better results. Since then I started using ATP aMLC “industrial” Flash, which has been very reliable.
- DaniloDias 8y agoWere you using a WiFi adapter? Intermittent drops often come from undervoltage. You may need a 3.5v power adapter. Also, slow ssh can come from dns troubles: http://jrs-s.net/2017/07/01/slow-ssh-logins/ http://jrs-s.net/2017/07/01/slow-ssh-logins/
- bschwindHN 8y ago> You may need a 3.5v power adapter Do you mean a 3.5A power adapter? The Pi runs at 5v. I have one running on a 2.0A adapter and it's been running for a few years now. Though it uses ethernet so there's less power consumption compared to one using WiFi.
- DaniloDias 8y ago>> Do you mean a 3.5 power adapter? Yeah- sorry. Trying to do this from memory. :)
- thinkmassive 8y agoI was experiencing these issues with a known-good PSU. The same one has been working fine since I switched SD cards. Undervoltage is a common issue but easy to identify since it shows up in logs and displays the lightning bolt icon in the top-right corner of a display is connected.
- wingerlang 8y agoIt's not clear exactly how this helps him work compared to just using hosted versions of the services. It looks like there could potentially be a lot of maintenance to keep multiple individual servers up and running, and this is probably multiple side project in and of itself.
- helthanatos 8y agoMy thoughts exactly. I was hoping to find something more useful than the same benefits t I'd get from a free azure subscription.
- hnuser1234 8y agoSomething about the RPi seems to motivate new hobbyists in ways that hosted VMs just don't.
- jachee 8y agoIt's quite difficult to put a sticker on a VM.
- ahje 8y agoCloser to the truth than one might think. The Pi can be tinkered with in the same way one could tinker with an Amiga or an Atari back in the days. You can, of course, tinker around in a Docker container or a VM as well, but they're not physical products and therefore not "real" in the same sense.
- kkarakk 8y agocurrent gen skilled hobbyists grew up with fancying "physical" objects. a RPi is a physical object manipulating your data. a hosted VM(even if hosted on your own personal machine) doesn't have the same "tactility"
- MrKristopher 8y agoSame. Hosting websites at your house? Slower load times for your users. Hosting git at your house? If your house burns, you might lose all copies of the code. Hosting a manual WordPress installation? That's making work for yourself IMO.
- dragonshed 8y agoI prefer to think of and use my RPis as home network appliances, things that can run hassle-free. Examples from my house are: Pihole - Adblock for all wifi devices Shairport - audio airplay target Plex - media server My family members and I simply use these services without even knowing/remembering they're hosted on a RPis. If it requires tinkering or isn't permanent, it goes on a VPS. Many of the examples listed in the post are things that I would simply host on docker, a VPS or in a VM.
- KaiserPro 8y agoso one of the things not really covered here is how to deal with SD card failure. Any application that requires any level of writing to disk will almost certainly die in short order. I have a boatload of Pis, doing a bunch of things, and one of the annoying things is having cards die on me. Everything is in ansible, so its not that much effort to rebuild. However having any important data living on a pi's SD card is a nono
- mellow-lake-day 8y ago> so one of the things not really covered here is how to deal with SD card failure. I recommend a program like win32diskimager (https://sourceforge.net/projects/win32diskimager/ https://sourceforge.net/projects/win32diskimager/) so you can make images of your SD cards in their working state and if they get corrupted quickly get them back to working order. > However having any important data living on a pi's SD card is a nono That is why I wrote a script using the Fabric Python module to log in to my rpi3 and download important files. Ideally the script would run automatically every day but I haven't quite gotten there yet.
- nzjrs 8y agoThis is content spam, correct?
- anonytrary 8y agoHe seems to be using a content spam technique. He's effectively pointing to a verbose table of contents for his blog, with a slew of shameless plugs of tangential affiliate links.
- vardump 8y ago> Setup a Raspberry Pi git server For the love of $DEITY, please at least use an external USB disk. In RAID1, if possible. (Perhaps some multi-RPI git mirroring scheme could work as well? Anyone ever done something like that?) Do not EVER trust your valuable data on SD-cards on a Raspberry Pi!
- rcarmo 8y agoThe 2B and newer boards are much more reliable, especially when running Ubuntu ARM.
- vardump 8y agoI think it often depends on the power supply quality. I think many of the cards were corrupted due to bad power. Regardless, 3 bits per cell TLC SD cards (or QLC, 4 bits per cell, ugh) are not made for repeated writes, like git or database workloads. They will get corrupted even in the best conditions. You could use industrial SD-cards, but I think it's easier just to plug in a USB drive.
- ahje 8y agoIf the data is valuable then one should have an off-site backup anyway. I use an old laptop pretty much in the same way that the author uses his Pi's. While it's fairly new SSD is much more reliable than the Pi's SD card I would never store anything important on it unless I'm certain it's backed up somewhere else as well.
- rcarmo 8y agoI have a 3B+ set up on my desk with a BitScope USB oscilloscope and the Arduino IDE running on it for my hardware projects, a 2B in a closet running Gitea and Docker as “build box” for my containers (it’s speedy enough when you move the Docker storage to an external USB HDD) and another 3B to run my 3D printer. I’m not very keen on running ordinary services on them (my home automation setup runs on an ODROID, with Node—RED and homebridge Docker containers, which benefit from EMMC storage and twice the RAM as a Pi), but I’ve found the Pi to be a great platform for small self-contained tasks that really benefit from having a dedicated machine with a stable configuration. Also, I’ve found them to be quite reliable from the 2B onwards (I even ran a Swarm cluster on a set of mine for a couple of years) — I have all the setup info for most of these on my GitHub profile at https://GitHub.com/rcarmo https://GitHub.com/rcarmo
- cheunste 8y agoRandom question. How is the BitScope USB o-scope? I'm actually looking for a new O-scope (since I am loosing access to a lab) and I'm looking for something small and compact.
- rcarmo 8y agoIt's not ideal for high frequencies, but as a simple logic analyser it's ok. I have used it only for tweaking small oscillators for now.
- monkeydust 8y agoI have 3 RPi,s at home. I have Pi2 that acts as a dashboard for real time data on my train to work, my wife's bus route, weather temp and rain probability. I am using sensehat to present this information through pixels. I have a Pi3 running home automation (hass.io) which I am new to and find amazing in most part. And final one in my daughters room which is a Pi0 with Envirophat that's monitoring temperature. All side project and I am not a developer.
- SpaceInvader 8y agoWhat dashboard software you're using?
- monkeydust 8y agoI designed my own. You can read about it here. https://goo.gl/Zmdoit https://goo.gl/Zmdoit It has become integral part of our daily routine.
- deleted 8y ago[deleted]
- bschwindHN 8y agoAt first a I used a Raspberry Pi as an infrared sending device so I could control my air conditioner and lights remotely. Now I've built that functionality into its own PCB, but as I'm developing that product I need an MQTT broker to connect to. So the Pi now functions as a local MQTT broker until I have a hosted one I'm satisfied with. Next thing I want to do with it is run a little web app that displays local train and bus times, garbage collection days, weather forecasts, and that sort of thing. They're great for prototyping hardware ideas and running various one-off web services locally!
- Walkman 8y agoThe article has 9 subchapters. It could have 2 or 3 by saying "Install GitLab", but maybe GitLab can't run on a Raspberry? If you are not restricted to a Pi however, try GitLab and you are done with all the steps described in this article.
- karolist 8y agoI'm running a completely silent mini ITX J1900 build for a long time now, it has an x86 arch and 4 core CPU with Intel VT-x support where you can run as many KVM instances as your RAM allows for, don't really see how a dozen Raspberry PIs could be better but to each his own. I always recommend silent SOC x86 builds for home dev use instead of RPi
- lunchables 8y agoYour requirements aren't necessarily the same as everyone else. For people who want something silent and inexpensive to run a few containers, rpi can be hard to beat. Extremely cheap, extremely low power and take up very little physical space.
- roadbeats 8y agoIt felt like a clickbait title after reading the content... Hosting a phpMyAdmin? I was hoping to see some creative ideas...
- klibertp 8y agoI made an Elixir app[1] that worked on RPi and read various sensors, adjusted lighting and was driving some pumps with PWM. I was trying to grow some exotic plants and wanted to automate as much as possible. It was a fun project, the distributed nature of the language/OTP was really neat and when I bought the second Pi for monitoring the inside of a case it was very easy to hook it up with the former Pi and make it into one system. Unfortunately, all the plants died after a while - mostly because I didn't finish all the features I wanted to write fast enough... - and I abandoned it. I've been considering doing a write up on it since then, but I'm not sure if that would be interesting to anyone other than me. I wonder, would that count as creative? Maybe I should do the writeup after all (seeing as simply running some PHP on a few Pis got to the frontpage...) [1] https://github.com/piotrklibert/planties https://github.com/piotrklibert/planties
- pavel_lishin 8y agoI'd be very interested; I'm learning Elixir at a new job, and I've got a Raspberry Pi that's been sitting around since two christmases ago.
- 2sk21 8y agoThe main point of using a Raspberry Pi is for access to the GPIO pins and the built-in camera interface. As others have said, there are better alternatives if all you need is a server.
- bbayer 8y agoCan you name the alternatives?
- fimdomeio 8y agoRent a vps, digital ocean, linode... buy a desktop computer. My mac broke recently and while in the shop I bought a crappy new desktop for less than 200€. It's running linux and would happily run all this software. it becames cheaper than buying lots of raspberry pi's cases and sdcards and it's easier to mantain. But if one's doing it for the fun of it as the original author appear to have done, then I have no moral complains to present. :)
- lunchables 8y agoWhy is an old crappy desktop computer universally better than a raspberry pi? I use two raspberry pi to run internal DNS and a couple other things small things. They are silent, take up no space and use almost no power and are almost certainly cheaper.
- dragontamer 8y agoLaptops in general are okay alternatives if you want a "UPS" (battery) and so forth. The only problem is that Laptops have hit-or-miss Linux support. If Linux is a must, I'd argue that building a Desktop is easier, since you can verify which hardware works for Linux. (Pick motherboards that others have already tested). Something like a Ryzen 5 2500x build (6-core / 12-threads) would be far better than a Rasp. Pi for any home-server use. You got 4-DIMMs for easy 32GB support for tons of virtual servers. You have Hard Drives, SSDs, AVX2 (for high-speed H264 encoding), PCIe (GPU compute) and more. The standard Desktop is a beast these days. -------- For "clusters", a typical GPU like Vega64 or the RTX 2070 will get you far more performance at far cheaper prices. You can even toss two GPUs on a typical Desktop... maybe four GPUs if you go HEDT (Threadripper or i9-Extreme). That's all a modern supercomputer node is these days: just a normal CPU with 4x GPUs on it. High-performance SIMD programming is a bit difficult at first, but programming CUDA / OpenCL / AMD HCC is actually straightforward. Its the "high performance" part that gets difficult (but that's true of any programming). Your "cluster of GPUs" is the architecture of modern supercomputers. You can build one under $1500 (2x GPUs RTX 2060 or Rx 590 + Desktop with a bit more power-supply than usual). That's a Heterogeneous compute with 3-nodes (2x GPUs + 1x CPU) right there, plenty of room for experimentation and learning about communication. -------- IMO, the Rasp. Pi's main benefit is GPIO and I2C pins, as described by the other poster. Rasp. Pi works extremely well as a host to Arduino (since Arduino has better latency metrics to its GPIO). Effectively, Rasp. Pi is easier to program than Arduino, but Arduino is easier to interface from an electronics point of view (due to lower latency, no OS in the way, etc. etc.) But from a "serious compute" point of view, like servers or HPC, you probably should just get a normal desktop + graphics card. That's pretty much what a supercomputer is these days anyway.
- squarefoot 8y agoIt should be noted that most single board computers out there can be used to do the same things; a lot of them are more convenient than the Raspberries.