# Persistent disk + Spaces + Upload of data

**URL:** <https://discuss.huggingface.co/t/persistent-disk-spaces-upload-of-data/44955>\
**Category:** Spaces\
**Created:** [June 29, 2023, 1:49pm UTC](https://discuss.huggingface.co/t/persistent-disk-spaces-upload-of-data/44955 "2023-06-29T13:49:24Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![nsthorat-lilac](https://avatars.discourse-cdn.com/v4/letter/n/da6949/32.png) [@nsthorat-lilac](https://discuss.huggingface.co/u/nsthorat-lilac)\
**Post date:** [June 29, 2023, 1:49pm UTC](https://discuss.huggingface.co/t/persistent-disk-spaces-upload-of-data/44955/1 "2023-06-29T13:49:25Z")

</div>

Hi all,

I’m using HF spaces + docker with persistent disk storage, and using the HfApi to upload a folder of large data files:

```auto
hf_api = HfApi()
dataset_path = os.path.join('data', 'datasets', d)
hf_api.upload_folder(
  folder_path=os.path.abspath(dataset_path),
  path_in_repo=dataset_path,
  repo_id=hf_space,
  repo_type='space',)

```

Which seems to get uploaded correctly:  
 ![image](https://us1.discourse-cdn.com/hellohellohello/original/3X/9/4/94b52bc863f0011a194db225a8c6a56e3e55c72a.png)

However when I try to read files from /data once the docker image boots up they don’t seem to exist, using os.listdir I see an empty ‘/data’ dir once the docker image boots up.

Is there something I’m misunderstanding?
