Monorepo for Aesthetic.Computer
aesthetic.computer
1# SpiderLily Automated Build & Distribution System
2
3Complete automation for building and distributing SpiderLily game builds via DigitalOcean Spaces.
4
5## 🎯 Overview
6
7This system provides **around-the-clock automated builds** for SpiderLily on multiple platforms, with automatic upload to DigitalOcean Spaces and public distribution via `https://builds.false.work`.
8
9### What This Solves
10
11- ✅ **Zero-touch builds**: Trigger Mac/Windows/iOS builds from your dev container
12- ✅ **Automatic distribution**: Builds upload to Spaces and appear on builds.false.work
13- ✅ **Version management**: Timestamped builds + "latest" aliases
14- ✅ **Cost efficient**: Mac builds free, Windows ~$3/build, storage $5/month
15- ✅ **Public access**: Anyone can download builds from builds.false.work
16
17### Architecture
18
19```
20Dev Container (Linux)
21 ↓ SSH/gcloud
22Mac Mini M4 ←→ GCP Windows VM
23 ↓ build
24SpiderLily .app/.exe
25 ↓ compress + upload
26DigitalOcean Spaces (falsework-builds)
27 ↓ CDN
28https://builds.false.work
29```
30
31## 🚀 Quick Start
32
33### 1. Setup DigitalOcean Spaces
34
35```bash
36# Create a Space in DigitalOcean dashboard
37# Name: falsework-builds
38# Region: sfo3 (San Francisco)
39# Enable CDN: Yes
40# File Listing: Restricted
41
42# Or via CLI:
43doctl spaces create falsework-builds --region sfo3
44```
45
46### 2. Generate Access Keys
47
481. Go to: https://cloud.digitalocean.com/account/api/spaces
492. Click "Generate New Key"
503. Name: `falsework-builds`
514. Save the Key and Secret
52
53### 3. Configure Credentials
54
55Create `aesthetic-computer-vault/false.work/builds-spaces.env`:
56
57```bash
58BUILDS_SPACES_ENDPOINT=https://sfo3.digitaloceanspaces.com
59BUILDS_SPACES_KEY=DO00XXXXXXXXXXXXXXXXXX
60BUILDS_SPACES_SECRET=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
61BUILDS_SPACES_BUCKET=falsework-builds
62BUILDS_SPACES_REGION=sfo3
63BUILD_RETENTION_DAYS=30
64BUILD_WEBHOOK_URL= # Optional: Discord webhook for notifications
65```
66
67### 4. Install Dependencies
68
69**On Dev Container (already installed):**
70- `s3cmd` - S3-compatible CLI for Spaces
71- `sshpass` - SSH automation
72- `gcloud` - GCP CLI (for Windows VM)
73
74**On Mac Mini:**
75```bash
76brew install s3cmd
77```
78
79**On Windows VM:**
80```powershell
81# Install AWS CLI (S3-compatible)
82choco install awscli
83```
84
85### 5. Test Upload
86
87```bash
88# From dev container, trigger Mac build + upload
89cd /workspaces/aesthetic-computer/false.work/unreal-builder/scripts
90fish schedule-builds.fish nightly mac
91```
92
93This will:
941. SSH to Mac Mini
952. Build SpiderLily.app
963. Compress to .tar.gz
974. Upload to Spaces
985. Update builds.false.work/index.html
99
100## 📋 Usage
101
102### Trigger Builds
103
104```bash
105cd /workspaces/aesthetic-computer/false.work/unreal-builder/scripts
106
107# Build all platforms
108fish schedule-builds.fish nightly all
109
110# Build specific platform
111fish schedule-builds.fish release mac
112fish schedule-builds.fish release windows
113fish schedule-builds.fish release ios
114
115# Custom version
116fish schedule-builds.fish release mac 1.0.0
117```
118
119### Manual Upload (if build exists)
120
121```bash
122# Upload existing Mac build
123./upload-to-spaces.sh mac ~/Perforce/.../Packaged/Mac/SpiderLily.app 1.0.0
124
125# Upload Windows build
126./upload-to-spaces.sh windows D:/Builds/123/WindowsNoEditor 1.0.0
127
128# Upload iOS build
129./upload-to-spaces.sh ios ~/Perforce/.../Packaged/IOS/SpiderLily.app 1.0.0
130```
131
132### Update builds.false.work
133
134```bash
135# After uploading, update the public index
136./update-builds-index.sh mac 1.0.0
137./update-builds-index.sh windows 1.0.0
138./update-builds-index.sh ios 1.0.0
139
140# Then commit and push
141cd /workspaces/aesthetic-computer
142git add false.work/builds.false.work/ system/public/builds.false.work/
143git commit -m "Add SpiderLily builds"
144git push
145```
146
147## 🛠️ Scripts Reference
148
149### `schedule-builds.fish`
150Orchestrates builds on remote machines from dev container.
151```bash
152fish schedule-builds.fish <type> <platform>
153# type: nightly, release, hotfix
154# platform: all, mac, windows, ios
155```
156
157### `upload-to-spaces.sh`
158Compresses and uploads builds to DigitalOcean Spaces.
159```bash
160./upload-to-spaces.sh <platform> <build_path> [version]
161```
162
163### `update-builds-index.sh`
164Updates builds.false.work with new download links.
165```bash
166./update-builds-index.sh <platform> <version>
167```
168
169### `mac/build-and-upload.sh`
170Complete Mac pipeline: build → compress → upload → update index.
171```bash
172./mac/build-and-upload.sh [version]
173```
174
175### `windows-build-and-upload.ps1`
176Complete Windows pipeline (runs on GCP VM).
177```powershell
178.\windows-build-and-upload.ps1 -Version "1.0.0" -Config "Development"
179```
180
181## 🌐 Distribution
182
183Builds are available at:
184- **Public website**: https://builds.false.work
185- **Direct CDN URLs**: `https://falsework-builds.sfo3.cdn.digitaloceanspaces.com/{platform}/{filename}`
186- **Latest aliases**: `spiderlily-{platform}-latest.tar.gz` or `.zip`
187
188### Download URLs
189
190```
191Mac:
192https://falsework-builds.sfo3.cdn.digitaloceanspaces.com/mac/spiderlily-mac-2025.11.05.14.30.tar.gz
193https://falsework-builds.sfo3.cdn.digitaloceanspaces.com/mac/spiderlily-mac-latest.tar.gz
194
195Windows:
196https://falsework-builds.sfo3.cdn.digitaloceanspaces.com/windows/spiderlily-windows-2025.11.05.14.30.zip
197https://falsework-builds.sfo3.cdn.digitaloceanspaces.com/windows/spiderlily-windows-latest.zip
198
199iOS:
200https://falsework-builds.sfo3.cdn.digitaloceanspaces.com/ios/spiderlily-ios-2025.11.05.14.30.tar.gz
201https://falsework-builds.sfo3.cdn.digitaloceanspaces.com/ios/spiderlily-ios-latest.tar.gz
202```
203
204## 📊 Storage Management
205
206### List All Builds
207
208```bash
209s3cmd ls s3://falsework-builds/mac/
210s3cmd ls s3://falsework-builds/windows/
211s3cmd ls s3://falsework-builds/ios/
212```
213
214### Check Storage Usage
215
216```bash
217s3cmd du s3://falsework-builds/
218```
219
220### Delete Old Builds
221
222```bash
223# Delete builds older than 30 days
224s3cmd ls s3://falsework-builds/ | \
225 awk '{if ($1 < "2025-10-01") print $4}' | \
226 xargs -I {} s3cmd del {}
227```
228
229### Set Lifecycle Policy (Auto-delete)
230
231Create `lifecycle.json`:
232```json
233{
234 "Rules": [
235 {
236 "ID": "delete-old-builds",
237 "Status": "Enabled",
238 "Prefix": "",
239 "Expiration": {
240 "Days": 30
241 }
242 }
243 ]
244}
245```
246
247Apply:
248```bash
249aws s3api put-bucket-lifecycle-configuration \
250 --bucket falsework-builds \
251 --endpoint-url https://sfo3.digitaloceanspaces.com \
252 --lifecycle-configuration file://lifecycle.json
253```
254
255## 💰 Cost Breakdown
256
257| Service | Details | Monthly Cost |
258|---------|---------|--------------|
259| **DigitalOcean Spaces** | 250GB storage + 1TB bandwidth + CDN | $5 |
260| **Mac Builder** | M4 Mac Mini (local) | $0 |
261| **Windows Builder** | GCP n2-standard-8 (on-demand) | ~$3/build |
262| **Bandwidth** | After 1TB: $0.01/GB | ~$0-5 |
263| **Total** | For ~10 builds/month | **~$35-40** |
264
265Compare to AWS EC2 Mac instances: **$800+/month** 🎉
266
267## 🔒 Security
268
269- ✅ Credentials stored in `aesthetic-computer-vault` (private submodule)
270- ✅ Files publicly readable but bucket listing restricted
271- ✅ HTTPS-only access via CDN
272- ✅ SSH access to builders password-protected
273- ✅ GCP VM uses service account keys
274
275## 🐛 Troubleshooting
276
277### Upload fails with "403 Forbidden"
278- Check Spaces keys in `builds-spaces.env`
279- Verify bucket name and region match
280
281### Can't SSH to Mac Mini
282- Check credentials in `mac-builder-credentials.env`
283- Test: `ssh falseworks@host.docker.internal`
284
285### Windows build fails
286- Ensure GCP VM is running: `gcloud compute instances list`
287- Check Perforce connection: `p4 info`
288- Verify UE5.6 installed at `C:\Program Files\Epic Games\UE_5.6`
289
290### builds.false.work not updating
291- Run `./update-builds-index.sh` manually
292- Commit and push changes to git
293- Netlify will auto-deploy
294
295## 📚 Related Documentation
296
297- [../README.md](../README.md) - Main false.work build system docs
298- [MAC-SETUP-PLAN.md](MAC-SETUP-PLAN.md) - Mac builder setup guide
299- [BUILD-AUTOMATION-GUIDE.md](BUILD-AUTOMATION-GUIDE.md) - General automation guide
300- [../../at/pds/STORAGE.md](../../at/pds/STORAGE.md) - DigitalOcean Spaces reference
301
302---
303
304**Engineered by [Aesthetic Inc.](https://aesthetic.direct)**
305Questions? [@jeffrey on prompt.ac](https://prompt.ac/chat)