Although I've written a SSL management and distribution system, rcert, but the here immediately goes another problem: I still need to manually deploy the rcert, which is kind of frustrating. Or I can write some shell scripts to make this process automatically. Let's solve this (possibly) once and for all.
I built a handy (perhaps also buggy) software distribution system this time. This main purpose is of course to ease out the deployment process. And I'd like to call it
OwO, because this emoji looks so nice and cool. Moreover, it should be able to deploy itself once I have the initial instance ran.
Basically, it will serve these pages and API endpoints below (let's take owo.ryza.moe as its domain)
|Sign In||https://owo.ryza.moe/||Webpage API||No|
|Sign Out||https://owo.ryza.moe/||Webpage API||No|
|Compile-time Static Files||https://owo.ryza.moe/||Web Resources||Yes||These files are compiled into the final binary|
|Feature Image||https://owo.ryza.moe/||Web Resources||No||Feature Image for Specific Project|
|Install Script||https://owo.ryza.moe/||Web Resources||No||Install Script for Specific Project|
|Project Resources||https://owo.ryza.moe/||Web Resources||No||Resources for Specific Project|
|Update Project Info||https://owo.ryza.moe/||API Endpoint||Yes||Post|
|Upload Project Resource||https://owo.ryza.moe/||API Endpoint||Yes||Post, one file per request|
|Get Raw Install Script||https://owo.ryza.moe/||API Endpoint||Yes||Get|
|Remove Project for Version||https://owo.ryza.moe/||API Endpoint||Yes||Post|
|Remove Project Resource||https://owo.ryza.moe/||API Endpoint||Yes||Post|
Once I had decided these rules, the next question was which http server crate should I use. I considered
hyper, but let's try something else this time. Thus
actix_web as its http server framework.
OwO will output dynamic webpages, so it needs an HTML template engine. After some googling, I chose
ructe as the template engine to render dynamic webpages for
And here is the result of 3 days' coding!