Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issues using s3 with docker setup #809

Open
jwr1 opened this issue Jun 4, 2024 · 3 comments
Open

Issues using s3 with docker setup #809

jwr1 opened this issue Jun 4, 2024 · 3 comments
Labels
bug Something isn't working docker Issues and pull requests related to docker environment more information needed requires more info to solve

Comments

@jwr1
Copy link
Member

jwr1 commented Jun 4, 2024

As explained on the optional-features/s3_storage page, you need to edit the config/packages/oneup_flysystem.yaml file to use the s3 adapter. After doing so, the docker image build command starts to fail on this step: [builder-composer 7/7] RUN composer run-script --no-dev post-install-cmd && chmod +x bin/console && sync. It has errors like The s3 service does not have version and Missing required client configuration options: region: (string). I got around this by filling out the s3 environment variables in the .env.example_docker file (since that's the file that gets copied over in Dockerfile, but obviously, we shouldn't have to do that.

Basically, it's checking that the s3 variables are filled out when it shouldn't; it should check them at runtime instead of build time.

@jwr1 jwr1 added the bug Something isn't working label Jun 4, 2024
@BentiGorlich BentiGorlich added the docker Issues and pull requests related to docker environment label Jun 6, 2024
Copy link
Contributor

This issue is stale because it has been open 50 days with no activity. Remove stale label or comment or this will be closed in 6 days.

@github-actions github-actions bot added the Stale Inactivity for too long label Jul 27, 2024
@jwr1
Copy link
Member Author

jwr1 commented Jul 27, 2024

This is definitely still an issue.

@jwr1 jwr1 removed the Stale Inactivity for too long label Jul 27, 2024
@ghost
Copy link

ghost commented Aug 7, 2024

hmmm, i tried to replicate this and i cant seem to get the docker build to fail just by changing config/packages/oneup_flysystem.yaml. does your config/packages/oneup_flysystem.yaml look like this? and your build command look like this? docker build --no-cache -t mbin -f Dockerfile ..

# Read the documentation: https://github.com/1up-lab/OneupFlysystemBundle
oneup_flysystem:
  adapters:
    default_adapter:
      local:
        location: "%kernel.project_dir%/public/%uploads_dir_name%"

    kbin.s3_adapter:
      awss3v3:
        client: kbin.s3_client
        bucket: "%amazon.s3.bucket%"
        options:
          ACL: public-read
    ## If using an s3 bucket with owner-full-control and no ACL, the following may work:
    ##    options:
    ##      ACL: ''

  filesystems:
    public_uploads_filesystem:
      #adapter: default_adapter
      adapter: kbin.s3_adapter
      alias: League\Flysystem\Filesystem

@ghost ghost added needs feedback Requires a greater consensus to make an informed decision more information needed requires more info to solve and removed needs feedback Requires a greater consensus to make an informed decision labels Aug 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working docker Issues and pull requests related to docker environment more information needed requires more info to solve
Projects
None yet
Development

No branches or pull requests

2 participants