rabume / cfml-app-template

A template for a modern CFML application including a containerized environemnt for development and production.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

πŸ”§ CFML App Template

Template for a modern CFML application with a containerized development environment. This template does by no means always represents the state of the art or the best possible solution, but I hope someone can benefit from it.

✨ Used technologies

Backend

Frontend

  • Vue3 -> Frontend Framework

⚑ Prerequisites

  • Unix based OS (Linux, MacOS, WSL2)
  • Docker (>= 24.0.5) -> This version already includes docker compose
  • make (>= 4.4.1)
  • nvm
  • commandbox (optional -> Already running in docker container)
  • cflint (optional -> VsCode Extension which needs a JAR file)

πŸš€ Getting started

  1. Clone the repository:

    git clone https://github.com/rabume/cfml-app-template
  2. Enter the directory:

    cd cfml-app-template
  3. Copy the .env.example file to .env and adjust the variables to your needs
  4. Start development environment: make dev
  5. Access the application (if not changed in .env):

πŸ“ Note

Currently, the global key is being utilized for user authentication. In a real-world application, the user would be authenticated through a login form, generating a JWT token for subsequent requests. Please note that this is just a basic illustration.

πŸ“¦ Commands

Command Description
make dev Start development environment
make clean Remove all containers and volumes
make migrate Run database migrations (fresh)
make seed Run database seeds
make watch Watch for file changes

⛏️ Deployment

You can find the deployment configuration in the /deploy directory. Right now I use a makefile to automate the deployment process. This is optional and can be replaced. The prod.env.example contains the environment variables for the production environment. Instead of using a .env file, you can also set the environment variables directly on your server.

  • make deploy -> Deploy the application and runs the migrations

About

A template for a modern CFML application including a containerized environemnt for development and production.

License:MIT License


Languages

Language:ColdFusion 40.5%Language:Vue 33.3%Language:Makefile 7.7%Language:TypeScript 6.6%Language:SCSS 6.3%Language:Dockerfile 4.0%Language:HTML 1.6%