mirror of
https://github.com/postmannen/ctrl.git
synced 2024-12-14 12:37:31 +00:00
store log are now written to database folder
This commit is contained in:
parent
a95c36f0c3
commit
bcc5db7c04
1 changed files with 2 additions and 1 deletions
|
@ -536,7 +536,8 @@ func (r *ringBuffer) dbUpdate(db *bolt.DB, bucket string, key string, value []by
|
||||||
// To store a message in the store, send what to store on the
|
// To store a message in the store, send what to store on the
|
||||||
// ringbuffer.permStore channel.
|
// ringbuffer.permStore channel.
|
||||||
func (r *ringBuffer) startPermanentStore(ctx context.Context) {
|
func (r *ringBuffer) startPermanentStore(ctx context.Context) {
|
||||||
const storeFile string = "store.log"
|
|
||||||
|
storeFile := filepath.Join(r.configuration.DatabaseFolder, "store.log")
|
||||||
f, err := os.OpenFile(storeFile, os.O_APPEND|os.O_RDWR|os.O_CREATE, 0600)
|
f, err := os.OpenFile(storeFile, os.O_APPEND|os.O_RDWR|os.O_CREATE, 0600)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Printf("error: startPermanentStore: failed to open file: %v\n", err)
|
log.Printf("error: startPermanentStore: failed to open file: %v\n", err)
|
||||||
|
|
Loading…
Reference in a new issue