Skip to content

Commit

Permalink
Fix failing adapter
Browse files Browse the repository at this point in the history
Signed-off-by: Ashish Tiwari <ashishjaitiwari15112000@gmail.com>
  • Loading branch information
Revolyssup committed Feb 17, 2023
1 parent 1d2a953 commit 12e07f3
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,14 @@ var (
instanceID = uuid.NewString()
)

func init() {
// Create the config path if it doesn't exists as the entire adapter
// expects that directory to exists, which may or may not be true
if err := os.MkdirAll(path.Join(config.RootPath(), "bin"), 0750); err != nil {
fmt.Println(err)
os.Exit(1)
}
}
func main() {
log, err := logger.New(serviceName, logger.Options{Format: logger.SyslogLogFormat, DebugLevel: isDebug()})
if err != nil {
Expand Down

0 comments on commit 12e07f3

Please sign in to comment.