Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to run on a RPI3B #298

Open
Tsjippy opened this issue Nov 18, 2024 · 4 comments
Open

How to run on a RPI3B #298

Tsjippy opened this issue Nov 18, 2024 · 4 comments

Comments

@Tsjippy
Copy link

Tsjippy commented Nov 18, 2024

I love this package and it runs great on my windows machine.

But it doesnt work on my RPI3b.

I have locally used all changed from #280 and #289.

QR code generation worked one time but most of the times I get the "qr code not ready or already scanned" error. Even if I remove the whole sessions folder and start a new folder.

A visit to :3000/session/status/test makes the server crash.

I have this in my .env file:

## Application ##
PORT=3000 # OPTIONAL, DEFAULT 3000
API_KEY= # OPTIONAL, DEFAULT EMPTY
BASE_WEBHOOK_URL=http://localhost:3000/localCallbackExample # MANDATORY
ENABLE_LOCAL_CALLBACK_EXAMPLE=FALSE # OPTIONAL, DISABLE FOR PRODUCTION
RATE_LIMIT_MAX=1000 # OPTIONAL, THE MAXIUM NUMBER OF CONNECTIONS TO ALLOW PER TIME FRAME
RATE_LIMIT_WINDOW_MS=60000 # OPTIONAL, TIME FRAME FOR WHICH REQUESTS ARE CHECKED IN MS

## Client ##
MAX_ATTACHMENT_SIZE=10000000 # IF REACHED, MEDIA ATTACHMENT BODY WILL BE NULL
SET_MESSAGES_AS_SEEN=TRUE # WILL MARK THE MESSAGES AS READ AUTOMATICALLY
# ALL CALLBACKS: auth_failure|authenticated|call|change_state|disconnected|group_join|group_leave|group_update|loading_screen|media_uploaded|message|message_ack|message_create|message_reaction|message_revoke_everyone|qr|ready|contact_changed|unread_count|message_edit|message_ciphertext
DISABLED_CALLBACKS=message_ack|message_reaction|unread_count|message_edit|message_ciphertext  # PREVENT SENDING CERTAIN TYPES OF CALLBACKS BACK TO THE WEBHOOK
WEB_VERSION='2.2328.5' # OPTIONAL, THE VERSION OF WHATSAPP WEB TO USE
WEB_VERSION_CACHE_TYPE=none # OPTIONAL, DETERMINTES WHERE TO GET THE WHATSAPP WEB VERSION(local, remote or none), DEFAULT 'none'
RECOVER_SESSIONS=TRUE # OPTIONAL, SHOULD WE RECOVER THE SESSION IN CASE OF PAGE FAILURES
CHROME_BIN= /usr/bin/chromium-browser  # OPTIONAL, PATH TO CHROME BINARY
HEADLESS=TRUE # OPTIONAL, RUN CHROME IN HEADLESS MODE

## Session File Storage ##
SESSIONS_PATH=./sessions # OPTIONAL

ENABLE_SWAGGER_ENDPOINT=TRUE # OPTIONAL

So I feel there is still a lot to do to have it working on a rpi.

@avoylenko
Copy link
Collaborator

Is there anything written to the server log during the crash?

@Tsjippy
Copy link
Author

Tsjippy commented Nov 20, 2024

unfortunately not.

But I think the start up process is v ery power hungry. More than the rpi can handle.
Would be great if we could turn off the callback(I don't care about receiving messages, I just want to send them) or something

@avoylenko
Copy link
Collaborator

The browser is CPU/memory consuming process and turning off the callback won't change anything. Try to allocate more RAM by cutting the memory allocated to the GPU.

@Tsjippy
Copy link
Author

Tsjippy commented Nov 20, 2024

ok thanks.

In the end I choose to use this: https://github.com/gajosu/whatsapp-ha-addon on my rpi4

thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants