Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Export action.GTSAction = func(ctx context.Context) error { dbConn, err := bundb.NewBunDBService(ctx) if err != nil { return fmt.Errorf("error creating dbservice: %s", err) } exporter := trans.NewExporter(dbConn) path := viper.GetString(config.Keys.AdminTransPath) if path == "" { return errors.New("no path set") } if err := exporter.ExportMinimal(ctx, path); err != nil { return err } return dbConn.Stop(ctx) }
Export exports info from the database into a file
View Source
var Import action.GTSAction = func(ctx context.Context) error { dbConn, err := bundb.NewBunDBService(ctx) if err != nil { return fmt.Errorf("error creating dbservice: %s", err) } importer := trans.NewImporter(dbConn) path := viper.GetString(config.Keys.AdminTransPath) if path == "" { return errors.New("no path set") } if err := importer.Import(ctx, path); err != nil { return err } return dbConn.Stop(ctx) }
Import imports info from a file into the database
Functions ¶
This section is empty.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.