#Is the Playwright Firefox Docker image usable with PlaywrightCrawler?

1 messages · Page 1 of 1 (latest)

thorny mortar
#

I understand that the template for PlaywrightCrawler uses the Chrome Docker image. Is it possible to modify that Dockerfile to use apify/actor-node-playwright-firefox:16, and if so, are there any other modifications that would need to be made?

thorny mortar
#

Please see this run for details of the errors I am getting: T7zTFW0HXDl8gYdAh

barren badger
#

Hi, I have never seen this error, so I am not sure what you are doing wrong but to use firefox with playwright on apify platform you need:

  1. change dockerfile line to
    FROM apify/actor-node-playwright-firefox:16

  2. and in the code
    import { firefox } from 'playwright'

and in crawler options

 launchContext:
    {
        //useChrome:true,
        launcher:playwright.firefox,
    },

hope this helps