Skip to content

Json files are empty #11

@karl007

Description

@karl007

Hi.

I had the problem that the json files after pull stay empty.

I checked everything and debugged the script.

The only thing I could fix ist was to replace the line 123

${CURL_BASE_CMD}${1} | jq '.' > $2

with a direct call of curl:

curl -u "$USERNAME":"$PASSWORD" -Ss "http://$HOSTNAME:$APIPORT/api$1" | jq '.' > $2

Don't know what the reason was, but now with " instead of ' and without ${} and wrap the url with " everything works.

Tried to put everything in the CURL_BASE_CMD var, but no success.

Maybe this helps someone.

Zabbix 3.2
Graylog 3.1
Debian 8.10 (Jessie)
Bash 4.3.30

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