{"id":13467725,"url":"https://github.com/saltcorn/saltcorn","last_synced_at":"2025-04-23T23:14:14.283Z","repository":{"id":36999392,"uuid":"249730865","full_name":"saltcorn/saltcorn","owner":"saltcorn","description":"Free and open source no-code application builder","archived":false,"fork":false,"pushed_at":"2025-04-23T17:45:14.000Z","size":154124,"stargazers_count":1811,"open_issues_count":506,"forks_count":313,"subscribers_count":34,"default_branch":"master","last_synced_at":"2025-04-23T23:13:36.723Z","etag":null,"topics":["no-code","nocode"],"latest_commit_sha":null,"homepage":"https://saltcorn.com/","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/saltcorn.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2020-03-24T14:31:21.000Z","updated_at":"2025-04-23T17:45:19.000Z","dependencies_parsed_at":"2024-01-17T05:31:54.367Z","dependency_job_id":"b605db87-db79-4446-a9aa-9595fae6025b","html_url":"https://github.com/saltcorn/saltcorn","commit_stats":{"total_commits":2597,"total_committers":30,"mean_commits":86.56666666666666,"dds":"0.15748941085868307","last_synced_commit":"8075029f6194ad699375189c07c6588a15ec9da8"},"previous_names":[],"tags_count":480,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saltcorn%2Fsaltcorn","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saltcorn%2Fsaltcorn/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saltcorn%2Fsaltcorn/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saltcorn%2Fsaltcorn/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/saltcorn","download_url":"https://codeload.github.com/saltcorn/saltcorn/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250528877,"owners_count":21445518,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["no-code","nocode"],"created_at":"2024-07-31T15:00:59.776Z","updated_at":"2025-04-23T23:14:14.265Z","avatar_url":"https://github.com/saltcorn.png","language":"JavaScript","funding_links":["https://opencollective.com/saltcorn"],"categories":["JavaScript","others","置顶","Application platforms","Rapid Development Tools"],"sub_categories":["1、AI应用生态","Samples","Web App Builders"],"readme":"[![Saltcorn Banner](https://user-images.githubusercontent.com/66894759/159173453-2ca63e71-1ff5-4f1e-b551-58b157b0de52.png)](https://saltcorn.com)\n\n[![Build and Test](https://github.com/saltcorn/saltcorn/workflows/Node.js%20CI/badge.svg)](https://github.com/saltcorn/saltcorn/actions/workflows/nodejs.yml) [![OpenCollective](https://img.shields.io/badge/OpenCollective-1F87FF?style=flat\u0026logo=OpenCollective\u0026logoColor=black)](https://opencollective.com/saltcorn)\n\n# Saltcorn\n\nSaltcorn is an extensible open source no-code database application builder. Use it to build web and mobile database applications with flexible views, datatypes, layouts and actions\n\nThis repository contains the core codebase, including the code necessary to self-host an instance and to host a multitenant instance.\n\n## Acknowledgements\n\nSaltcorn is using [PostgreSQL](https://github.com/postgres/postgres), [node.js](https://github.com/nodejs/node), [node-postgres](https://node-postgres.com/), [express](https://github.com/expressjs/express), [live-plugin-manager](https://www.npmjs.com/package/live-plugin-manager), [craft.js](https://craft.js.org/), [jQuery-Menu-Editor](https://github.com/davicotico/jQuery-Menu-Editor), [Blockly](https://developers.google.com/blockly), [CodeMirror](https://codemirror.net/) and other awesome free and open source projects.\n\n## Trying out Saltcorn\n\n#### Online\n\nA multitenant instance of Saltcorn is running at [saltcorn.com](https://saltcorn.com), and you can create a new application under a subdomain at [https://saltcorn.com/tenant/create](https://saltcorn.com/tenant/create).\nThis service is free but there are no guarantees about the security or availability of your application or the information you are storing. This service should only be used to explore the capabilities of Saltcorn.\n\n#### Desktop\n\nTo try out Saltcorn on your desktop, make sure you have node.js 18+ and npm installed. Then run these commands on the command line:\n\n```\nnpm config set prefix ~/.local\nnpm install -g @saltcorn/cli\nexport SQLITE_FILEPATH=~/saltcorn.sqlite\n.local/bin/saltcorn reset-schema -f\n.local/bin/saltcorn serve\n```\n\nNow open http://localhost:3000/ in your browser. When you want to run this again, you need to run the `export` line and the `saltcorn serve` line. or simply run `SQLITE_FILEPATH=~/saltcorn.sqlite .local/bin/saltcorn serve`.\n\n#### Server\n\nTo install Saltcorn on a fresh virtual machine, simply install node.js and run `npx saltcorn-install -y`; see [Quick install server on Linux](#quick-install-server-on-linux). To try out Saltcorn with docker-compose see [Quickstart with Docker](#quickstart-with-docker).\n\n## Hosting options\n\nFor self-hosting, a 2 GB virtual private server is sufficient to run Saltcorn unless you expect high traffic volumes. Installation instructions are given below. Saltcorn can also run on a 1GB virtual machine, but there can be issues with upgrading.\n\n[DigitalOcean](https://marketplace.digitalocean.com/apps/saltcorn) and [Linode](https://www.linode.com/marketplace/apps/linode/saltcorn/) have one-click install options for Saltcorn\n\nIf hosting on DigitalOcean, which offers a 2GB virtual machine for $12 per month, please consider using our [referral code](https://m.do.co/c/a1bcfb757fda) which will give you $100 credit over 60 days.\n\n## Quickstart with Docker\n\nYou can run a local instance for quick testing by running the following command:\n\n`cd ./deploy/examples/test \u0026\u0026 docker-compose up -d`\n\nand then go to http://localhost:3000 in your web browser.\n\nNOTE: The dependencies to build mobile apps are quite large, they are not installed in the standard docker image (saltcorn/saltcorn). To use an image that includes the mobile dependencies as well, either use 'saltcorn/saltcorn-with-mobile' directly or replace 'saltcorn/saltcorn' with 'saltcorn/saltcorn-with-mobile' in the docker-compose file.\n\n## Quick install server on Linux\n\nThis has been [tested on Debian 10, 11 and 12, Ubuntu 18.04, 20.04 and 22.04, OpenSuSE, AlmaLinux, and Fedora](https://releases.saltcorn.com/). All you need is to run these\nthree lines on the command line shell, as root or as a user with sudo access:\n\n```\nwget -qO - https://deb.nodesource.com/setup_18.x | sudo bash -\nsudo apt-get install -qqy nodejs\nnpx saltcorn-install -y\n```\n\nThe first two lines will install Node.js 18 (you can also use 20). The last line will call the Saltcorn install script\naccepting all the defaults, which installs PostgreSQL and sets up Saltcorn as a service\nlistening on port 80.\n\nIf you want a different port, different database backend, or to not install as a service, you\ncan omit the final `-y` to get an interactive installation:\n\n```\nwget -qO - https://deb.nodesource.com/setup_18.x | sudo bash -\nsudo apt-get install -qqy nodejs\nnpx saltcorn-install\n```\n\n## Install from NPM packages\n\nInstructions have been tested on Ubuntu 20.04 on a 1GB VM.\n\nTL;DR: `npm install -g @saltcorn/cli \u0026\u0026 saltcorn setup`\n\n### Installing node and npm\n\nFor a recent version (v18) of Node.js:\n\n```\nwget -qO - https://deb.nodesource.com/setup_18.x | sudo -E bash -\nsudo apt-get install -y nodejs libpq-dev build-essential python-is-python3\n```\n\nYou can also use Node 20 or 22.\n\n### Install Saltcorn\n\n`npm install -g @saltcorn/cli`\n\nIf this fails, you may need to tell npm to disregard file permissions during compilation:\n\n`npm install -g @saltcorn/cli --unsafe`\n\nSometimes, the above commands fail to install the library `sd-notify` (which is useful for\nintegrating with systemd) even though it is installable. You can rectify that by installing\nit subsequently:\n\n`npm install -g sd-notify`\n\n### Setup (automated)\n\nif you are `root`, create a user with sudo and switch to that user:\n\n```\nadduser saltcorn\nadduser saltcorn sudo\nsu saltcorn\ncd\nmkdir -p ~/.config/\n```\n\nthen run\n\n`saltcorn setup` and follow the instructions given.\n\n### Setup (manual)\n\nNOTE: this is somewhat out of date; see instead https://wiki.saltcorn.com/view/ShowPage?title=Install%20on%20Ubuntu, in paticular the last section.\n\nSkip this section if you ran `saltcorn setup` or `npx saltcorn-install`\n\n1. Install PostgreSQL: `sudo apt install postgresql postgresql-client`\n2. Either,\n\n   - Create a JSON file `.saltcorn` in your XDG config directory (on Ubuntu this is normally \\$HOME/.config) with these values:\n\n     - `host`: address of PostgreSQL server\n     - `port`: port of PostgreSQL server\n     - `database`: PostgreSQL database\n     - `user`: PostgreSQL user name\n     - `password`: PostgreSQL user password\n     - `sslmode`: PostgreSQL [SSL Mode](https://www.postgresql.org/docs/current/libpq-connect.html#LIBPQ-CONNECT-SSLMODE)\n     - `sslcert`: PostgreSQL [SSL Certificate](https://www.postgresql.org/docs/current/libpq-connect.html#LIBPQ-CONNECT-SSLCERT)\n     - `sslkey`: PostgreSQL [SSL Key](https://www.postgresql.org/docs/current/libpq-connect.html#LIBPQ-CONNECT-SSLKEY)\n     - `sslrootcert`: PostgreSQL [SSL Root Certificate](https://www.postgresql.org/docs/current/libpq-connect.html#LIBPQ-CONNECT-SSLROOTCERT)\n     - `session_secret`: Saltcorn session secret\n     - `multi_tenant`: run as multi-tenant (true/false)\n\n     For example:\n\n     ```\n     {\n        \"host\":\"localhost\",\n        \"port\":5432,\n        \"database\":\"saltcorn\",\n        \"user\":\"tomn\",\n        \"password\":\"dgg2342vfB\",\n        \"session_secret\":\"hrh64b45b3\",\n        \"multi_tenant\":true\n     }\n     ```\n\n     Or,\n\n   - Set environment variables. `SALTCORN_SESSION_SECRET`, `SALTCORN_MULTI_TENANT` (defaults to `false`), and either `DATABASE_URL` or `PGHOST`, `PGPORT`, `PGUSER`, `PGDATABASE`, `PGPASSWORD`. You can also set `PGSSLMODE`, `PGSSLCERT`, `PGSSLKEY`, `PGSSLROOTCERT` (see [Postgres Documentation](https://www.postgresql.org/docs/current/libpq-envars.html))\n\n### Run\n\n`saltcorn serve`\n\n### Server install\n\n#### Install Saltcorn as a service\n\nInstalling saltcorn as a service will mean it runs in the background and restarts automatically if the system reboots.\n\ncreate a file `/lib/systemd/system/saltcorn.service` with these contents:\n\n```\n[Unit]\nDescription=saltcorn\nDocumentation=https://saltcorn.com\nAfter=network.target\n\n[Service]\nType=notify\nWatchdogSec=30\nUser=saltcorn\nWorkingDirectory=/home/saltcorn\nExecStart=/home/saltcorn/.local/bin/saltcorn serve -p 80\nRestart=always\nEnvironment=\"NODE_ENV=production\"\n\n[Install]\nWantedBy=multi-user.target\n```\n\nrun:\n\n```\nsudo systemctl daemon-reload\nsudo systemctl start saltcorn\nsudo systemctl enable saltcorn\n```\n\nThis may be in a different location in non-Debian systems, e.g. in `/etc/systemd/system` instead.\n\nIn order to allow the `saltcorn` user to open port 80, you need to permission node.js to allow\nthis by running:\n\n```\nsudo setcap 'cap_net_bind_service=+ep' `which node`\n```\n\n#### SSL certificate\n\nUse [Let's Encrypt](https://letsencrypt.org/) or [Cloudflare](https://www.cloudflare.com/ssl/) to get a free SSL certificate (for https).\n\n## Install from source (for Saltcorn developers)\n\n### Installing node and npm on Ubuntu\n\n`sudo apt install nodejs npm libpq-dev`\n\nwill give you a usable version. For a more recent version (v18) of Node.js:\n\n```\nwget -qO - https://deb.nodesource.com/setup_18.x | sudo -E bash -\nsudo apt-get install -y nodejs libpq-dev\n```\n\n### Prepare Node\n\nassuming you have cloned this repository to \\$HOME/saltcorn (otherwise adjust PATH)\n\n```\nnpm config set prefix ~/.local\necho 'export PATH=$HOME/saltcorn/packages/saltcorn-cli/bin:$HOME/.local/bin:$PATH' \u003e\u003e ~/.bashrc\nsource ~/.bashrc\n```\n\n### Install packages\n\nrun\n\n```\nnpm install --legacy-peer-deps\nnpm run tsc\n```\n\nto install everything. If successful, you should now be able to run `saltcorn` in your shell.\n\n## Packages\n\n- [@saltcorn-cli](https://github.com/saltcorn/saltcorn/tree/master/packages/saltcorn-cli): command-line interface\n\n## Deployment tips\n\n- If your Saltcorn server is running behind a reverse proxy such as Nginx, refer to the [Socket.io reverse proxy documentation](https://socket.io/docs/v3/reverse-proxy/#nginx). This configuration is essential for Socket.io, which powers the chat, log-viewer, and streaming API functionalities (e.g. for the [recorder plugin](https://www.npmjs.com/package/@saltcorn/recorder)).\n\n## Development tips\n\n### Prettier\n\nwe use prettier:\n\n`npm install -g prettier`\n\nto format code:\n\n`git ls-files | grep -v builder_bundle | xargs prettier --write`\n\nRun this before every pull request.\n\n### dev server\n\n`nodemon packages/saltcorn-cli/bin/saltcorn serve`\n\nto also watch a local module\n\n`nodemon --watch ../saltcorn-kanban/ packages/saltcorn-cli/bin/saltcorn serve`\n\n### React build builder\n\n```\ncd packages/saltcorn-builder\nnpm install\nnpm install styled-components@4.4.1\nnpm run build\n```\n\n### React rebuild on save\n\nin `saltcorn/packages/saltcorn-builder/` run:\n\n`git ls-files | entr npm run builddev`\n\nbut this is not a production build, so run\n\n`npm run build`\n\nwhen done.\n\nIf you get this error: `Error: error:0308010C:digital envelope routines::unsupported`,\nrun this and try again: `export NODE_OPTIONS=--openssl-legacy-provider`.\n\n### Build tsdocs\n\n```\nnpm install --legacy-peer-deps\nnpm run tsc\n```\n\nthen\n\n`npm run docs`\n\nTSDocs will then be available in `docs/`.\n\nTo deploy these to https://saltcorn.github.io/tsdocs/:\n\n```\ncp -R docs/* /path/to/tsdocs\ncd /path/to/tsdocs\ngit add .\ngit commit -am 'version number or other message...'\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsaltcorn%2Fsaltcorn","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsaltcorn%2Fsaltcorn","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsaltcorn%2Fsaltcorn/lists"}