Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Logs not written to file #41

Open
Open

Description

Hey! Love this project, exactly what I needed. Got it mostly set up now but facing an issue with the jobs.log not getting written to and some strange errors in the logs.

 jq: error (at <stdin>:1): Cannot iterate over null (null)

Docker Compose File

version: "3.7"
services:
 ftp_mount:
 image: ubuntu
 restart: always
 command: "sh -c 'while :; do sleep 1; done'"
 volumes:
 - "/mnt/disks/Unprotected_Data/FTP/reolink:/ftp"
 - "/mnt/disks/ntfs_backup_drive_500gb/BACKUPS_CRONTAB:/backups"
 - "/mnt/user/appdata/:/data:ro"
 - "/mnt/user/docker/:/docker:ro"
 - "${PWD}/scripts:/scripts:Z"
 - "${PWD}/logs:/var/log/crontab:rw"
 crontab:
 build: .
 restart: always
 volumes:
 - "/var/run/docker.sock:/var/run/docker.sock:ro"
 - "${PWD}/config/config.yaml:/opt/crontab/config.yaml:ro"
 - "${PWD}/logs:/var/log/crontab:rw"

config.yaml

purge_camera_files:
 command: echo Purging Camera Files
 comment: Removes camera footage until disk is 95% full
 image: alpine:3.5
 schedule: '@every 24h'
 dockerargs: --rm
 trigger:
 - command: /bin/bash /scripts/purge_files.sh /ftp
 project: crontab
 container: ftp_mount

Container Logs:

root@Tower:/mnt/user/docker/crontab# coml
Attaching to crontab_ftp_mount_1, crontab_crontab_1
crontab_1 | 2021年01月01日T06:09:49.378156977Z jq: error (at <stdin>:1): Cannot iterate over null (null)
crontab_1 | 2021年01月01日T06:09:49.416839397Z jq: error (at <stdin>:1): Cannot iterate over null (null)
crontab_1 | 2021年01月01日T06:09:49.454677066Z jq: error (at <stdin>:1): Cannot iterate over null (null)
crontab_1 | 2021年01月01日T06:09:49.566032634Z jq: error (at <stdin>:1): Cannot iterate over null (null)
crontab_1 | 2021年01月01日T06:09:50.083452378Z ##### crontab generation complete #####
crontab_1 | 2021年01月01日T06:09:50.083854115Z # Removes camera footage until disk is 95% full
crontab_1 | 2021年01月01日T06:09:50.083868869Z */1 * * * * /bin/bash /opt/crontab/jobs/548a081a-c6ec-4db1-b270-82434eda680a.sh
crontab_1 | 2021年01月01日T06:09:50.083920757Z ##### run commands with onstart #####
crontab_1 | 2021年01月01日T06:09:50.083968699Z crond -f -d 6 -c /etc/crontabs
crontab_1 | 2021年01月01日T06:09:50.084371880Z crond: crond (busybox 1.31.1) started, log level 6
crontab_1 | 2021年01月01日T06:10:00.084930783Z crond: USER docker pid 135 cmd /bin/bash /opt/crontab/jobs/548a081a-c6ec-4db1-b270-82434eda680a.sh
crontab_1 | 2021年01月01日T06:10:00.085997105Z Start Cronjob **548a081a-c6ec-4db1-b270-82434eda680a** Removes camera footage until disk is 95% full
crontab_1 | 2021年01月01日T06:10:02.233314641Z Purging Camera Files
crontab_1 | 2021年01月01日T06:10:04.056799272Z Current capacity at 91 %
crontab_1 | 2021年01月01日T06:10:04.072716733Z End Cronjob **548a081a-c6ec-4db1-b270-82434eda680a** Removes camera footage until disk is 95% full

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

        AltStyle によって変換されたページ (->オリジナル) /