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

Error when launching the container from docker compose #1

Closed
jonny190 opened this issue Aug 12, 2022 · 1 comment
Closed

Error when launching the container from docker compose #1

jonny190 opened this issue Aug 12, 2022 · 1 comment

Comments

@jonny190
Copy link

jonny190 commented Aug 12, 2022

Error
Creating nxfilter_nxfilter_1 ... done
Attaching to nxfilter_nxfilter_1
nxfilter_1 | Exception in thread "main" java.lang.NullPointerException
nxfilter_1 | at nxd.Main.(Unknown Source)
nxfilter_1 | at nxd.Main.main(Unknown Source)
nxfilter_1 | Exception in thread "Thread-0" java.lang.NullPointerException
nxfilter_1 | at nxd.n.run(Unknown Source)

This is based on the below docker compose

version: '3.3'
services:
nxfilter:
image: deepwoods/nxfilter:latest
hostname: nxfilter
volumes:
- /data/nxfinter/nxfilter-conf:/nxfilter/conf
- /data/nxfinter/nxfilter-log:/nxfilter/log
- /data/nxfinter/nxfilter-db:/nxfilter/db
restart: unless-stopped
environment:
TZ: "Europe/London"
networks:
lan:
ipv4_address: ... (Ip address redacted)
networks:
lan:
external:
name: lan

@DeepWoods
Copy link
Owner

DeepWoods commented Aug 12, 2022

More than likely it's a system permissions issue with your volume mapping. NxFilter runs with root privileges in the container to be able to bind to the TCP and UPD ports required. Java may also but I'm not sure of that one. For my Debian 11 test system, I use this docker compose which maps the volumes to /var/lib/docker/volumes/compose_nxf* The file owner/group in the _data directories there are a mix of root and my personal user.

version: '3.5'

services:
  nxfilter:
    image: deepwoods/nxfilter:latest
    container_name: nxfilter
    hostname: nxfilter
    restart: unless-stopped
    environment:
      TZ: "America/Chicago"
    volumes:
      - nxfconf:/nxfilter/conf
      - nxflog:/nxfilter/log
      - nxfdb:/nxfilter/db
    ports:
      - 53:53/udp
      - 80:80
      - 443:443
      - 19002-19004:19002-19004
volumes:
  nxfconf:
  nxfdb:
  nxflog:

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