R
Railway16mo ago
LuaN

how can i install puppeteer to my application in Railway?

I'm running a Discord bot that needs to use puppeeter to generate images, and puppeeter needs to install some dependencies on the machine in order to work, is there any way to make this run on Railway?
29 Replies
Percy
Percy16mo ago
Project ID: N/A
LuaN
LuaN16mo ago
N/A
Brody
Brody16mo ago
do you have "puppeteer" in your package.json
LuaN
LuaN16mo ago
yes
Brody
Brody16mo ago
not the core version?
LuaN
LuaN16mo ago
LuaN
LuaN16mo ago
i have this error I believe this error occurs as I need to install some dependencies using apt-get as the documentation shows
Brody
Brody16mo ago
show me the documentation please
LuaN
LuaN16mo ago
GitHub
puppeteer/docs/troubleshooting.md at main · puppeteer/puppeteer
Node.js API for Chrome . Contribute to puppeteer/puppeteer development by creating an account on GitHub.
Brody
Brody16mo ago
are you deploying with nixpacks or a dockerfile
LuaN
LuaN16mo ago
nixpacks
Brody
Brody16mo ago
add this as a nixpacks.toml file to your project
[phases.setup]
aptPkgs = ["...", "libglib2.0-dev"]
[phases.setup]
aptPkgs = ["...", "libglib2.0-dev"]
LuaN
LuaN16mo ago
I solved it using Dockerfile to install all dependencies, thanks!
Brody
Brody16mo ago
damn and I already had the next thing to try already prepared
milo
milo16mo ago
btw @influente id recommend using browserless there is a template for it
⛧ ayami ʸᵒᵘⁿᵍᵇᵒʸ⛧
how it works? im having the same problem
milo
milo13mo ago
gooogle browserless
⛧ ayami ʸᵒᵘⁿᵍᵇᵒʸ⛧
is this right? https://railway.app/template/browserless how can i use it it created a repo on my github i hope u can help me pls 🙏 i can pay u for help if its necesary pls I need this to work 🙏
Brody
Brody13mo ago
may i ask you what you are wanting to use puppeteer / browserless for?
⛧ ayami ʸᵒᵘⁿᵍᵇᵒʸ⛧
Im trying to learn how to use it but it dont works on railway
Brody
Brody13mo ago
but what are you going to use it for specifically
⛧ ayami ʸᵒᵘⁿᵍᵇᵒʸ⛧
I think that puppeteer is used to extract data from websites Im watching tutorial to learn how to use it Im learning programation
Brody
Brody13mo ago
thats web scraping, web scraping is in railways tos
⛧ ayami ʸᵒᵘⁿᵍᵇᵒʸ⛧
oh ok so how can I solve the error
Brody
Brody13mo ago
i wont be able to provide support for something that is in railways tos
⛧ ayami ʸᵒᵘⁿᵍᵇᵒʸ⛧
but you helped someone on this thread or is not the same
Brody
Brody13mo ago
they where not web scraping they where just generating images
⛧ ayami ʸᵒᵘⁿᵍᵇᵒʸ⛧
mmh how could you make sure it won't be used for scrapping?
Brody
Brody13mo ago
https://railway.app/legal/terms section 6, subsection 8 going to lock this thread now, as it has been solved
Want results from more Discord servers?
Add your server