[GH-ISSUE #121] Full URL on paste insert #76

Open
opened 2026-02-27 10:15:37 +03:00 by kerem · 2 comments
Owner

Originally created by @GioPan04 on GitHub (Feb 16, 2025).
Original GitHub issue: https://github.com/matze/wastebin/issues/121

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

Originally created by @GioPan04 on GitHub (Feb 16, 2025). Original GitHub issue: https://github.com/matze/wastebin/issues/121 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
Author
Owner

@matze commented on GitHub (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?

<!-- gh-comment-id:2661467707 --> @matze commented on GitHub (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?
Author
Owner

@GioPan04 commented on GitHub (Feb 16, 2025):

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

<!-- gh-comment-id:2661582750 --> @GioPan04 commented on GitHub (Feb 16, 2025): 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 in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/wastebin-matze#76
No description provided.