Skip to content

Instantly share code, notes, and snippets.

View par4dise's full-sized avatar

Sébastien Paradis par4dise

View GitHub Profile
@par4dise
par4dise / BsonClassMapHelper.cs
Last active February 5, 2020 14:12 — forked from andreabalducci/BsonClassMapHelper.cs
Reset class map for unit testing
using System;
using System.Collections.Generic;
using System.Reflection;
using MongoDB.Bson.Serialization;
namespace Mongo.Gist
{
/// <summary>
/// Class BsonClassMapHelper.
/// </summary>
@par4dise
par4dise / local-mongo-replicaset-with-docker
Created January 6, 2020 11:03 — forked from oleurud/local-mongo-replicaset-with-docker
[Local mongo replicaset with docker] #docker #mongo
# pull the official mongo docker container
docker pull mongo
# create network
docker network create my-mongo-cluster
# create mongos
docker run -d --net my-mongo-cluster -p 27017:27017 --name mongo1 mongo mongod --replSet my-mongo-set --port 27017
docker run -d --net my-mongo-cluster -p 27018:27018 --name mongo2 mongo mongod --replSet my-mongo-set --port 27018
docker run -d --net my-mongo-cluster -p 27019:27019 --name mongo3 mongo mongod --replSet my-mongo-set --port 27019