Skip to content

Conversation

@mheers
Copy link

@mheers mheers commented Aug 8, 2024

… custom certificate

Right now the SSL_CERT_FILE needed by the python script is not created in /run/etc/wal-e.d/env so envdir "/run/etc/wal-e.d/env" wal-e backup-push fails with

Traceback (most recent call last):
  File "src/gevent/greenlet.py", line 906, in gevent._gevent_cgreenlet.Greenlet.run
  File "/usr/local/lib/python3.10/dist-packages/wal_e/worker/upload.py", line 52, in __call__
    kib_per_second = do_lzop_put(self.creds, url, segment.path,
  File "/usr/local/lib/python3.10/dist-packages/wal_e/worker/worker_util.py", line 40, in do_lzop_put
    k = blobstore.uri_put_file(creds, url, tf)
  File "/usr/local/lib/python3.10/dist-packages/wal_e/blobstore/s3/s3_util.py", line 58, in uri_put_file
    k.set_contents_from_file(fp, encrypt_key=(not disable_encryption))
  File "/usr/lib/python3/dist-packages/boto/s3/key.py", line 1307, in set_contents_from_file
    self.send_file(fp, headers=headers, cb=cb, num_cb=num_cb,
  File "/usr/lib/python3/dist-packages/boto/s3/key.py", line 760, in send_file
    self._send_file_internal(fp, headers=headers, cb=cb, num_cb=num_cb,
  File "/usr/lib/python3/dist-packages/boto/s3/key.py", line 957, in _send_file_internal
    resp = self.bucket.connection.make_request(
  File "/usr/lib/python3/dist-packages/boto/s3/connection.py", line 667, in make_request
    return super(S3Connection, self).make_request(
  File "/usr/lib/python3/dist-packages/boto/connection.py", line 1070, in make_request
    return self._mexe(http_request, sender, override_num_retries,
  File "/usr/lib/python3/dist-packages/boto/connection.py", line 1030, in _mexe
    raise ex
  File "/usr/lib/python3/dist-packages/boto/connection.py", line 939, in _mexe
    response = sender(connection, request.method, request.path,
  File "/usr/lib/python3/dist-packages/boto/s3/key.py", line 803, in sender
    http_conn.endheaders()
  File "/usr/lib/python3.10/http/client.py", line 1278, in endheaders
    self._send_output(message_body, encode_chunked=encode_chunked)
  File "/usr/lib/python3.10/http/client.py", line 1038, in _send_output
    self.send(msg)
  File "/usr/lib/python3.10/http/client.py", line 976, in send
    self.connect()
  File "/usr/lib/python3.10/http/client.py", line 1455, in connect
    self.sock = self._context.wrap_socket(self.sock,
  File "/usr/lib/python3/dist-packages/gevent/_ssl3.py", line 114, in wrap_socket
    return self.sslsocket_class(
  File "/usr/lib/python3/dist-packages/gevent/_ssl3.py", line 312, in __init__
    raise x
  File "/usr/lib/python3/dist-packages/gevent/_ssl3.py", line 308, in __init__
    self.do_handshake()
  File "/usr/lib/python3/dist-packages/gevent/_ssl3.py", line 667, in do_handshake
    self._sslobj.do_handshake()
ssl.SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1007)
2024-08-08T11:54:39Z <Greenlet at 0x7fb529041000: <wal_e.worker.upload.WalUploader object at 0x7fb5291d1ff0>(<wal_e.worker.pg.wal_transfer.WalSegment object at)> failed with SSLCertVerificationError

FYI: Setting WALG_S3_CA_CERT_FILE does not have any effect here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant