Appearance
Local Setup
Prerequisites
Generated applications come with a fully configured and configurable local development environment. To get started, you will need to install Docker.
If you haven't generated an app yet, you can use our demo app to get familiar with the environment. You can always build your own app using our open source app base, but to unlock the full power of codecannon, you should generate your own app on app.codecannon.dev.
If you're unsure how to do this, please refer to the Getting Started guide.
First time setup
- Clone the repository
bash
# Replace github repo URL with your own upon code delivery
git clone https://github.com/codecannon/demo-app.git
- Copy the local example .env file
bash
cp .env.example .env
cp api/.env.example api/.env
cp ui/.env ui/.env.local
- Start the local environment
bash
docker compose up
Configuring local environment
You can change your settings in the .env file in the root of the repository (.env.example
).
Changing the application host
You can change the application host (URL) by changing the APP_URL
variable in the .env
file. This will change the URL at which the application is accessible.
sh
# APP_URL: Application URL (both frontend and backend).
# URL should be without trailing slash, and wihtout http/https prefix.
# Example: localhost
APP_URL=localhost
Changing the application port
You can change the application port by changing the APP_PORT
variable in the .env
file. This will change the port at which the application is accessible.
sh
# APP_URL: Application port (both frontend and backend).
# Should be a valid port number.
# Example: 80
APP_PORT=80
See also: