bgio-azure-storage
v0.49.0
Published
Azure Storage database connector for boardgame.io
Downloads
13
Readme
bgio-azure-storage
Azure Storage database connector for boardgame.io
This package provides a database connector that allows you to use an Azure Storage account to store boardgame.io metadata and game state.
Installation
npm install --save bgio-azure-storage
Usage
const { AzureStorage } = require('bgio-azure-storage');
const { BlobServiceClient } = require('@azure/storage-blob');
const { Server } = require('boardgame.io/server');
const { MyGame } = require('./game');
const database = new AzureStorage({
client: BlobServiceClient.fromConnectionString('enter your connection string here'),
container: 'boardgameio',
});
const server = Server({
games: [MyGame],
db: database,
});
server.run(8000);