1. Get Debian/Ubuntu:
2. Optional OS upgrades:
3. Node.js tools:
1. [Install NVM](https://github.com/brettjrea/Debian_Install_NVM) - Node Version Manager- Install NVS - Node Version Switcher (added 02/23 it is a cross-platform node based successor/replacement for NVM)
4. Build tools:
5. Add a Backend:
6. Add a Frontend:
7. Configure Process Manager:
8. Add GitHub CLI:
sudo apt upgrade -y && sudo apt update -y && sudo apt autoremove -y &&
sudo apt install wget &&
sudo apt-get install --reinstall ca-certificates -y &&
wget https://raw.githubusercontent.com/brettjrea/Debian_Strapi_Backend_API/main/install-strapi.sh &&
chmod +x install-strapi.sh &&
./install-strapi.sh &&
sudo apt autoremove -y &&
sudo apt clean -y
cd ~/my-backend && yarn deploy
I seperated the command to start development because I am using PM2 from the link above. ☝️
sudo apt update -y && sudo apt upgrade -y && sudo apt autoremove -y &&
sudo apt install libvips libvips-dev libvips-tools python gir1.2-vips-8.0 make g++ -y &&
npm install -g yarn &&
yarn global add pm2 &&
yarn create strapi-app my-backend --quickstart --no-run &&
cd my-backend &&
echo "18.14.2" > .nvmrc && echo "const strapi = require('@strapi/strapi'); strapi().start();" > server.js &&
yarn strapi install graphql &&
pm2 start yarn --name my-backend -- start &&
sleep 20 &&
pm2 stop my-backend &&
pm2 delete all &&
yarn add strapi-plugin-init-admin-user &&
echo "INIT_ADMIN_USERNAME=admin
INIT_ADMIN_PASSWORD=admin
INIT_ADMIN_FIRSTNAME=Admin
INIT_ADMIN_LASTNAME=Admin
[email protected]" >> .env
cd ~/my-backend && yarn deploy