- Notifications
You must be signed in to change notification settings - Fork268
✨ A complete and self-contained solution for developers of any qualification to create a production-ready project with backend (Go), frontend (JavaScript, TypeScript) and deploy automation (Ansible, Docker) by running only one CLI command.
License
create-go-app/cli
Folders and files
| Name | Name | Last commit message | Last commit date | |
|---|---|---|---|---|
Repository files navigation
Create a new production-ready project withbackend (Golang),frontend (JavaScript, TypeScript)
anddeploy automation (Ansible, Docker) by running one CLI command.
Focus onwriting code andthinking of business-logic! The CLI will take care of the rest.
First,download and installGo. Version1.17 or higher is required.
If you're looking for theCreate Go App CLI for Go
1.16, you can find ithere.
Installation is done by using thego install command and rename installed binary in$GOPATH/bin:
go install github.com/create-go-app/cli/v3/cmd/cgapp@latest
Also, macOS and GNU/Linux users available way to install viaHomebrew:
# Tap a new formula:brew tap create-go-app/cli# Installation:brew install create-go-app/cli/cgapp
Let's create a new project viainteractive console UI (orCUI for short) in current folder:
cgapp create
Next, open the generated Ansible inventory file (calledhosts.ini) and fill in the variables according to your server configuration. And you're ready toautomatically deploy this project:
cgapp deploy
That's all you need to know to start! 🎉
If you don't want to install Create Go App CLI to your system, you feel free to using our officialDocker image and run CLI from isolated container:
docker run --rm -it -v${PWD}:${PWD} -w${PWD} koddr/cgapp:latest [COMMAND]
🔔 Please note: the
deploycommand is currentlyunavailable in this image.
The best way to better explore all the features of theCreate Go App CLI is to read the projectWiki and take part inDiscussions and/orIssues. Yes, the most frequently asked questions (FAQ) are alsohere.
CLI command for create a new project with the interactive console UI.
cgapp create [OPTION]
| Option | Description | Type | Default | Required? |
|---|---|---|---|---|
-t | Enables to define custom backend and frontend templates. | bool | false | No |
- 📺 Full demo video:https://recordit.co/OQAwkZBrjN
- 📖 Docs:https://github.com/create-go-app/cli/wiki/Command-create
CLI command for deploy Docker containers with your project via Ansible to the remote server.
🔔 Make sure that you havePython 3.8+ andAnsible 2.9+ installed on your computer.
cgapp deploy [OPTION]
| Option | Description | Type | Default | Required? |
|---|---|---|---|---|
-k | Prompt you to provide the remote user sudo password (a standard Ansible--ask-become-pass option). | bool | false | No |
- 📺 Full demo video:https://recordit.co/ishTf0Au1x
- 📖 Docs:https://github.com/create-go-app/cli/wiki/Command-deploy
- Backend template with Golang built-innet/http package:
net/http— simple REST API with CRUD and JWT auth.
- Backend template withFiber:
fiber— complex REST API with CRUD, JWT auth with renew token, DB and cache.
- Backend template withgo-chi:
chi— a basic application with healthcheck.
- Pure JavaScript frontend template:
vanilla— generated template with pure JavaScript app.vanilla-ts— generated template with pure TypeScript app.
- Frontend template withReact:
react— generated template with a common React app.react-ts— generated template with a TypeScript version of the React app.
- Frontend template withPreact:
preact— generated template with a common Preact app.preact-ts— generated template with a TypeScript version of the Preact app.
- Frontend template withNext.js:
next— generated template with a common Next.js app.next-ts— generated template with a TypeScript version of the Next.js app.
- Frontend template withNuxt 3:
nuxt3— generated template with a common Nuxt 3 app.
- Frontend template withVue.js:
vue— generated template with a common Vue.js app.vue-ts— generated template with a TypeScript version of the Vue.js app.
- Frontend template withSvelte:
svelte— generated template with a common Svelte app.svelte-ts— generated template with a TypeScript version of the Svelte app.
- Frontend template withLit web components:
lit-element— generated template with a common Lit app.lit-element-ts— generated template a TypeScript version of the Lit app.
☝️ Frontend part will be generate using awesome toolVite.js under the hood. So, you'll always get the latest version of
React,Preact,Vue,Svelte,Litor pure JavaScript/TypeScript templates for your project! And theNext.jsandNuxt 3frontend parts will be generated using thecreate-next-appandnuxiutilities.Please make sure that you have
npmversion7or higher installed to create the frontend part of the project correctly. If you run thecgapp createcommand using ourDocker image,npmof the correct version isalready included.
- Roles for run Docker container withTraefik Proxy:
traefik— configured Traefik container with a simple ACME challenge via CA server.traefik-acme-dns— configured Traefik container with a complex ACME challenge via DNS provider.
- Roles for run Docker container withNginx:
nginx— pure Nginx container with "the best practice" configuration.
✌️ Since Create Go App CLI
v2.0.0, we're recommend to useTraefik Proxy as default proxy server for your projects. The main reason: this proxy providesautomatic SSL certificates from Let's Encrypt out of the box. Also, Traefik was built on the Docker ecosystem and has areally good looking anduseful Web UI.
- Roles for run Docker container withPostgreSQL:
postgres— configured PostgreSQL container with apply migrations for backend.
- Roles for run Docker container withRedis:
redis— configured Redis container for backend.
If you want to saythank you or/and support active development ofCreate Go App CLI:
- Add aGitHub Star to the project.
- Tweet about projecton your Twitter.
- Write interesting articles about project onDev.to,Medium or personal blog.
- Join DigitalOcean at ourreferral link (your profit is$100 and we get $25).
Together, we can make this projectbetter every day! 😘
Create Go App CLI is free and open-source software licensed under theApache 2.0 License. Officiallogo was created byVic Shóstak and distributed underCreative Commons license (CC BY-SA 4.0 International).
About
✨ A complete and self-contained solution for developers of any qualification to create a production-ready project with backend (Go), frontend (JavaScript, TypeScript) and deploy automation (Ansible, Docker) by running only one CLI command.
Topics
Resources
License
Code of conduct
Contributing
Security policy
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Uh oh!
There was an error while loading.Please reload this page.


