Comments (4)
@IrshadMar I think I managed to set it up by adding following lines to my dockerfile
FROM public.ecr.aws/lambda/dotnet:6
RUN yum install -y libXext \
libXrender
RUN curl -SL "https://github.com/rdvojmoc/DinkToPdf/raw/v1.0.8/v0.12.4/64%20bit/libwkhtmltox.so" --output ./libwkhtmltox.so
To use zip deployments you would need to modify your lambda to install libXext and libXrender and add the lib to /var/task or where do you keep your dlls.
It looks like the code after publish is unable to load libwkhtmltox.so located in runtimes folder.
from wkhtmltopdf-dotnet.
This solved it for me
https://www.appsloveworld.com/docker/100/58/unable-to-load-shared-library-libgdiplus-or-one-of-its-dependencies-while-runni
Docker file:
FROM public.ecr.aws/lambda/dotnet:6
WORKDIR /var/task
RUN yum clean all && yum update -y
RUN yum install -y amazon-linux-extras
RUN amazon-linux-extras install epel -y
RUN yum install -y libgdiplus
COPY publish/* /var/task/
CMD [ "" ]
Note: You may have to use the libwkhtmltox.so file using the curl command mentioned by @stysiok in the comment above.
Thanks a lot!
from wkhtmltopdf-dotnet.
Have you been able to sort that issue yourself? I'm trying to also set it up on AWS Lambda, but failing miserably. No matter what dependencies I install I always get an exception back that some of the dependencies are missing.
from wkhtmltopdf-dotnet.
I was unsuccessful in solving this issue even after trying the docker solution mentioned by @stysiok above.
While running the docker build I am getting the below error at yum install
Used the below command.
RUN yum install -y libXext \ libXrender
After deployment I am still getting ---> System.NotSupportedException: Unable to load native library. The platform may be missing native dependencies (libjpeg62, etc). Or the current platform is not supported.
from wkhtmltopdf-dotnet.
Related Issues (20)
- Not reading settings on alpine HOT 2
- HTML tags removed HOT 3
- Reporting a vulnerability HOT 1
- In Linux CentOS 7, there was an error: Unable to load native library. The platform may be missing native dependencies (libjpeg62, etc). Or the current platform is not supported. HOT 3
- Memory overflow HOT 2
- The wkhtmltopdf project that is used, is no longer maintained HOT 3
- Display flex is not working HOT 1
- Unable to load native library - Windows 10/11 HOT 16
- How to directly pass parameters to wkhtmltopdf without using objects HOT 1
- You can only download the pdf once HOT 2
- How can I include CSS like Bootstrap in my HTML so that I can observe the applied styles when generating a PDF? HOT 6
- Unable to load native library on .NET8 HOT 26
- n/a
- GlobalSettings not respected on debian 11 HOT 3
- With Multiple requests fails HOT 12
- Not working on Azure Web App 32 bits HOT 7
- add cover command HOT 2
- PdfTools.GetConversionResult doesn't frees memory HOT 3
- HTML字符串转换为PDF报错System.ExecutionEngineException
- 将HTML字符串转换为PDF文件,抛出异常System.ExecutionEngineException(重复,需要删除) HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from wkhtmltopdf-dotnet.