Skip to content

[16.0] Configuration not working with environment variables #503

@RavaszTamas

Description

@RavaszTamas

Module

fs_attachment

Describe the bug

Attachments are not being saved to the S3 storage backend despite the RUNNING_ENV and SERVER_ENV_CONFIG environment variables being set.

To Reproduce

Affected versions:
Odoo 16.0

Steps to reproduce the behavior:

  1. Set the RUNNING_ENV and SERVER_ENV_CONFIG environment variables.
RUNNING_ENV=dev
SERVER_ENV_CONFIG=
[fs_storage.aqela]
protocol=s3
directory_path=partner_files
options={"key": "<key>", "secret": "<secret>", "client_kwargs": {"endpoint_url": "https://my-url.com"}}
use_as_default_for_attachments=True
use_filename_obfuscation=True
model_xmlids=projects.partner_file 
  1. Attempt to upload an attachment.

Expected behavior
Attachments should be saved to the S3 storage backend as configured in the SERVER_ENV_CONFIG.

Additional context

  • OS: Debian GNU/Linux 11 (bullseye)
  • Python version: 3.9.2
  • Docker Compose is used for deployment.
  • The server_environment module is installed and configured.
  • The fs.storage model is set to use S3 with the correct protocol and options.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingstalePR/Issue without recent activity, it'll be soon closed automatically.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions