mirror of
				https://github.com/optim-enterprises-bv/vault.git
				synced 2025-10-31 18:48:08 +00:00 
			
		
		
		
	 a4c652cbb3
			
		
	
	a4c652cbb3
	
	
	
		
			
			* WIP on mongodb plugin * Add mongodb plugin * Add tests * Update mongodb.CreateUser() comment * Update docs * Add missing docs * Fix mongodb docs * Minor comment and test updates * Fix imports * Fix dockertest import * Set c.Initialized at the end, check for empty CreationStmts first on CreateUser * Remove Initialized check on Connection() * Add back Initialized check * Update docs * Move connProducer and credsProducer into pkg for mongodb and cassandra * Chage parseMongoURL to be a private func * Default to admin if no db is provided in creation_statements * Update comments and docs
		
			
				
	
	
		
			22 lines
		
	
	
		
			364 B
		
	
	
	
		
			Go
		
	
	
	
	
	
			
		
		
	
	
			22 lines
		
	
	
		
			364 B
		
	
	
	
		
			Go
		
	
	
	
	
	
| package main
 | |
| 
 | |
| import (
 | |
| 	"log"
 | |
| 	"os"
 | |
| 
 | |
| 	"github.com/hashicorp/vault/helper/pluginutil"
 | |
| 	"github.com/hashicorp/vault/plugins/database/mongodb"
 | |
| )
 | |
| 
 | |
| func main() {
 | |
| 	apiClientMeta := &pluginutil.APIClientMeta{}
 | |
| 	flags := apiClientMeta.FlagSet()
 | |
| 	flags.Parse(os.Args)
 | |
| 
 | |
| 	err := mongodb.Run(apiClientMeta.GetTLSConfig())
 | |
| 	if err != nil {
 | |
| 		log.Println(err)
 | |
| 		os.Exit(1)
 | |
| 	}
 | |
| }
 |