⏳Local setup in 3 minutes...
Local Setup
Follow these steps to set up your local environment for Ready SaaS. This will prepare your development environment to run the application locally.
1. Clone the Repo
Once you get Ready SaaS, you'll receive an invite to our private Github Repo.
Once you access the repo, grab the repo address and clone it
clone the repo running the following command in your terminal:
2. Install Dependencies
To install dependencies, we recommend using a virtual environment. A virtual environment isolates your Python/Django setup on a per-project basis, ensuring dependencies are kept separate from other projects.
In this guide we're using venv to manage our virtual environment.
Run each of these commands in order to create a virtual environment, and install all dependencies in it. You can replace .ready_saas
with the name of your project if you prefer.
Notice that the pip install -r requirements/local.txt
command installs all requirements listed in requirements/local.txt
. Ready SaaS let's you specify which dependencies should be included in each environment.
3. Database setup
To run Ready SaaS locally, you'll first need to create a Postgres DB and reference it within the project.
In order to do that, make sure you have Postgres installed.
To create a new db for your project, run the following command:
The above command expects you to provide your own postgres username
and your desired db_name
4. Environment Variables
Create an .env file
Within the project you'll find a .env-sample
file. You can rename it to .env
or copy it to create a new .env
file:
Database
Use the db_name
from the previous step to populate the DATABASE_URL
. Also include your Postgres credentials: db_user
and db_password
5. Database Migration
The following command will create the necessary tables in your local database.
6. Seed Database Subscription Plans
This optional step populates your local database with sample subscription plans, useful for development and testing. If you don't run this command, you will likely see an error when accessing pages that require a subscription plan to exist.
7. Create an Admin User
Creating an admin user allows you to access Django's admin interface to manage application data.
To create an admin user run the following command:
8. Run Locally
Now you're ready to start Django’s development server, making the application accessible on your local machine.
you can optionally specify the port number you'd like it to run on:
If you followed all the steps up to this point, you should have an identical instance of this page running in your local machine.
Yay! 🙌 You're done with the basic local setup!
If you want to change the content of that page right now, open and edit the following file:
ready_saas/templates/landing.html
Last updated