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

fix: allow a wider range of filenames #25

Merged
merged 10 commits into from
Aug 24, 2024
Merged

Conversation

lajp
Copy link
Member

@lajp lajp commented Aug 24, 2024

This PR improves on filename matching in order to e.g. render .jpeg files as parts of the pdf.
Additionally it disallows unsupported filenames entirely, returing an error if encountered.

This includes the current progress of #23 but is to be merged beforehand in order to get the hotter fixes in ASAP

@lajp lajp changed the title fix: allow a fix: allow a wider range of filenames Aug 24, 2024
@lajp lajp marked this pull request as ready for review August 24, 2024 13:07
@lajp lajp requested a review from kahlstrm August 24, 2024 13:09
@lajp
Copy link
Member Author

lajp commented Aug 24, 2024

This requires the addition of the env variable ALLOWED_ORIGINS=http://localhost:3000,https://tietokilta.fi
and the EXPOSE env var is changed to BIND_ADDR=0.0.0.0

Copy link
Contributor

@kahlstrm kahlstrm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, just need to add the default host setting to the Dockerfile, otherwise this will not work without infra changes.

src/error.rs Outdated Show resolved Hide resolved
src/main.rs Show resolved Hide resolved
@lajp lajp merged commit baf1088 into Tietokilta:main Aug 24, 2024
4 checks passed
@lajp lajp deleted the filename-fix branch August 24, 2024 14:28
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

Successfully merging this pull request may close these issues.

2 participants