-
Notifications
You must be signed in to change notification settings - Fork 0
Getting Started
Rob Landers edited this page Feb 5, 2024
·
1 revision
This is a rather simple guide on how to get started. It is meant to outline the overall process. This is still very alpha software and not recommended for production use.
composer require bottledcode/durable-php
A DI container is required, I recommend php-di
// src/bootstrap.php
require_once __DIR__ . '/../vendor/autoload.php';
return new Container([
DurableClientInterface::class => autowire(DurableClient::class),
EntityClientInterface::class => autowire(EntityClient::class),
OrchestrationClientInterface::class => autowire(OrchestrationClient::class),
]);First, we need a rethinkdb instance and a beanstalkd instance, then we can start the cli
docker run -d --rm -p 11300:11300 ghcr.io/beanstalkd/beanstalkd:latest
docker run --rm -d -p 28015:28015 -p 8080:8080 rethinkdb
# start durable-php
vendor/bin/dphp run --bootstrap src/bootstrap.php