Dockerfile. Run fly launch to create an
application, and then proceed from there, running fly deploy after you make
changes. The recipes the follow contain fragments that can be added
to multiple cookbooks.
For best results, you are encouraged to try out each step. To do so, you will need to Log in to Fly. Nothing you do in this tutorial will exceed the Free Allowances provided.
These cookbooks can be more than mere educational materials. Using throwaway applications is
often better than experimenting in production when you want to make configuration changes.
Starting a minimal application, using flyctl ssh console to shell into that machine and
explore and make changes, rerunning fly deploy to reset the machine when those experiments
fail and making changes to your Dockerfile and fly.toml when things work is an effective
way to validate an approach before making changes to your application.
Let’s get started.
Cookbooks
- Minimal - full ruby, slim ruby, multi-stage build
- Databases - sqlite3, postgresql, mysql
- Node - support for esbuild, rollup, webpack
- API - api only rails servers with web front end
Recipes
- Sources - adding sources from outside of your
Dockerfile. - Optimizing builds - ordering, splitting, staging, and caching.
- Optimizing deployments - jemalloc, yjit, swap.