diff --git a/docs/frontend.md b/docs/frontend.md new file mode 100644 index 00000000..79f39743 --- /dev/null +++ b/docs/frontend.md @@ -0,0 +1,20 @@ +--- +title: Just the frontend (Svelte) +category: development +description: Learn how to focus purely on UI and frontend development using + Svelte with pockethost.io. Simply clone our repository, install the needed + packages and start a local build to connect directly to the `pockethost.io` + mothership for seamless database tasks. No backend setup, all fun and + function. +--- + +Just want to work with the UI and frontend? + +```bash +git clone git@github.com:benallfree/pockethost.git +cd pockethost +yarn +yarn dev:www +``` + +That's it. You're in business. Your local Svelte build will talk to the `pockethost.io` mothership and connect to that for all database-related tasks. diff --git a/packages/www/content/docs/development/full-stack/dnsmasq.md b/docs/full-stack/dnsmasq.md similarity index 100% rename from packages/www/content/docs/development/full-stack/dnsmasq.md rename to docs/full-stack/dnsmasq.md diff --git a/packages/www/content/docs/development/full-stack/etc_hosts.md b/docs/full-stack/etc_hosts.md similarity index 100% rename from packages/www/content/docs/development/full-stack/etc_hosts.md rename to docs/full-stack/etc_hosts.md diff --git a/packages/www/content/docs/development/full-stack/index.md b/docs/full-stack/index.md similarity index 100% rename from packages/www/content/docs/development/full-stack/index.md rename to docs/full-stack/index.md diff --git a/packages/www/content/docs/development/full-stack/local-domain-setup.md b/docs/full-stack/local-domain-setup.md similarity index 100% rename from packages/www/content/docs/development/full-stack/local-domain-setup.md rename to docs/full-stack/local-domain-setup.md diff --git a/packages/www/content/docs/hosting/overview.md b/docs/hosting/overview.md similarity index 100% rename from packages/www/content/docs/hosting/overview.md rename to docs/hosting/overview.md diff --git a/packages/www/content/docs/introduction.md b/docs/introduction.md similarity index 60% rename from packages/www/content/docs/introduction.md rename to docs/introduction.md index 41e3ff81..1024b19e 100644 --- a/packages/www/content/docs/introduction.md +++ b/docs/introduction.md @@ -1,23 +1,13 @@ --- title: Introduction -category: getting-started +category: overview description: PocketHost, a powerful cloud hosting platform for PocketBase, allows you to create unlimited projects quickly and easily. With no backend setup required, it manages all the Linux/devops tasks, from email and DNS jargon to SSL management and CDN hosting, so developers can solely focus on building their apps. - --- -# Overview - -Starting a new project on PocketHost is as effortless as creating a project on Firebase or Supabase. Simply choose a custom subdomain and each PocketBase instance is instantly provisioned and managed on `pockethost.io`. Our cloud-hosted environment is built with speed and scalability in mind, and you can access your PocketBase instance using the PocketBase JavaScript SDK. It's as simple as `new PocketBase('https://my-project.pockethost.io')`. - -We know that many web and nodejs programmers choose SvelteKit, React, Vercel, Firebase, and Supabase for their ease of use. That's why we've mirrored that simplicity with PocketHost. Set up a live PocketBase instance with no backend setup. Once you've created an account at pockethost.io, you can provision your first PocketBase instance and connect from anywhere. - -With PocketHost, you can forget about the time-consuming tasks of managing Linux/devops. We handle everything from email and DNS management to SSL certification, CDN hosting, and much more. This lets us give you more time to focus on what's really important: building your app and making an impact with your creation. - - # 👋 Welcome to PocketHost ## Overview diff --git a/docs/overview.md b/docs/overview.md new file mode 100644 index 00000000..f02d41b2 --- /dev/null +++ b/docs/overview.md @@ -0,0 +1,15 @@ +--- +title: Developing PocketHost +category: development +description: Learn how to develop PocketHost, a powerful, open-source, nodejs + application that enables swift multi-tenant platform functions. Ideal for + public or private use, PocketHost is beginner-friendly with plenty of + front-end modifications, while offering complex backend setup opportunities + for seasoned developers. +--- + +This monorepo contains the entire open source stack that powers pockethost.io. You can use it to run your own private or public multitenant platform. + +PocketHost is a pure nodejs application. It used to run in a Docker container, but it was eventually decided that a pure node stack was a better option. + +If you are interested in contributing, modifying the frontend is definitely easiest. Modifying the backend takes some extra setup. diff --git a/packages/www/content/docs/development/production.md b/docs/production.md similarity index 57% rename from packages/www/content/docs/development/production.md rename to docs/production.md index 6e358fb0..045281cb 100644 --- a/packages/www/content/docs/development/production.md +++ b/docs/production.md @@ -5,22 +5,8 @@ description: Learn how to deploy your PocketHost project for production. This guide covers building, refreshing Certbot, running tests, as well as updating and maintaining PocketBase's max semver. Dive in and get your applications running smoothly in no time. - --- -# Overview - -Deploying your PocketHost project for production may seem daunting at first, especially when your focus is primarily on code creation. But fear not, this guide will get you through the necessary steps to streamline your deployment process. - -Begin by setting up your project. Use `git clone git@github.com:benallfree/pockethost.git` command, followed by `cd pockethost` to enter the directory. After you have initiated your project, you need to build it, and for this, you'll leverage `scripts/build.sh`. - -Next, take a moment to refresh Certbot with `./scripts/certbot-refresh.sh`. This will help ensure your SSL certs are always up-to-date, with `fullchain.pem` and `privkey.key` keys in the `docker/mount/nginx/ssl`. - -Then, you're ready to run the project. Launch your project using `sudo scripts/pm2.sh` and follow up with `sudo pm2 dash` to access the dashboard. At this point, navigate to `https://pockethost.io` to test the output. - -Finally, update the max PocketBase semver to limit or lock the PocketBase versions available. All you need is to tweak the `DAEMON_PB_SEMVER` variable in `.env`. And there you have it, your PocketHost project is ready to go live! - - ## Summary - `sudo crontab -e` diff --git a/docs/readme.md b/docs/readme.md new file mode 100644 index 00000000..5709c455 --- /dev/null +++ b/docs/readme.md @@ -0,0 +1,38 @@ +# PocketHost Development + +PocketHost is designed to run full stack on your local development machine. + +## Getting started + +```bash +git clone git@github.com:benallfree/pockethost.git +cd pockethost +yarn +yarn dev:www # Marketing site only, talks to pockethost.io +yarn dev:dashboard # Dashboard site only, talks to pockethost.io +yarn dev # Everything, talks to pockethost.lvh.me +``` + +## Just the Frontend + +PocketHost has two frontends. Both static site generated (SSG): + +1. The marketing/blog site (11ty) +2. The dashboard (sveltekit) + +If you're only doing frontend development, it is much easier to point these at the production PocketHost backend instead of trying to run a local backend. + +## All Our Base + +You can run the complete PocketHost stack locally. A simple `yarn dev` will fire up: + +- `https://pockethost.lvh.me` - Marketing/blog +- `https://app.pockethost.lvh.me` - Dashboard (app) +- `https://mothership.pockethost.lvh.me` - Mothership backend +- `https://*.sfo-1.pockethost.lvh.me` - Instance worker + +**Prerequisites** + +```bash +brew install caddy +``` diff --git a/packages/www/content/docs/development/rpc.md b/docs/rpc.md similarity index 53% rename from packages/www/content/docs/development/rpc.md rename to docs/rpc.md index e92e2f10..0eebd5d3 100644 --- a/packages/www/content/docs/development/rpc.md +++ b/docs/rpc.md @@ -6,18 +6,8 @@ description: Learn how to secure data modifications with PocketHost by creating new RPC calls, adjust the schema, and handle commands. Currently, only asynchronous executions are supported, with returns from RPC calls unavailable. Ideal for nodejs programmers seeking robust security measures. - --- -# Overview - -We all are quite aware of the security challenge one could face allowing direct modification of record by the frontend PocketBase client. That's where Remote Procedure Calls (RPCs) in PocketHost swing into action, coming to the rescue to ensure the vulnerable frontiers are secure. It gives you an opportunity to deal with mutable data safely by sending frontend RPC requests to the backend to process securely. The advantage of this? You're catering to imperfections in PocketBase admin security rules, and handling record update scenarios involving transactions, data validation, or specific condition requirements. - -So, how do we add an RPC call to your PocketHost? It's simple - from your command line, execute `npx hygen rpc new `, which effectively prepares the necessary files for your RPC call. Of course, you may need to tune the schema in `./packages/common/src/schema/Rpc/.ts` to match your specifications. Follow it up by adjusting `./packages/daemon/services/RpcService/commands.ts` to receive the RPC command. - -Now let's talk about the RPC results. Currently, you must be aware that we don't support RPC results, as they basically operate on an asynchronous basis. Essentially, you have managed to enhance your backend security layer by adding the robust RPC feature to your PocketHost. - - For security, PocketHost does not allow modification of records by the frontend PocketBase client. Instead, the frontend must send an RPC request which the backend will securely process. This allows for many security vulnerabilities to be addressed which PocketBase admin security rules cannot. In particular, PocketBase admin security rules fall short in these scenarios: - When the incoming data cannot be validated declaratively diff --git a/packages/www/_includes/components/header.njk b/packages/www/_includes/components/header.njk index bcec6b76..cf89bc8c 100644 --- a/packages/www/_includes/components/header.njk +++ b/packages/www/_includes/components/header.njk @@ -17,7 +17,7 @@ @@ -31,7 +31,7 @@ diff --git a/packages/www/_includes/layouts/docs.njk b/packages/www/_includes/layouts/docs.njk index 031b2140..44daf547 100644 --- a/packages/www/_includes/layouts/docs.njk +++ b/packages/www/_includes/layouts/docs.njk @@ -56,11 +56,7 @@ layout: layouts/base.njk diff --git a/packages/www/content/docs/development/frontend.md b/packages/www/content/docs/development/frontend.md deleted file mode 100644 index 37a14e02..00000000 --- a/packages/www/content/docs/development/frontend.md +++ /dev/null @@ -1,30 +0,0 @@ ---- -title: Just the frontend (Svelte) -category: development -description: Learn how to focus purely on UI and frontend development using - Svelte with pockethost.io. Simply clone our repository, install the needed - packages and start a local build to connect directly to the `pockethost.io` - mothership for seamless database tasks. No backend setup, all fun and - function. - ---- - -# Overview - -Relishing the thrill of frontend development without diverting focus towards backend areas is a compelling prospect. To truly immerse yourself in Svelte, `pockethost.io` makes it convenient to concentrate solely on UI and frontend tasks. An easy way to initiate this is by cloning the `pockethost.io` repository. This makes an effortless bridge for your local build to communicate with our resourceful mothership. - -A quick tour through the following commands eradicates any need for backend setup. Begin by cloning the repository with `git clone git@github.com:benallfree/pockethost.git`. Following that, navigate to the newly cloned directory using `cd pockethost`. The command `yarn` will install all required packages, then `yarn dev:www` starts a local build. - -That's the magic. You're now in the throes of a seamless frontend undertaking. The `pockethost.io` mothership oversees your Svelte build ensuring it has resources to handle all database-related exercises. By deploying this approach, you get to relish the strengths offered by Svelte, while we shoulder the backend burden. Enjoy the freedom of crafting your UI innovations without unnecessary backend tangles. - - -Just want to work with the UI and frontend? - -```bash -git clone git@github.com:benallfree/pockethost.git -cd pockethost -yarn -yarn dev:www -``` - -That's it. You're in business. Your local Svelte build will talk to the `pockethost.io` mothership and connect to that for all database-related tasks. diff --git a/packages/www/content/docs/development/overview.md b/packages/www/content/docs/development/overview.md deleted file mode 100644 index 947ce8e0..00000000 --- a/packages/www/content/docs/development/overview.md +++ /dev/null @@ -1,23 +0,0 @@ ---- -title: Developing PocketHost -category: development -description: Learn how to develop PocketHost, a powerful, open-source, nodejs - application that enables swift multi-tenant platform functions. Ideal for - public or private use, PocketHost is beginner-friendly with plenty of - front-end modifications, while offering complex backend setup opportunities - for seasoned developers. ---- - -# Overview - -Are you hungry for some development magic? We've got something exciting on the table- PocketHost, a robust open-source Node.js app that fuels pockethost.io. Harness the power of PocketHost to run your very own private or public multi-tenant platform. It's a feast for developers at all levels, chock-full of engaging front-end modifications for beginners and intricate backend setup options for the experienced. - -PocketHost runs purely on Node.js, carrying forward our legacy of keeping things straightforward and efficient. Previously, we operated within a Docker container, but at PocketHost, we're all about elevation and evolution. We realized the potential to boost our efficiency standard and seized the chance, shifting to a pure Node.js stack. - -If you're eager to bring new ideas to the table or to get your hands dirty tweaking existing ones, you're most welcome here! With PocketHost, you can easily modify the frontend, making it an excellent starting point. If you're experienced and up for a challenge, delve into modifying the backend. Although it requires extra setup, it's a journey certain to enrich your developer skills. At PocketHost, we believe in growing together, learning together, and creating together. And what's better? You get to do all this in your way! - -This monorepo contains the entire open source stack that powers pockethost.io. You can use it to run your own private or public multitenant platform. - -PocketHost is a pure nodejs application. It used to run in a Docker container, but it was eventually decided that a pure node stack was a better option. - -If you are interested in contributing, modifying the frontend is definitely easiest. Modifying the backend takes some extra setup. diff --git a/packages/www/content/docs/index.njk b/packages/www/content/docs/index.njk index bb85f43d..2146f404 100644 --- a/packages/www/content/docs/index.njk +++ b/packages/www/content/docs/index.njk @@ -1,3 +1,3 @@ \ No newline at end of file diff --git a/packages/www/content/docs/overview/faq.md b/packages/www/content/docs/overview/faq.md index 068b29e8..4f9bdc34 100644 --- a/packages/www/content/docs/overview/faq.md +++ b/packages/www/content/docs/overview/faq.md @@ -1,6 +1,6 @@ --- title: FAQ -category: getting-started +category: overview description: Explore frequently asked questions about pockethost.io, a nonprofit, one-click hosting and deployment service for PocketBase projects. Discover how PocketHost ensures stability, security, and offers a free tier, @@ -8,14 +8,6 @@ description: Explore frequently asked questions about pockethost.io, a restrictions and more for both hobbyists and --- -# Overview - -pockethost.io is a community-powered, non-profit hosting service for the PocketBase projects. Headed by seasoned programmer benallfree, it provides one-click hosting and deployment, allowing you to harness the power of PocketBase without the need to self-host or grapple with server setups. Furthermore, PocketHost provides a plethora of additional services such as backup, restore, SFTP access, static hosting, and much more, making it a useful tool for quick deployment of small to mid-scale PocketBase projects. - -PocketHost employs the tested and stressed infrastructure daily ensuring stability and security for your data. You can back up and download your data at any time via SFTP and SSH with RSA-2048 encryption boosts security. PocketHost, developed with an understanding of the sovereignty principle of PocketBase, extends support to import data, facilitating easy migration process to and from the platform. - -Creating as many PocketBase instances as needed is at the heart of PocketHost’s mission. The service caters to both hobbyists and professional developers; hence a free tier has been offered. This free tier grants you unlimited bandwidth, storage, and 100 CPU minutes each month allowing flexibility for users. Moreover, they're considering the inception of a paid-plan for power users which will come with added perks and unlimited resources. An interactive discussion area is maintained for further queries and to stay updated with the latest developments. - ## About ### What is pockethost.io? diff --git a/packages/www/content/docs/overview/help.md b/packages/www/content/docs/overview/help.md index 5d4cea50..0d8282e0 100644 --- a/packages/www/content/docs/overview/help.md +++ b/packages/www/content/docs/overview/help.md @@ -1,25 +1,19 @@ --- title: Getting Help -category: getting-started +category: overview description: Learn how to get assistance with PocketHost, your one-click deployment platform. Engage real-time in the PocketHost Discussions forum or for more confidential matters, send a direct email to the developer. Get started and harness the power of PocketHost now. - --- -# Overview - -Got queries on how to best use PocketHost for your projects? Let's clear them up, champ! The first stop is our buzzing [PocketHost Discussions](https://github.com/benallfree/pockethost/discussions) forum over at GitHub. It's the ideal platform for you to fire away your questions, sing praises, suggest features or even rant a little. We just ask that you take a stab at initiating a discussion before raising GitHub issues – let's keep things organized! - -When you want to get into more confidential subjects or need specific assistance, feel free to drop an email to ben@pockethost.io. Also, don't forget, we have an active Discord channel - another great place to get real-time responses from our community. It's all about helping each other out to make our web development journeys more enriching and efficient. - -So strap on your proverbial white belt and jump into the fray. Remember, when it comes to PocketHost, the only dumb question is the one you didn't ask. Use these resources to your advantage and get ready to grapple with the limitless potential of PocketHost. Now, who's ready for a roll on the digital canvas? +## Discord +The fastest and easiest way to get help is to head over to the [Discord server](https://discord.gg/nVTxCMEcGT). There lots of friendly people there who are in the same boat and willing to help. ## Discussion Forum -The fastest and easiest way to get help is to head over to the [PocketHost Discussions](https://github.com/benallfree/pockethost/discussions) forum. Please do not create GitHub issues without initiating a discussion first. +Another great option is our [PocketHost Discussions](https://github.com/benallfree/pockethost/discussions) forum, though we may be phasing this out in favor of the much more popular Discord option. ## Email diff --git a/packages/www/content/docs/overview/introduction.md b/packages/www/content/docs/overview/introduction.md new file mode 100644 index 00000000..1024b19e --- /dev/null +++ b/packages/www/content/docs/overview/introduction.md @@ -0,0 +1,50 @@ +--- +title: Introduction +category: overview +description: PocketHost, a powerful cloud hosting platform for PocketBase, + allows you to create unlimited projects quickly and easily. With no backend + setup required, it manages all the Linux/devops tasks, from email and DNS + jargon to SSL management and CDN hosting, so developers can solely focus on + building their apps. +--- + +# 👋 Welcome to PocketHost + +## Overview + +PocketHost hosts your [PocketBase](https://pocketbase.io) projects, so you don't have to. Create a project like you would in Firebase and Supabase and let PocketHost do the rest. + +PocketHost is a cloud hosting platform for PocketBase. You can use it to instantly provision a PocketBase backend for your latest project. Features include: + +- Create unlimited PocketBase projects, each with a custom subdomain +- Each instance runs on a subdomain of `pockethost.io` +- Access your PocketBase instance using the PocketBase JavaScript SDK as easily as `new PocketBase('https://my-project.pockethost.io')` +- Run your instance in an ultra-beefy shared environment + +## Focus on your app + +Get a live PocketBase instance in 10 seconds with no backend setup: + +1. Create an account at pockethost.io +2. Provision your first PocketBase instance +3. Connect from anywhere + +```ts +import PocketBase from 'pocketbase' + +const client = new PocketBase(`https://harvest.pockethost.io`) +``` + +## Batteries Included + +Here's all the Linux/devops stuff that PocketHost does for you: + +- Email and DKIM+SPF and more +- DNS jargon: MX, TXT, CNAME +- SSL cert provisioning and management +- Storage +- Volume mounts +- Could computing or VPS deployment +- CDN and static asset hosting +- Amazon AWS +- Lots more - scaling, firewalls, DDoS defense, user security, log rotation, patches, updates, build tools, CPU architectures, multitenancy, on and on diff --git a/packages/www/content/docs/overview/roadmap.md b/packages/www/content/docs/overview/roadmap.md index 10c43238..41e6b8ba 100644 --- a/packages/www/content/docs/overview/roadmap.md +++ b/packages/www/content/docs/overview/roadmap.md @@ -1,6 +1,6 @@ --- title: Roadmap -category: getting-started +category: overview description: Explore the PocketHost's roadmap and delve into the planned enhancements for our cloud-based hosting and deployment platform. From handling project instances and account management to CLI and backup features, @@ -8,21 +8,13 @@ description: Explore the PocketHost's roadmap and delve into the planned experience with pockethost.io. --- -# Overview +# The new way: Feature Hub -Our main goal at PocketHost is ensuring that your projects are up and running without the unnecessary backend hassle, and to continuously refine this process. We strive to help you focus on what you love - creating - while we handle the nitty-gritty. Our roadmap includes enhancements across a variety of features, which we're excited to share. +Come join the [Feature Hub](https://discord.gg/FUVakVzknS) on our Discord server. There, you can see and discuss all kinds of features and ideas. -Instance and Account Management features are set for a significant revamp. We're working on allowing you to power instances on and off, place them into maintenance mode, restart them, and even delete them. Account management will benefit from the ability to permanently delete an account or change the email address affiliated with it. +# The old way -A big addition is a comprehensive Command Line Interface (CLI) feature for improved interaction with the platform. Enhancements include the ability to download and restore DB backups locally, deployment of static assets, and initialization of a new project, among others. - -Looking towards the future, there are plenty of ideas buzzing around. From developing detailed video tutorials, mitigating storage partitioning, to integrating secure mail API credentials for your projects, we’re all about constantly growing and improving. And remember, we encourage your input along the way – it helps make PocketHost better! Your creations reflect you, and we're here to ensure they reach the world beautifully. - -This document attempts to outline all known/planned issues. - -Cleanup effort: In some cases, if a ticket has already been created, it is linked. The ticket will remain closed until active work begins. This better reflects the health of the repository because open issues creates the appearance of instability or lack of attention. - -Ideas, in no particular order... +Here is a HISTORICAL reference of previous ideas. - [Turn instances on and off](https://github.com/benallfree/pockethost/discussions/204) - Allow instance to be placed into maintenance mode diff --git a/packages/www/content/docs/releases/next.md b/packages/www/content/docs/releases/next.md deleted file mode 100644 index f873f6e8..00000000 --- a/packages/www/content/docs/releases/next.md +++ /dev/null @@ -1,20 +0,0 @@ ---- -title: Changes in `master` not yet released -description: Uncover the latest updates and changes made to the 'master' that - are yet not released. Stay tuned for a deep dive into these advancements to - comprehend how they can potentially enhance and revolutionize your experience - with PocketHost's features and functionalities. - ---- - -# Overview - -Stepping into the technical realm of mid-development updates, we aim to provide you with an insider's perspective on the alterations made to the `master` that haven't yet seen the light of the day in a release. Since it's still in the refining process, you can perceive this as a backstage pass that brings the upcoming modifications to PocketHost's functionalities into the spotlight. - -Fresh off the coder's console, these modifications promise considerable potential to significantly upgrade your PocketHost experience. This includes enhancements across multiple aspects - adjustments that boost performance, augment security, and even some novel attributes that could transform how your projects are managed by the platform in a profoundly impactful way. - -Delving a bit deeper, you'll find that these changes are pioneered by the philosophy of enhancing not just the software's efficiency, but also your interactive experience. As we simplify complex elements and amplify convenience factors, the prime focus pivots to you, the user - ensuring that you find ease and efficacy when creating and managing your projects using PocketHost. - -In conclusion, the `master` holds a hidden trove of improvements designed to turbocharge your projects to previously unreachable heights. So, stay tuned, adopt a posture of learning and anticipation; these advancements are shaping up to redefine your journey with PocketHost. - - diff --git a/packages/www/content/docs/usage/accessing-instance.md b/packages/www/content/docs/usage/accessing-instance.md index ffd710df..403c468c 100644 --- a/packages/www/content/docs/usage/accessing-instance.md +++ b/packages/www/content/docs/usage/accessing-instance.md @@ -8,14 +8,6 @@ description: Learn how to access your PocketBase instances managed by anticipated support for custom domains. --- -# Overview - -Let's dive into the crux of uncovering the inner workings of how to access your pervasive PocketBase instances, managed prudently by PocketHost. Crucial for running your avant-garde projects such as web games, these instances are the backbone of your application's backend. They can be approached via two easy gateways - you have the choice of using either the uniquely assigned, immutable UUIDs or your personalized, modifiable subdomains. - -Every instance governed by PocketHost is labelled with a UUID that's like its indelible fingerprint. It's like the North Star - steadfast and unwavering no matter where you journey. Yet, as a programmer, you have the flexibility to choose your unique subdomains. Like pet names, these subdomains can be playful, meaningful, esoteric, or all of the above, free for you to change at will for convenient accessibility. - -In the future, for those who truly wish to customize their experience to that extra degree, hang tight. Custom domains are on the horizon, being methodically rigged and tested even as we speak. This is yet another tool in your arsenal to connect with and engage your users, enabling you to continue building the most impressive applications. - Your PocketBase instance managed by PocketHost is accessible in two ways: 1. `.pockethost.io` diff --git a/packages/www/content/docs/usage/backup-and-restore.md b/packages/www/content/docs/usage/backup-and-restore.md index 19575b96..85aa134d 100644 --- a/packages/www/content/docs/usage/backup-and-restore.md +++ b/packages/www/content/docs/usage/backup-and-restore.md @@ -6,20 +6,8 @@ description: Learn how to perform backup and restore operations for your on how to ensure data safety and continuity for your PocketBase instances by backing up and restoring your work efficiently. Empower your projects with robust data management best practices. - --- -# Overview - -In the digital realm, safeguarding data is paramount. Therefore, knowing how to efficiently backup and restore your data is a crucial facet for any developer or enterprise owner. This guide focuses on those working with PocketHost projects, detailing how you can use File Transfer Protocol (FTP) to perform these operations with ease, thereby ensuring the safety and continuity of your PocketBase instances. - -Before delving into the process, it’s important to ascertain the status of your PocketHost instance. Ideally, you’d want it in an idle state, a detail expanded upon in our instances usage document. Having your instance idle optimizes the process and reduces the risk of data conflicts. - -Backing up is the first line of defense against loss of data or unforeseen errors. However, a backup is useless without knowing how to restore it correctly. It's a good practice to regularly test restoring from your backups to ensure they'd work correctly if the need arises. - -Additionally, effective data management isn't only about ensuring the safe storage and retrieval of data. It also involves synchronizing data between different environments or platforms. The guide will provide some insights on how you can automate this process using lftp, based on a brilliant Stack Overflow article we found. - - You can use [FTP](/docs/usage/ftp/) to perform backup and restore operations. ## Before you Begin diff --git a/packages/www/content/docs/usage/create.md b/packages/www/content/docs/usage/create.md index ee15a962..83f78b0a 100644 --- a/packages/www/content/docs/usage/create.md +++ b/packages/www/content/docs/usage/create.md @@ -6,16 +6,6 @@ description: Learn how to create a new PocketBase instance on pockethost.io. A Experience the ease of having a deployment service do all the work for you. --- -# Overview - -You've made it here, which tells me you're ready to plunge into the exciting world of virtually effortless backend deployment, thanks to PocketHost. First off, I want to put emphasis on just how simple and swift this process is. It's almost as easy as installing a NPM package. - -To kick things off, every instance of PocketHost is given its own unique subdomain. To create a new instance, you'll need to navigate to [https://app.pockethost.io/app/new](https://app.pockethost.io/app/new). This brings you to the heart of the action. Here is where you get to choose a unique name for your subdomain, which is the identifier for your PocketBase instance. - -And just like that, you're in the game! Once you've nailed down your subdomain, the rest takes care of itself. Behind the scenes, PocketHost is busy threading all the virtual cables together to bring your distinct backend to life. More importantly, it's quick– almost like creating a new git branch. Awaiting you upon completion is a fresh and ready-to-go PocketBase instance, accessible via your very own, uniquely named subdomain. - -So, in essence, this is backend setup without breaking a sweat, without dealing with Linux administration, Docker containers, Domain management and whatnot. It's letting PocketHost do what it's meant to do. That’s it, you’re ready to connect to your fresh instance from anywhere and start building your application. Now go out there and create something amazing! - Every PocketHost instance runs on a unique subdomain. To create a new instance, head to [https://app.pockethost.io/app/new](https://app.pockethost.io/app/new). You'll need to choose a unique name. diff --git a/packages/www/content/docs/usage/ftp.md b/packages/www/content/docs/usage/ftp.md index bd9e9a3a..f5250ba4 100644 --- a/packages/www/content/docs/usage/ftp.md +++ b/packages/www/content/docs/usage/ftp.md @@ -5,20 +5,8 @@ description: Discover how to access your PocketBase files via Secure FTP (FTPS) on PocketHost. Learn how to navigate through different directories and understand their purposes. Explore our recommended GUI and CLI clients to further enhance the management of your PocketBase project online. - --- -# Overview - -In PocketHost, we believe in providing you with utmost control over your PocketBase instance. That's why we offer you access to all your PocketBase files via Secure FTP (FTPS). Simply head over to [ftp://pockethost.io](ftp://pockethost.io), pop in your pockethost.io account credentials and voila! You're in. - -Upon logging in, you'll find a directory for each instance attached to your account. Within each of these instance directories, several subdirectories exist serving different purposes. The 'pb_data' directory, for instance, is the dedicated space for all PocketBase data. If you need to oversee public files, ensure to check out the 'pb_public' directory. - -For a smoother navigation experience, we recommend a couple of Powerful FTP clients. FileZilla shines as a comprehensive GUI frontend for all platforms. For terminal lovers, widely known command-line tools such as 'ftp', 'wget', or 'lftp' will serve perfectly. Remember, the right tool can boost your ability to manage your PocketBase project online promptly and efficiently. - -In PocketHost, you can be sure that we've taken that Linux administration load off your shoulders so that you can hone in on what truly matters - your code. - - PocketHost allows you to access all your PocketBase files via Secure FTP (FTPS). ## Accessing via FTP diff --git a/packages/www/content/docs/usage/hooks.md b/packages/www/content/docs/usage/hooks.md index ab1fb557..cdbe5ff9 100644 --- a/packages/www/content/docs/usage/hooks.md +++ b/packages/www/content/docs/usage/hooks.md @@ -6,18 +6,8 @@ description: Learn how to use PocketBase Hooks on PocketHost to write custom creating HTTP routes, updating/creating records, or running server actions upon user registration. It's an essential guide for nodejs developers looking to maximize PocketHost's potential. - --- -# Overview - -Currently, we're diving into the wonders of PocketBase Hooks on PocketHost. As a seasoned Node.js developer, you have the power to create dynamic server-side functionalities with minimal fuss. PocketBase Hooks let you write plain JavaScript code, incorporated into your PocketHost deployment, to create custom HTTP routes, update and create records, or even perform server actions when a user registers. - -This is done within the `pb_hooks` directory, where every instance on PocketHost is mounted. We commonly see `*.pb.js` files placed in this directory, automatically executed once loaded into PocketBase. Some caveats to keep in mind - alterations in your `pb_hooks` directory will cause your PocketHost instance to restart and automatically escalate your changes. - -If you're a fan of practical learning, take a look at some sample codes like an `onAfterBootstrap` event listener, registering new HTTP routes, creating and updating records, and even paying attention to collection changes. These scripts make it feasible to run server-side tasks, enhancing the versatility of your application. Remember, all these scripts go straight into your `pb_hooks` directory on the PocketHost instance. In a nutshell, this crucial guide increases the potency of PocketHost for any Node.js developers out there. Watch this space for more power-packed PocketHost functionalities. Keep coding, and as always, enjoy the journey! - - The prebuilt PocketBase v0.17+ executable comes with an embedded ES5 JavaScript engine (goja) which enables you to write custom server-side code using plain JavaScript. Every PocketHost instance comes with a `pb_hooks` directory which is mounted into the PocketBase instance at `/pb_hooks`. This directory is where you can place your custom server-side code. diff --git a/packages/www/content/docs/usage/instances/index.md b/packages/www/content/docs/usage/instances/index.md index 61bb68c7..62a3094f 100644 --- a/packages/www/content/docs/usage/instances/index.md +++ b/packages/www/content/docs/usage/instances/index.md @@ -7,22 +7,8 @@ description: Learn how to manage your PocketHost instance with our comprehensive admin access. Master the nuances of using PocketHost and get your PocketBase projects up and running in no time. Essential reading for web & node.js developers. - --- -# Overview - -Dive straight into managing your individual PocketHost instances via an easy-to-use dashboard. Each PocketBase deployment functions on an on-demand basis, launching only upon receiving a web request. Following a period of 5 seconds idle time, instances hibernate for optimal hardware use, with a negligible latency during the "first hit". - -Track usage through PocketHost’s integrated metering system, offering a generous 100 active minutes each month in the free tier. When over this limit, you have the option to purchase extended usage, or to shift your instance to the pool of stand-by instances. - -Control the your PocketBase version deployed with each instance. Default selections utilize the latest major+minor release, locked at instance creation. Upgrades to successive versions can be facilitated by reaching out to support. - -Administer your instance efficiently with the use of instance-specific access, available at the URL https://.pockethost.io/_. This can also be accessed via the PocketHost dashboard. - -Secure your instance with environment variables unveiled at `pocketbase` executable launch. Secrets are accessible as environment variables, available to the `pocketbase` process. Monitor developments through the realtime log – a feature to be launched soon. - - PocketHost provides a simple dashboard where you can manage your instance. ## On-demand Execution diff --git a/packages/www/content/docs/usage/maintenance.md b/packages/www/content/docs/usage/maintenance.md index 64d2d335..d5ca9489 100644 --- a/packages/www/content/docs/usage/maintenance.md +++ b/packages/www/content/docs/usage/maintenance.md @@ -6,22 +6,8 @@ description: Discover how to utilize Maintenance Mode on PocketHost, a vital backups, or emergency shutdowns, Maintenance Mode ensures no unwanted requests are processed, prioritizing control and system health. Learn about manual activation and automatic triggers in this walkthrough. - --- -# Overview - -Step into the shoes of system administrator with PocketHost's Maintenance Mode. This is an essential tool when managing PocketBase instances, providing a reliable lifeline during updates, data backups, or emergency shutdowns. It ensures zero unwanted requests are processed when your PocketBase instance requires focus on control and system health. - -In the unpredictable world of software, instances can sometimes malfunction. When this occurs, PocketHost reacts by automatically activating Maintenance Mode. This action triggers an immediate shutdown of your PocketBase instance, terminating the `pocketbase` process and halting further requests. - -Taking the driver's seat, you can also manually engage Maintenance Mode. During crucial tasks such as version updates, data backup and restoration, and even emergency shutdowns, you have the power to control the flow of requests. - -To manually activate Maintenance Mode, steer yourself to your instance dashboard. Venture to the bottom of the page to find the "Danger Zone". Now, flip the switch to Maintenance Mode. It's as simple as that. With PocketHost in your toolkit, you'll always have total command when it comes to orchestrating your back end infrastructure. - -Don't forget that these topics are further elaborated in their individual chapters - [Upgrading](/docs/usage/upgrading/) and [Backing up and Restoring](/docs/usage/backup-and-restore/). - - Maintenance Mode will prevent your instances `pocketbase` process from running. No requests are processed while your instance is in Maintenance Mode. Maintenance mode can be activated manually, or PocketHost may place your instance in maintenance mode if it detects that the instance is malfunctioning. diff --git a/packages/www/content/docs/usage/rename-instance.md b/packages/www/content/docs/usage/rename-instance.md index dd190f19..62608055 100644 --- a/packages/www/content/docs/usage/rename-instance.md +++ b/packages/www/content/docs/usage/rename-instance.md @@ -7,16 +7,6 @@ description: Learn how to rename your PocketHost instance and its implications. Remember, handle your subdomains with care. --- -# Overview - -Accessing your PocketHost instances through their permalink, like `https://mfsicdp6ia1zpiu.pockethost.io`, is always possible. Yet, for convenience and ease of use, you can utilize a more user-friendly unique subdomain such as `https://harvest.pockethost.io`. - -When it comes to renaming your applicable subdomain, tread cautiously. The renaming process releases your old name back into the pool, open for anyone to claim. This can be critical in case you decide to return to your previous moniker, or if your project has a strong connection to its original subdomain. - -To maintain your digital property rights, be thoughtful about your renaming decisions. Avoid frequent name changes, especially if the subdomain name is associated with any existing functionality or references. Remember, your subdomain represents your project's digital address, making it a vital component of your brand identity. Handle it with care to prevent any undesired eventualities or reclamation by other users. - -In summary, while PocketHost offers the flexibility to rename your instances, it comes with implications. Plan carefully and make sure you won't regret relinquishing your old subdomain before you decide to make a change. Your subdomain is much more than a name; it's a cornerstone of your project’s identity and accessibility. - PocketHost instances can always be accessed by their permalink, such as `https://mfsicdp6ia1zpiu.pockethost.io`, but they can also be accessed by convenient subdomain such as `https://harvest.pockethost.io`. The subdomain name is unique across all of PocketHost, but you can change it. When you change it, you relinquish the old name and someone else can grab it if they want it. So be careful. diff --git a/packages/www/content/docs/usage/upgrading.md b/packages/www/content/docs/usage/upgrading.md index b41dca27..fb020473 100644 --- a/packages/www/content/docs/usage/upgrading.md +++ b/packages/www/content/docs/usage/upgrading.md @@ -6,22 +6,8 @@ description: Learn how to upgrade your PocketHost instance version quickly and rarer and more substantial updates, our guide makes the process straightforward while prioritizing your project's data safety. Upgrade, but don't compromise. - --- -# Overview - -Unlock the full potential of PocketHost by upgrading your instance version promptly and effortlessly. PocketHost's comprehensive support for all versions of PocketBase grants you the power to optimize your instance with the latest and most capable versions out there. - -To upgrade your instance, take advantage of the Danger Zone in the instance details. Specify the desired PocketBase version using semver format. This upgrade can be automatic for minor updates or manual for more substantial changes. - -Always initiate the upgrade process by backing up your instance for data integrity. In most scenarios, automatic upgrades are advised. Simply change to the new version you want. While specifying a semver range like `~0.16.0`, the system will embrace any upcoming patch release without including major versions. After this step, you can take your instance out of maintenance to make it live. - -In some exceptional cases, resort to manual upgrades. These steps require downloading your database via FTP, performing necessary upgrades according to PocketBase documentation, and re-uploading the database. After exiting maintenance mode, ensure to test your instance. - -Upgrading your PocketHost instance means staying ahead and leveraging the best features it offers. But always emphasize protecting your project's data without compromising utility. - - PocketHost supports all versions of PocketBase. Your instance uses [semver](https://semver.org/) version (`0.16.0`) or semver range (`~0.16.0`) to describe which version of PocketBase to run.