mirror of
https://github.com/FlareSolverr/FlareSolverr.git
synced 2025-06-07 12:05:37 +00:00
Build precompiled binaries with NodeJS 16
This commit is contained in:
parent
fe6cfd75b8
commit
05dcae979c
@ -66,13 +66,14 @@ This is the recommended way for Windows users.
|
||||
### From source code
|
||||
|
||||
This is the recommended way for macOS users and for developers.
|
||||
* Install [NodeJS](https://nodejs.org/).
|
||||
* Install [NodeJS](https://nodejs.org/) 16.
|
||||
* Clone this repository and open a shell in that path.
|
||||
* Run `export PUPPETEER_PRODUCT=firefox` (Linux/macOS) or `set PUPPETEER_PRODUCT=firefox` (Windows).
|
||||
* Run `npm install` command to install FlareSolverr dependencies.
|
||||
* Run `node node_modules/puppeteer/install.js` to install Firefox.
|
||||
* Run `npm start` command to compile TypeScript code and start FlareSolverr.
|
||||
|
||||
If you get errors related to firefox not installed try running `node node_modules/puppeteer/install.js` to install Firefox.
|
||||
|
||||
### Systemd service
|
||||
|
||||
We provide an example Systemd unit file `flaresolverr.service` as reference. You have to modify the file to suit your needs: paths, user and environment variables.
|
||||
|
@ -64,8 +64,8 @@ function getFirefoxNightlyVersion() {
|
||||
if (fs.existsSync('bin')) {
|
||||
fs.rmSync('bin', { recursive: true })
|
||||
}
|
||||
execSync('./node_modules/.bin/pkg -t node14-win-x64,node14-linux-x64 --out-path bin .')
|
||||
// execSync('./node_modules/.bin/pkg -t node14-win-x64,node14-mac-x64,node14-linux-x64 --out-path bin .')
|
||||
execSync('./node_modules/.bin/pkg -t node16-win-x64,node16-linux-x64 --out-path bin .')
|
||||
// execSync('./node_modules/.bin/pkg -t node16-win-x64,node16-mac-x64,node16-linux-x64 --out-path bin .')
|
||||
|
||||
// get firefox revision
|
||||
const revision = await getFirefoxNightlyVersion();
|
||||
|
1794
package-lock.json
generated
1794
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@ -6,7 +6,7 @@
|
||||
"start": "tsc && node ./dist/server.js",
|
||||
"build": "tsc",
|
||||
"dev": "nodemon -e ts --exec ts-node src/server.ts",
|
||||
"package": "node build-binaries.js",
|
||||
"package": "tsc && node build-binaries.js",
|
||||
"test": "jest --runInBand"
|
||||
},
|
||||
"author": "Diego Heras (ngosang)",
|
||||
@ -37,7 +37,7 @@
|
||||
"@types/uuid": "^8.3.1",
|
||||
"archiver": "^5.3.0",
|
||||
"nodemon": "^2.0.13",
|
||||
"pkg": "^4.4.9",
|
||||
"pkg": "^5.5.2",
|
||||
"supertest": "^6.1.6",
|
||||
"ts-jest": "^27.0.7",
|
||||
"ts-node": "^10.3.0",
|
||||
|
Loading…
x
Reference in New Issue
Block a user