Skip to content

Commit e20cbb2

Browse files
author
AtomicNicos
committed
some work
1 parent c332a71 commit e20cbb2

File tree

7 files changed

+70
-5
lines changed

7 files changed

+70
-5
lines changed

src/app/content/2022/220504-raspi-tooling/raspi-tooling.component.html

Lines changed: 66 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,70 @@
11
<app-post-body [post]="this.post" [date]="this.post.date">
2-
- Raspberry PI
3-
- Shell
4-
"pic of shell"
5-
- Small deployed web service
2+
<p>I was recently asked whether I could a family member out, as they needed a custom inventory management platform for pieces of a family art collection.</p>
3+
<p>I accepted, although I probably shouldn't have.</p>
4+
<p>I'll go over how the project services were designed, how it is being hosted, and more, in this article.</p>
5+
6+
<h4>Run-down</h4>
7+
<ul>
8+
<li><a class='no-underline' routerLink='.' fragment='the-service-architecture'>The service architecture</a></li>
9+
<li><a class='no-underline' routerLink='.' fragment='the-pi'>The Pi</a></li>
10+
<li><a class='no-underline' routerLink='.' fragment='what-does-it-run'>What does it run?</a></li>
11+
</ul>
12+
13+
<hr/>
14+
<h4 id='the-service-architecture'>The service architecture</h4>
15+
<p>The project follows a pretty simple design: the web frontend is how the user interacts with the service, the backend is how the service saves the data to a database.</p>
16+
<p>Due to my past experience, I decided to write the frontend in Angular, and the backend in Python, using FastAPI as the middleware. The database would use PostgreSQL</p>
17+
18+
<br/>
19+
<h4 id='the-pi'>The Pi</h4>
20+
<p>For a myriad of reasons, we decided to use a local system, and decided to do so on a Raspberry Pi 4.</p>
21+
<p>The Pi has a number of advantages, but the one I retained was that one could have it boot off of an SSD, rather than the traditional SD card.</p>
22+
<p>Another neat thing is that there are a lot of case designs to 3D print, and I found a design that allows for an SSD, and additional ventilation fans.</p>
23+
24+
<br/>
25+
<p>Link thingiverse</p>
26+
<p>The first element was to fit the SSD into the casing. In order to have it snug against the base, I flipped it from its original configuration.</p>
27+
28+
<div class='media-container'>
29+
<img src='/assets/images/2022/220504-raspi-tooling/ssd.jpg' alt='The base casing with the SSD'>
30+
<span><em>The base casing with the SSD</em></span>
31+
</div>
32+
33+
<p>This meant that, in order to have the Pi itself fit snugly in the casing, a strut of sorts was needed. I designed it by using the RasPi design sheet.</p>
34+
35+
<div class='media-container'>
36+
<img src='/assets/images/2022/220504-raspi-tooling/support.jpg' alt='The RaspberryPi strut'>
37+
<span><em>The RaspberryPi strut</em></span>
38+
</div>
39+
40+
<p>The Raspberry Pi then aligned perfectly with the holes in the casing, letting me start with the ventilation, which consists of a CPU heatsink/ventilator unit, and a casing 40mm ventilator.</p>
41+
42+
<div class='media-container'>
43+
<img src='/assets/images/2022/220504-raspi-tooling/raspi-fitting.jpg' alt='The fitted RaspberryPi'>
44+
<span><em>The fitted RaspberryPi</em></span>
45+
</div>
46+
47+
<div class='media-container'>
48+
<img src='/assets/images/2022/220504-raspi-tooling/ventilation.jpg' alt='The RaspberryPi with the ventilation'>
49+
<span><em>The RaspberryPi with the ventilation</em></span>
50+
</div>
51+
52+
<p>The final device, bar some cables, looks like this:</p>
53+
54+
<div class='media-container'>
55+
<img src='/assets/images/2022/220504-raspi-tooling/closed.jpg' alt='The completed RaspberryPi'>
56+
</div>
57+
58+
<br/>
59+
<h4 id='what-does-it-run'>What does it run?</h4>
60+
61+
<p>From the get go I decided that I would use containerized applications, probably using Docker.</p>
62+
<p>This somewhat restricted my choice of platforms, so I went with a very lightweight and headless version of Ubuntu, which I flashed onto the SSD.</p>
63+
64+
<p>I then installed containerd, docker and docker-compose for the management of our services.</p>
65+
<p></p>
66+
67+
- Small deployed web service
668
- Ubuntu
769
- Docker
870
- ufw
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
img {
2+
width: 50%;
3+
}

src/app/routing/app.sub-routes-2022.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,6 @@ export const subroutes2022: Routes = [
114114
date: [2022, 4, 26]
115115
}
116116
},
117-
/*
118117
{
119118
path: '2022_05_04+Building-a-raspi-private-web-server',
120119
component: May2022RaspiToolingComponent,
@@ -126,6 +125,7 @@ export const subroutes2022: Routes = [
126125
date: [2022, 5, 4]
127126
}
128127
},
128+
/*
129129
{
130130
path: '2022_05_15+winning-the-wavegame',
131131
component: May2022WavegameComponent,
Loading
Loading
Loading
Loading

0 commit comments

Comments
 (0)