Deploying What To Cook
Introduction
What To Cook is a self-hosted recipe management and meal planning application designed to help you answer the eternal question: “What should I cook today?” It provides an intuitive interface for storing recipes, planning weekly meals, and generating shopping lists based on your meal plan.
The application focuses on simplicity and practical features that make daily meal planning easier for individuals and families.
Key features of What To Cook include:
- Recipe Management: Store and organize your favorite recipes
- Meal Planning: Plan meals for the week or month
- Shopping Lists: Auto-generate shopping lists from meal plans
- Ingredient Tracking: Track what you have in your pantry
- Recipe Import: Import recipes from URLs
- Categorization: Organize recipes by meal type, cuisine, or custom tags
- Search and Filter: Quickly find recipes by ingredients or name
- Serving Adjustment: Scale recipes up or down
- Mobile-Friendly: Access and cook from your phone or tablet
- Family Sharing: Share meal plans with family members
This guide walks you through deploying What To Cook on Klutch.sh using Docker for meal planning.
Prerequisites
Before deploying What To Cook on Klutch.sh, ensure you have:
- A Klutch.sh account
- A GitHub account with a repository for your configuration
- Basic familiarity with Docker concepts
Repository Structure
Create a GitHub repository with the following structure:
what-to-cook-deploy/├── Dockerfile└── .dockerignoreDockerfile
Create a Dockerfile in your repository:
FROM whattoeattoday/what-to-cook:latest
# Web interface portEXPOSE 3000
# The base image handles the entrypointEnvironment Variables
| Variable | Required | Default | Description |
|---|---|---|---|
DATABASE_URL | No | SQLite | Database connection string |
SECRET_KEY | Yes | - | Application secret key |
Deployment on Klutch.sh
- Push your Dockerfile to your GitHub repository.
- Log in to Klutch.sh and create a new project.
- Create a new app within your project and connect your GitHub repository containing the Dockerfile.
- Configure the deployment settings: - Select **HTTP** as the traffic type - Set the internal port to **3000**
- Add environment variables: - `SECRET_KEY`: A secure random string
- Attach a persistent volume: - Mount path: `/app/data` - Recommended size: 1 GB - Purpose: Database and recipe images
- Click **Deploy** and wait for the build to complete.
- Access your What To Cook instance and create your account.
Post-Deployment Setup
After deployment:
- Create your user account
- Add your favorite recipes manually or import from URLs
- Set up your weekly meal plan
- Generate shopping lists
- Invite family members if desired
Usage Tips
Weekly Meal Planning
- Navigate to the meal planner
- Drag and drop recipes to different days
- Generate a shopping list for the week
- Check off items as you shop
Recipe Import
Many recipe websites can be imported by pasting the URL. The application will extract ingredients and instructions automatically.
Troubleshooting
Recipe Import Failing
Not all recipe websites are supported for import. Try manually entering recipes that fail to import.
Images Not Loading
Ensure the persistent volume is correctly mounted and has sufficient space.