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

Full URL on paste insert #121

Open
GioPan04 opened this issue Feb 16, 2025 · 2 comments
Open

Full URL on paste insert #121

GioPan04 opened this issue Feb 16, 2025 · 2 comments

Comments

@GioPan04
Copy link

When inserting a new paste the url generated to be copied only contains the path of the paste.
It would be better to include the complete url (base url + path).

I have a specific use case where my pastes are generated on a local lan which has a different domain than the public one. Right now when I share a paste the browser includes the local domain when I create a new paste, that is not available on the public internet.

I can make a pull request if you consider this a valid change

@matze
Copy link
Owner

matze commented Feb 16, 2025

This is the same issue as with the QR code. But you cannot solve the issue generally other than threading through some base URL throughout the entire code base as was done until recently because the service itself does not know where it runs and how its setup. Thus, I'd like to keep relative URLs as the base for everything because it keeps everything simple and relocatable. Stupid question: why can't you paste on the public one?

@GioPan04
Copy link
Author

Mhh okay.
I wanted to be the only one allowed to create a paste, so I restricted nginx to allow the / route only to local IPs. To access the local version I use a domain (configured in my local DNS server) that is different from the public one

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

No branches or pull requests

2 participants