Comments (9)
If using -d
, the process daemonizes, so what you observe is the expected behaviour. Regarding docker, there is a Dockerfile
included in the project root, have you tried that?
When using --appimage-extract-and-run
, the order of arguments matters. You should put -d
after, not before, --appimage-extract-and-run
. This may be enough to fix your issue. However I don't recommend deploying the appimage inside docker, it makes little sense.
I understand you usually run foreground processes in a container and this should be addressed in PyBitmessage. There isn't a direct way to do that now in, what you could do is to comment calls to daemonize
in src/bitmessagemain.py
.
from pybitmessage.
I currently run bitmessage in daemon mode in a docker container and it works just fine, along with several other containers, using docker-compose. This allows separation from the host system and easier install of the system bitmessage is a part of (BitChan). I was attempting to move to an AppImage to prevent having to install Python 2 and Qt4.
You should put -d after, not before, --appimage-extract-and-run
This is what I did that causes the container to stop.
from pybitmessage.
Well, I found I could spawn a foreground sleep process that keeps the container running:
/usr/local/bin/pybitmessage -d & sleep infinity
Note1: pybitmessage is a symlink to the appimage.
Note2: I've moved to using the env variable APPIMAGE_EXTRACT_AND_RUN=1.
Strangely, now I can't access the API, the connection is refused. I've merely run the appimage instead of the normal linux binary, so I'm a little baffled what the issue is now, since kays.dat should be recognized since its location is set via the environment variable BITMESSAGE_HOME.
I've verified it's not an issue with the appimage, as I've been able to run it in daemon mode on my host linux system and connect to the API. So, the issue appears to be related to docker.
Update: It seems the issue is a listener is not created within the container. Using netstat -tunlp
I can see the API port hasn't been set up to be listened on by bitmessage. I'm sort of had a standstill, since I can't get much information from bitmessage. Is there some way to enable more verbose output when it's starting up?
from pybitmessage.
I think I found what causes the issue, it's --appimage-extract-and-run
.
Note: The following is running outside docker, on a full linux distro.
When executed without --appimage-extract-and-run
:
user@box:~$ ./PyBitmessage-0.6.3.2.glibc2.15-x86_64.AppImage -d
2022-01-23 00:19:42,606 - WARNING - Using default logger configuration
Running as a daemon. Send TERM signal to end.
Terminated
user@box:~$ sudo netstat -tunlp
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 0.0.0.0:8444 0.0.0.0:* LISTEN 286150/././/bin/pyt
tcp 0 0 0.0.0.0:8445 0.0.0.0:* LISTEN 286150/././/bin/pyt
udp 0 0 0.0.0.0:8444 0.0.0.0:* 286150/././/bin/pyt
When executed with --appimage-extract-and-run
:
user@box:~$ ./PyBitmessage-0.6.3.2.glibc2.15-x86_64.AppImage --appimage-extract-and-run -d
2022-01-23 00:19:42,606 - WARNING - Using default logger configuration
Running as a daemon. Send TERM signal to end.
user@box:~$ sudo netstat -tunlp
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
from pybitmessage.
I was attempting to move to an AppImage to prevent having to install Python 2 and Qt4.
You don't need Qt4 for the daemon.
from pybitmessage.
You don't need Qt4 for the daemon
Although true, the issue still exists with using the appimage with --appimage-extract-and-run -d
I misspoke, BitChan doesn't install Qt4, only Python 2, as a dependency for Bitmessage.
from pybitmessage.
You don't need Qt4 for the daemon
Although true, the issue still exists with using the appimage with --appimage-extract-and-run -d
I misspoke, BitChan doesn't install Qt4, only Python 2, as a dependency for Bitmessage.
The appimage was designed for desktop. I'll repeat what @PeterSurda wrote: running appimage inside of a docker container is a bit overkill, use official Dockerfile. The --appimage-extract-and-run
is a workaround for testing environments.
from pybitmessage.
running appimage inside of a docker container is a bit overkill, use official Dockerfile
Even outside docker, the issue persists, as demonstrated in #1924 (comment)
from pybitmessage.
It appears setting the environment variable NO_CLEANUP when also setting APPIMAGE_EXTRACT_AND_RUN (--appimage-extract-and-run
), solves the issue:
user@box:~$ export NO_CLEANUP=1
user@box:~$ ./PyBitmessage-0.6.3.2.glibc2.15-x86_64.AppImage --appimage-extract-and-run -d
2022-01-23 11:51:26,844 - WARNING - Using default logger configuration
Running as a daemon. Send TERM signal to end.
user@box:~$ sudo netstat -tunlp
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 0.0.0.0:8444 0.0.0.0:* LISTEN 301474/././/bin/pyt
tcp 0 0 0.0.0.0:8445 0.0.0.0:* LISTEN 301474/././/bin/pyt
udp 0 0 0.0.0.0:8444 0.0.0.0:* 301474/././/bin/pyt
from pybitmessage.
Related Issues (20)
- Outdated installment instructions HOT 1
- No connection using Appimage
- `dontconnect` UI test
- The date and time of reception is affected by environment variables.
- Appimage build broken? HOT 1
- No chance to run on -> macOS Monterey HOT 2
- Append `*.sql` files into `buildozer.spec`
- APPImage doesn't connect anymore HOT 8
- Bitmesage Plus enhanced security
- Pyelliptic is deprecated HOT 1
- Arch Linux is missing a maintainer
- Linux Mint 21 (cinnamon) incompatibility
- Incorrect stream offset in `HandleDisseminatePreEncryptedMsg`
- *
- Peter Surda (Peter Šurda) poses a significant threat to Bitmessage. HOT 3
- PyQt4 module is not availabale anymore HOT 3
- Newbie on Linux(Ubuntu) with AppImage HOT 1
- Appimage release
- 中文比特channel (ad, can close me)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pybitmessage.