mirror of
https://github.com/FlareSolverr/FlareSolverr.git
synced 2025-06-10 13:27:13 +00:00
Fix EACCES: permission denied, open '/tmp/flaresolverr.txt'. Resolves #120
This commit is contained in:
parent
05f8ef95d9
commit
5da5156851
@ -36,14 +36,14 @@ function validateEnvironmentVariables() {
|
||||
}
|
||||
|
||||
async function testChromeInstallation() {
|
||||
log.debug("Testing Chrome installation...")
|
||||
const sessionId = UUIDv1()
|
||||
// create a temporary file for testing
|
||||
log.debug("Testing Chrome installation...")
|
||||
const fileContent = `flaresolverr_${version}`
|
||||
const filePath = path.join(os.tmpdir(), 'flaresolverr.txt')
|
||||
const filePath = path.join(os.tmpdir(), `flaresolverr_${sessionId}.txt`)
|
||||
const fileUrl = `file://${filePath}`
|
||||
fs.writeFileSync(filePath, fileContent)
|
||||
// launch the browser
|
||||
const sessionId = UUIDv1()
|
||||
const session = await sessions.create(sessionId, {
|
||||
userAgent: null,
|
||||
oneTimeSession: true
|
||||
|
Loading…
x
Reference in New Issue
Block a user