Stop Fighting Your Document Templates: Four Ways to Manage PPAT DOCX Templates in Production
Adding a single new letter like Surat Keterangan Hibah used to touch six backend files, two frontend files, and still break in production with a 404 Template not found until someone manually uploaded the .docx file. Here is why that happened—and how four different architectures trade off simplicity, deploy safety, and Word customizability.
TL;DR Recommendation
Move to Bundled Defaults + Optional Custom Overrides: ship default templates/*.docx inside the Docker image as the built-in fallback, use Postgres + R2 only when staff uploads a customized version, and let the client read labels directly from the API. New document types then go live on deploy with zero manual steps—while keeping full Word customizability and a one-click Reset to Default.