mirror of
https://github.com/simstudioai/sim.git
synced 2026-09-24 15:45:35 +08:00
* fix(cli): generate per-install secrets instead of using fixed values The launcher passed the same built-in BETTER_AUTH_SECRET and ENCRYPTION_KEY to every install. Generate them once per install, persist them 0600 at ~/.simstudio/secrets.env, and reuse them on later runs so data already in the Postgres volume stays readable. Also passes INTERNAL_API_SECRET, which the realtime container requires and never received. * fix(cli): reassert owner-only permissions on the secrets file writeFileSync's `mode` applies only when it creates the file, and the write is skipped entirely when the stored values are already valid — so a secrets file left with permissive permissions kept them. chmod it on every run. * fix(cli): write the secrets file atomically Regenerating any one key rewrites all of them, and a plain write truncates first — a crash mid-rewrite would strand a still-valid ENCRYPTION_KEY and orphan the data it protects. Write to a temp file and rename into place.
Sim CLI
Sim CLI allows you to run Sim using Docker with a single command.
Installation
To install the Sim CLI globally, use:
npm install -g simstudio
Usage
To start Sim, simply run:
simstudio
Options
-p, --port <port>: Specify the port to run Sim on (default: 3000).--no-pull: Skip pulling the latest Docker images.
Requirements
- Docker must be installed and running on your machine.
Contributing
Contributions are welcome! Please open an issue or submit a pull request.
License
This project is licensed under the Apache-2.0 License.