Skip to content
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

Add paste expiration for file storage configuration #191

Open
C0rn3j opened this issue Dec 28, 2017 · 14 comments
Open

Add paste expiration for file storage configuration #191

C0rn3j opened this issue Dec 28, 2017 · 14 comments
Labels

Comments

@C0rn3j
Copy link
Contributor

C0rn3j commented Dec 28, 2017

staticMaxAge - max age for static assets (86400)

I see this line in README in the settings section, do you call pastes "static assets" and if so, does that mean they expire in a day by default?

Is that after last view or actual death time?

@geekism
Copy link

geekism commented Dec 28, 2017 via email

@seejohnrun
Copy link
Contributor

seejohnrun commented Dec 28, 2017 via email

@C0rn3j
Copy link
Contributor Author

C0rn3j commented Dec 28, 2017

This is the extent of my config.js, I installed hastebin through this PKGBUILD on Arch - https://aur.archlinux.org/packages/haste-server-git/

Looking at the config.js in this repo, looks like I just have to throw the expire property to the storage block, so I did so.

  "storage": {
    "path": "./data","type": "file",
    "expire": 31536000
  },

Could the expire property be added to the README? I see that the different storing methods have a notion about the expire but it is not really described for the regular file storage option

@seejohnrun
Copy link
Contributor

@C0rn3j expire does not work with file storage currently. We don't have a separate store where the expiration would be placed - and currently don't serialize them into the stored file. Could be a great idea for an enhancement if people want similar.

@C0rn3j
Copy link
Contributor Author

C0rn3j commented Dec 28, 2017

expire does not work with file storage currently.

Could that be documented in the README?

We don't have a separate store where the expiration would be placed - and currently don't serialize them into the stored file. Could be a great idea for an enhancement if people want similar.

Would love to be able to set an expiration, whether it's at least max exp. on server side or perhaps even let have a shorter expiration on the client side. (my storage is limited)

For example - PrivateBin has a dropdown menu like this. Not saying that Hastebin should let client be able to set shorter expiration than the max, just throwing it out there as an idea. The clutter this adds to the otherwise very clean interface may not be worth it.

image

@seejohnrun
Copy link
Contributor

@C0rn3j

  • We could add it to the README but I think it's already fairly clear when each storage type describes which options it supports. I'm open to a PR that makes it more clear though
  • Have you considered using non-file storage to support expiration? It's definitely a feature I could add but it may be a bit before I have time and I haven't heard this request before.
  • The client side expiration selection is nice, but I prefer to keep the interface free of distractions like that. Maybe an idea for a fork if you're interested!

@C0rn3j
Copy link
Contributor Author

C0rn3j commented Dec 29, 2017

Have you considered using non-file storage to support expiration?

Yes, and while I could do that, it kinda kills the simplicity of the installation.

It's definitely a feature I could add but it may be a bit before I have time and I haven't heard this request before

I have time, better see it added later than never ^^

We could add it to the README but I think it's already fairly clear when each storage type describes which options it supports.

Am not sure about other people who are new to the project, but I myself was totally confused.

I'll re-title this Issue and see about a README PR.

@C0rn3j C0rn3j changed the title Paste expiration - where to set it? Add paste expiration for file storage configuration Dec 29, 2017
@seejohnrun
Copy link
Contributor

@C0rn3j Thanks - I'll keep following this issue and watch for more upvotes - and eventually get this done!

@github-actions
Copy link

github-actions bot commented Mar 8, 2022

This issue is stale because it has been open for 30 days with no activity.

@github-actions github-actions bot added the stale label Mar 8, 2022
@ririko5834
Copy link

When it will be added?

@ririko5834
Copy link

Btw is the expire working for amazon S3?

@github-actions github-actions bot removed the stale label Mar 13, 2022
@github-actions
Copy link

This issue is stale because it has been open for 30 days with no activity.

@github-actions github-actions bot added the stale label Apr 12, 2022
@github-actions
Copy link

This issue was closed because it has been inactive for 14 days since being marked as stale.

@ririko5834
Copy link

It isnt stale

@deniskaber deniskaber added triage and removed stale labels May 11, 2022
@deniskaber deniskaber reopened this May 11, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

5 participants