Skip to content

[BUG] <title>This container runs commands “update-ca-certificates” invalid #459

Closed as not planned

Description

@samfor12

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior

#After connecting to S3 storage, I found that NextCloud cannot access it
#I went to NextCloud's log center

S3Exception
Error executing "PutObject" on "https://haproxy:9000/nextcloud/urn%3Aoid%3A226"; AWS HTTP error: cURL error 60: SSL certificate problem: self-signed certificate (see https://curl.haxx.se/libcurl/c/libcurl-errors.html) for https://haproxy:9000/nextcloud/urn%3Aoid%3A226
Exception thrown: Aws\S3\Exception\S3Exception

#This log clearly tells us that the system did not trust this certificate

Expected Behavior

After these operations are executed and my minio S3 storage is functioning properly, NextCloud will work properly and store the data in the S3 backend

Steps To Reproduce

#1. I will first copy a CA certificate to/usr/share/ca certificates/mozilla/
docker cp CA-cloud.com.crt nextcloud1:/usr/share/ca-certificates/mozilla/
#Entering the interior of the container
docker exec -it nextcloud1 bash
#2. edit /etc/ca-certificates.conf
nano /etc/ca-certificates.conf
#3. Go to the end of the file and add mozilla/CA-cloud.com.crt
#4. RUN update-ca-certificates
update-ca-certificates

#5. not output
#6. But the original NextCloud container has relevant output and will trust this certificate normally
#7. Add S3 storage configuration

vi /home/nextcloud1/appdata/www/nextcloud/config/config.php

  'objectstore' => [
          'class' => '\\OC\\Files\\ObjectStore\\S3',
          'arguments' => [
                  'bucket' => 'nextcloud',
                  'hostname' => 'minio',
                  'key' => 'minioadmin',
                  'secret' => 'minioadmin',
                  'port' => 9000,
                  // required for some non-Amazon S3 implementations
                  'use_path_style' => true,
          ],
],

#8. Once added, you will immediately be unable to access NextCloud

Internal Server Error

The server encountered an internal error and was unable to complete your request.
Please contact the server administrator if this error reappears multiple times, please include the technical details below in your report.
More details can be found in the server log.

#Unless the configuration files stored in S3 are removed
vi /home/nextcloud1/appdata/www/nextcloud/config/config.php

//  'objectstore' => [
//         'class' => '\\OC\\Files\\ObjectStore\\S3',
//          'arguments' => [
//                  'bucket' => 'nextcloud',
//                  'hostname' => 'haproxy',
//                  'key' => 'minioadmin',
//                  'secret' => 'minioadmin',
//                  'port' => 9000,
//                  // required for some non-Amazon S3 implementations
 //                 'use_path_style' => true,
//          ],
//],

#I went to NextCloud's log center

S3Exception
Error executing "PutObject" on "https://haproxy:9000/nextcloud/urn%3Aoid%3A226"; AWS HTTP error: cURL error 60: SSL certificate problem: self-signed certificate (see https://curl.haxx.se/libcurl/c/libcurl-errors.html) for https://haproxy:9000/nextcloud/urn%3Aoid%3A226
Exception thrown: Aws\S3\Exception\S3Exception

#This log clearly tells us that the system did not trust this certificate

Environment

- OS:rocky8
- How docker service was installed:
Use the official yum source provided by Docker to install

CPU architecture

x86-64

Docker creation

docker run -d  --name=nextcloud1 --restart=always   --net minio_to_haproxy_network -p 3958:443 -v /home/nextcloud1/appdata:/config -v /home/nextcloud1/data:/data  linuxserver/nextcloud:latest

Container logs

using keys found in /config/keys
[custom-init] No custom files found, skipping...
[ls.io-init] done.
[migrations] started
[migrations] 01-nginx-site-confs-default: skipped
[migrations] 02-default-location: skipped
[migrations] done
usermod: no changes
───────────────────────────────────────

      ██╗     ███████╗██╗ ██████╗
      ██║     ██╔════╝██║██╔═══██╗
      ██║     ███████╗██║██║   ██║
      ██║     ╚════██║██║██║   ██║
      ███████╗███████║██║╚██████╔╝
      ╚══════╝╚══════╝╚═╝ ╚═════╝

   Brought to you by linuxserver.io
───────────────────────────────────────

To support LSIO projects visit:
https://www.linuxserver.io/donate/

───────────────────────────────────────
GID/UID
───────────────────────────────────────

User UID:    911
User GID:    911
───────────────────────────────────────

using keys found in /config/keys
[custom-init] No custom files found, skipping...
[ls.io-init] done.

Activity

  1. github-actions commented on Jul 22, 2024

    @github-actions

    Thanks for opening your first issue here! Be sure to follow the relevant issue templates, or risk having this issue marked as invalid.

  2. Roxedus commented on Jul 22, 2024

    @Roxedus
    Member

    The paths used are not correct for alpine Linux.
    PHP's curl has its own certstore.

  3. samfor12 commented on Jul 22, 2024

    @samfor12
    Author

    HI ,Roxedus
    I need Alpine Linux to set up the root certificate and commands
    How to enable SMB sharing for external storage on Linux server/nextcloud?
    Thank you for your reply .

  4. j0nnymoe commented on Jul 22, 2024

    @j0nnymoe
    Member

    You install the app within nextcloud.

  5. samfor12 commented on Jul 25, 2024

    @samfor12
    Author

    I have installed software for external storage. But to use SMB, it is required to install SMB support software on the host, but I am not sure what needs to be installed

  6. LinuxServer-CI commented on Aug 24, 2024

    @LinuxServer-CI
    Collaborator

    This issue has been automatically marked as stale because it has not had recent activity. This might be due to missing feedback from OP. It will be closed if no further activity occurs. Thank you for your contributions.

  7. drizuid commented on Oct 4, 2024

    @drizuid
    Member

    unfortunately, this is very much out of scope. many required items were missing from the docker run, improper actions were being taken on the container, and we do not provide support for how to use remote storage, this is covered in nextcloud's documentation. closing this as out of scope.

  8. moved this from Issues to Done in Issue & PR Trackeron Oct 4, 2024
  9. github-actions commented on Nov 4, 2024

    @github-actions

    This issue is locked due to inactivity

  10. locked as resolved and limited conversation to collaborators on Nov 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions