Skip to content

Commit

Permalink
Get user group dynamically
Browse files Browse the repository at this point in the history
  • Loading branch information
CWSpear committed Nov 10, 2016
1 parent 1e28d5a commit f0ad727
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,16 @@ package main

import (
"fmt"
"os/user"

"github.com/docker/go-plugins-helpers/volume"
)

func main() {
driver := newLocalPersistDriver()

u, _ := user.Current()

handler := volume.NewHandler(driver)
fmt.Println(handler.ServeUnix("docker", driver.name))
fmt.Println(handler.ServeUnix(u.Name, driver.name))
}

0 comments on commit f0ad727

Please sign in to comment.