+
Skip to content

backup feature does not work as expected #420

@mertcangokgoz

Description

@mertcangokgoz

Hello.

I tried to use the s3 backup method but I encountered many errors.

  1. cannot delete the added s3 backup task.
  2. behaves as if a new backup task is being added when it is updated.
  3. ansible used for s3cmd gives error.(maybe it is related to my server, I don't know, I leave the log below.)
  4. error in file path added to crontab(It says to take /var/lib/roxy-wi/configs/hap_config/haproxy-prod*.conf as file path, but there are dated .conf files in /var/lib/roxy-wi/configs/hap_config/ folder.)

feature request

folder support should be added to the s3 backup area (if it supports bucket-name/folder-name, it would be great if you specify it in the document.)


OS

Distributor ID: Ubuntu
Description:    Ubuntu 22.04.5 LTS
Release:        22.04
Codename:       jammy

error log

[Thu Jul 03 00:37:00.300373 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992]   'class': algorithms.TripleDES,\r
[Thu Jul 03 00:37:00.469189 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] [WARNING]:  * Failed to parse /var/www/haproxy-\r
[Thu Jul 03 00:37:00.469385 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] wi/app/scripts/ansible/inventory/s3_backup-22.json with yaml plugin: We were\r
[Thu Jul 03 00:37:00.469534 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] unable to read either as JSON nor YAML, these are the errors we got from each:\r
[Thu Jul 03 00:37:00.469646 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] JSON: Expecting property name enclosed in double quotes: line 1 column 2 (char\r
[Thu Jul 03 00:37:00.469969 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] 1)  Syntax Error while loading YAML.   did not find expected ',' or '}'  The\r
[Thu Jul 03 00:37:00.470383 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] error appears to be in '/var/www/haproxy-\r
[Thu Jul 03 00:37:00.470861 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] wi/app/scripts/ansible/inventory/s3_backup-22.json': line 1, column 181, but\r
[Thu Jul 03 00:37:00.471401 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] may be elsewhere in the file depending on the exact syntax problem.  The\r
[Thu Jul 03 00:37:00.471933 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] offending line appears to be:   {'server': {'hosts': {'localhost': {'SERVER':\r
[Thu Jul 03 00:37:00.472356 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] 'hetzner-haproxy-cosmos', 'S3_SERVER': 'https://s3.eu-west-1.amazonaws.com/',\r
[Thu Jul 03 00:37:00.472775 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] 'BUCKET': 'production-backup-haproxy', 'SECRET_KEY':\r
[Thu Jul 03 00:37:00.473226 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] '\\'REDACTED"\\'', 'ACCESS_KEY':\r
[Thu Jul 03 00:37:00.473795 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] 'REDACTED', 'TIME': 'daily', 'action': 'add'}}}}\r
[Thu Jul 03 00:37:00.474230 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] ^ here\r
[Thu Jul 03 00:37:00.475102 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] [WARNING]:  * Failed to parse /var/www/haproxy-\r
[Thu Jul 03 00:37:00.475599 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] wi/app/scripts/ansible/inventory/s3_backup-22.json with ini plugin:\r
[Thu Jul 03 00:37:00.475994 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] /var/www/haproxy-wi/app/scripts/ansible/inventory/s3_backup-22.json:1: Error\r
[Thu Jul 03 00:37:00.476118 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] parsing host definition '{'server': {'hosts': {'localhost': {'SERVER':\r
[Thu Jul 03 00:37:00.476329 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] 'hetzner-haproxy-cosmos', 'S3_SERVER': 'https://s3.eu-west-1.amazonaws.com/',\r
[Thu Jul 03 00:37:00.476455 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] 'BUCKET': 'production-backup-haproxy', 'SECRET_KEY':\r
[Thu Jul 03 00:37:00.476655 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] '\\'REDACTED"\\'', 'ACCESS_KEY':\r
[Thu Jul 03 00:37:00.476782 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] 'REDACTED', 'TIME': 'daily', 'action': 'add'}}}}': No closing\r
[Thu Jul 03 00:37:00.476917 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] quotation\r
[Thu Jul 03 00:37:00.477043 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] [WARNING]: Unable to parse /var/www/haproxy-\r
[Thu Jul 03 00:37:00.477153 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] wi/app/scripts/ansible/inventory/s3_backup-22.json as an inventory source\r
[Thu Jul 03 00:37:00.477257 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] [WARNING]: No inventory was parsed, only implicit localhost is available\r
[Thu Jul 03 00:37:00.480790 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] [WARNING]: provided hosts list is empty, only localhost is available. Note that\r
[Thu Jul 03 00:37:00.480923 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] the implicit localhost does not match 'all'\r
[Thu Jul 03 00:37:00.645604 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] \r
[Thu Jul 03 00:37:00.645621 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] PLAY [localhost] ***************************************************************
[Thu Jul 03 00:37:00.645626 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] 
[Thu Jul 03 00:37:00.664826 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] \r
[Thu Jul 03 00:37:00.664840 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] TASK [Install s3cmd] ***********************************************************\r
[Thu Jul 03 00:37:00.664845 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] fatal: [localhost]: FAILED! => {"msg": "The conditional check 'action == \\"add\\"' failed. The error was: error while evaluating conditional (action == \\"add\\"): 'action' is undefined. 'action' is undefined\\n\\nThe error appears to be in '/var/www/haproxy-wi/app/scripts/ansible/roles/s3_backup.yml': line 11, column 9, but may\\nbe elsewhere in the file depending on the exact syntax problem.\\n\\nThe offending line appears to be:\\n\\n    block:\\n      - name: Install s3cmd\\n        ^ here\\n"}
[Thu Jul 03 00:37:00.664852 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] 
[Thu Jul 03 00:37:00.665243 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] \r
[Thu Jul 03 00:37:00.665248 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] PLAY RECAP *********************************************************************\r
[Thu Jul 03 00:37:00.665253 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] localhost                  : ok=0    changed=0    unreachable=0    failed=1    skipped=0    rescued=0    ignored=0   
[Thu Jul 03 00:37:00.665256 2025] [wsgi:error] [pid 80296:tid 140313594746432] [remote 10.0.0.2:32992] 

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      点击 这是indexloc提供的php浏览器服务,不要输入任何密码和下载