Skip to content

Commit 9065305

Browse files
committed
Add some deployment ideas
1 parent 286b1e5 commit 9065305

1 file changed

Lines changed: 36 additions & 0 deletions

File tree

backend/ddd/README.md

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,3 +74,39 @@
7474
17. An Account can add Blogs (by feed URL)
7575
18. An Account can follow Blogs
7676
19. An Account can unfollow Blogs
77+
78+
## Deployment
79+
80+
1. JS code needs to be pulled and built, so just do that for both?
81+
2. Configure MFD to:
82+
1. Build the backend Go API
83+
2. Build the frontend SvelteKit project
84+
3. Flip the symlink
85+
4. Cleanup any old dirs
86+
3. Restart the bloggulus-api service
87+
1. Points to /usr/local/src/bloggulus/active/backend/bloggulus file
88+
4. Restart the bloggulus-web service
89+
1. Points to /usr/local/src/bloggulus/active/frontend/build directory
90+
91+
Orrrr....
92+
93+
1. Build the FE to an output build/ directory
94+
2. Embed the whole FE output into the single Go binary
95+
3. At startup, write the embedded build dir to temp using os.CopyFS
96+
4. Exec a NodeJS process to run the frontend (in a background goro)
97+
5. Run the Go API like normal
98+
6. This might be terrible. Doesn't handle systemd sockets (or restarts) well.
99+
100+
Orrrr....
101+
102+
1. Just do the first strat but without mfd?
103+
2. Checkout the new commit into a fresh dir
104+
3. Build the backend Go API
105+
4. Build the frontend SvelteKit project
106+
5. Flip the symlink
107+
6. Cleanup any old dirs
108+
7. Restart the bloggulus-api service
109+
1. Points to /usr/local/src/bloggulus/active/backend/bloggulus file
110+
8. Restart the bloggulus-web service
111+
1. Points to /usr/local/src/bloggulus/active/frontend/build directory
112+
9. Cleanup any old dirs

0 commit comments

Comments
 (0)