Skip to content

bitobrian/Pocketspire

Repository files navigation

🚀 Pocketspire - a Pocketbase Container for .NET Aspire 🌟

Easily build and run a Pocketbase Docker Linux container within your .NET Aspire projects.

🎉 Getting Started

This uses a configurable Dockerfile mentioned in the Pocketbase docs.

✅ Prerequisites

  • .NET 9 SDK
  • Container image builder for Dockerfiles

📦 Installation

Pocketspire on nuget.org

Add the NuGet package and then the extension method to your AppHost:

using Pocketspire;

var builder = DistributedApplication.CreateBuilder(args);

var pocketbase = builder.AddPocketbaseContainer("pb");

// ...

Parameters

Superuser credentials are required for initial setup but a link will also generate in the console for use during first-time setup. See the pocketbase docs for more details.

  • name: The name of the instance. Appends to the name like: "pocketbase-{name}".
  • superUserEmail: The email for the super user.
  • superUserPassword: The password for the super user.
  • arm64cpu (optional): Use an ARM64 CPU. Default is false.
  • exposedPort (optional): The port to be exposed. Default is null.
  • pocketbaseVersion (optional): The version of PocketBase to use. Default is "0.24.1".

Find your app in the dashboard!

Dashboard

Grab your setup link from the console (first-time use)!

Setup Link

About

A .NET Aspire container resource for Pocketbase.

Resources

License

Stars

Watchers

Forks

Contributors