Skip to content

Added AWS_S3_HOST environment variable workaround to user_guide for i… #54279

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

Merged
merged 2 commits into from
Jul 28, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 15 additions & 3 deletions doc/source/user_guide/io.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1718,9 +1718,21 @@ at `fsimpl1`_ for implementations built into ``fsspec`` and `fsimpl2`_
for those not included in the main ``fsspec``
distribution.

You can also pass parameters directly to the backend driver. For example,
if you do *not* have S3 credentials, you can still access public data by
specifying an anonymous connection, such as
You can also pass parameters directly to the backend driver. Since ``fsspec`` does not
utilize the ``AWS_S3_HOST`` environment variable, we can directly define a
dictionary containing the endpoint_url and pass the object into the storage
option parameter:

.. code-block:: python

storage_options = {"client_kwargs": {"endpoint_url": "http://127.0.0.1:5555"}}}
df = pd.read_json("s3://pandas-test/test-1", storage_options=storage_options)

More sample configurations and documentation can be found at `S3Fs documentation
<https://s3fs.readthedocs.io/en/latest/index.html?highlight=host#s3-compatible-storage>`__.

If you do *not* have S3 credentials, you can still access public
data by specifying an anonymous connection, such as

.. versionadded:: 1.2.0

Expand Down