Start from a template
cohostly new writes a tiny starter project in one of six kinds, so you can see the whole path once.
cohostly new writes a small working project into a folder. It is a seed packet: you plant it, then watch it grow with cohostly deploy. It needs no network and no sign-in.
cohostly new <template> [folder]
The six templates
staticindex.html.flaskrequirements.txt (Flask 3.0.3) and app.py, which listens on port 8080 on all addresses.fastapirequirements.txt (FastAPI 0.115.0 and Uvicorn 0.30.6) and main.py. It writes no start command, so a deploy relies on the platform detecting one.expresspackage.json (with a start script that runs node server.js) and server.js, which listens on port 3000.gogo.mod (Go 1.21) and main.go, which listens on port 8080.nextjspackage.json, app/layout.js and app/page.js.Usage
folderis optional. The default ismy-<template>-appinside the current folder.- The folder must be new or empty. If it is not, the command stops.
- Anything that starts with
--is ignored.
What it prints
$ cohostly new express hello Created hello/ (A Node web app with Express.) Next: cd hello platform deploy
The last line says platform deploy. Typing cohostly deploy does the same.
Failures
Unknown template "x". Usage: platform new <template> [folder]1.<dir> already exists and is not empty. Pick another folder name.1.Examples
Make a plain website in the default folder:
cohostly new static cd my-static-app cohostly deploy
Make a Flask app called notes, then deploy it under a name of your choice:
cohostly new flask notes cd notes cohostly deploy --project notes-demo
Good to know The templates are meant to deploy as they are. The
fastapione has no start command written, so if its first deploy fails with a start problem, add a start command with--startor incohostly.json. See put an app online.
Read next
Up next · Command lineDeployDeploy a folder with cohostly deploy: every flag, what gets uploaded, how .env files are handled, the settings question, and what the output means.Keep reading
← Back to Sign in and keys