Skip to content

Latest commit

 

History

1 Commit

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

create-vermell-docker 🍂

npm scaffold that creates a Docker-ready Vermell web app.

Vermell is a minimal, zero-bloat web framework for modern C++ environments — fast, structural, and strictly typed. This package generates a ready-to-run project that builds and runs on top of the official Docker image vermellcc/vermell.

NodeJS Docker C++20 License: MIT

Table of Contents

  1. Usage
  2. What you get
  3. Quick Start (Docker)
  4. Local Build
  5. The Framework
  6. License

Usage

In an empty directory:

$ npm create vermell-docker

or, to scaffold into a new folder:

$ npm create vermell-docker my-app

You can also run it directly with npx:

$ npx create-vermell-docker my-app

What you get

my-app/
├── App.cpp              # your server (Router + routes + listen())
├── Dockerfile           # builds on vermellcc/vermell and compiles App.cpp
├── docker-compose.yml   # one-command Docker workflow (port 8080)
├── Makefile             # host build: g++ -std=c++20 App.cpp -o App -lvermell
├── Package.json         # convenience npm scripts (docker/make)
├── .dockerignore
└── .gitignore

The generated server is a minimal Vermell app:

#include <vermell/vermell.h>

int main() {
    Router router;
    router.setPort(8080);

    router.get("/", { [](Query &http) {
        http.send("Hello from Vermell");
    }});

    router.listen();
}

Quick Start (Docker)

The scaffold ships with everything needed to run inside Docker — no local C++ toolchain required:

$ cd my-app
$ docker compose up --build

or manually:

$ docker build -t vermell-app .
$ docker run --rm -p 8080:8080 vermell-app

Then open http://localhost:8080 — you should see Hello from Vermell.

The Dockerfile starts from the official image vermellcc/vermell (Debian bookworm with the framework installed) and builds the app against the installed library:

FROM vermellcc/vermell
WORKDIR /app
COPY . .
RUN g++ -std=c++20 App.cpp -o App -lvermell
EXPOSE 8080
CMD ["./App"]

Local Build

Requires Vermell installed on your machine (see Installation):

$ cd my-app
$ make
$ ./App

The scaffold also includes npm convenience scripts — npm run build / npm run start for Docker, npm run compose for Docker Compose, and npm run compile / npm run run for the host build.

The Framework

  • 📚 Full manual: vermell.cc — bilingual (EN/ES) documentation
  • 🏗 Source: github.com/vermellcc/vermell
  • 🐳 Docker image: vermellcc/vermell
  • ⚙️ Zero dependencies, non-blocking epoll event loop, C++20 — x86_64 and ARM (aarch64, armv7), WSL, Termux, Raspberry Pi, containers

License

This project is licensed under the MIT License.

About

npm scaffold that creates a Docker-ready vermell app

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages