Skip to content

Install the development environment โ€‹

Requirements โ€‹

OS โ€‹

Ubuntu 23.04 or later is recommended, but any Linux distribution should work.

It has also been tested on Windows but it requires more configuration (see below).

Software โ€‹

ProxyHerd requires:

Get the repository โ€‹

Clone the repository:

shell
git clone git@github.com:proxyherd/proxyherd.git

cd proxyherd

Install dependencies โ€‹

Platform specific: Windows โ€‹

For Windows development, make sure to install the following dependencies before proceeding with the Node.js dependencies installation:

shell
npm install --save-dev @nx/nx-win32-x64-msvc @rollup/rollup-win32-x64-msvc

Platform specific: MacOS โ€‹

For MacOS development, make sure to install the following dependencies before proceeding with the Node.js dependencies installation:

shell
npm install --save-dev @nx/nx-darwin-arm64 @rollup/rollup-darwin-arm64

Node.js dependencies โ€‹

Install Node.js dependencies:

shell
npm install

Test configuration โ€‹

The test files in packages/backend/test/src/assets (storage-file.env, storage-memory.env, storage-distributed.env) run the language samples with python3 and java taken from your PATH. The Python sample needs the requests package:

shell
python3 -m pip install requests

To use other executables, set PYTHON and JAVA in your shell before running the tests; variables that already exist are not overwritten by the env file.

Build the project โ€‹

shell
npm run build

Run all tests โ€‹

The file storage-file.env contains the variables to run the tests.

Before running the tests, you need to set the environment variable DOTENV_FILE to the path of the file storage-file.env:

shell
export DOTENV_FILE=packages/backend/test/src/assets/storage-file.env

On Windows, replace export by set.

TIP

You can replace storage-file.env by storage-memory.env or storage-distributed.env to test other storage.

Then, run the tests:

shell
npm run test

Run the linter โ€‹

shell
npm run lint

Start the development environment โ€‹

In a first terminal, run the backend:

shell
export COMMANDER_PORT=8889
export AUTH_LOCAL_USERNAME=admin
export AUTH_LOCAL_PASSWORD=password
export BACKEND_JWT_SECRET=secret1
export FRONTEND_JWT_SECRET=secret2

npm run start:backend-app

On Windows, replace export by set.


In a second terminal, run the frontend:

shell
npm run start:frontend-app

Released under the MIT License. ProxyHerd is a community fork of Scrapoxy 4.17.4 and is not affiliated with its original author.