How to store s3 keys in database

Since my files are getting cleared off after every docker deploy/redeploy, I’m left with the option of using s3 bucket to store my files .the issue im having is how to store s3 keys in the database and using the (sign download url) later inorder to display the files to the user later…

I can’t see the option for the $key ,in the put file s3 option, even after using repeats…

How should i do it?

I already explained you why this happens in another topic.

You need to properly setup the files folder, as explained in the topic I linked to.

After days of trials and errors. i found an easy way to insert s3 files into data base…i tried the folder mapping method,i can’t seem to get it to work as i am not much of a technical person
here is my solution

  1. upload file into your assets folder
  2. use s3 putFile to send file to s3 storage(file must be saved as public read)
  3. in core action stap,select set value - the value should be your s3storageurl/name_of_ uploaded_file from the file upload step
  4. in the database ,in the column asset column select set value name from the picker

and done