this post was submitted on 06 Oct 2024
14 points (88.9% liked)

Selfhosted

40188 readers
675 users here now

A place to share alternatives to popular online services that can be self-hosted without giving up privacy or locking you into a service you don't control.

Rules:

  1. Be civil: we're here to support and learn from one another. Insults won't be tolerated. Flame wars are frowned upon.

  2. No spam posting.

  3. Posts have to be centered around self-hosting. There are other communities for discussing hardware or home computing. If it's not obvious why your post topic revolves around selfhosting, please include details to make it clear.

  4. Don't duplicate the full text of your blog or github here. Just post the link for folks to click.

  5. Submission headline should match the article title (don’t cherry-pick information from the title to fit your agenda).

  6. No trolling.

Resources:

Any issues on the community? Report it using the report flag.

Questions? DM the mods!

founded 1 year ago
MODERATORS
 

Is it possible to somehow mount a folder to Adguard running in Docker? I have auto renewed Letsencrypt certificates, but have to copy/paste them into AdGuard. Trying to add a direct path to files doesn't work. Could it be just permissions?

top 2 comments
sorted by: hot top controversial new old
[–] [email protected] 9 points 1 month ago* (last edited 1 month ago)

Sure, you can just add a bind mount volume to mount a path from the host system to the container.

The only thing you'd have to make sure of is that whatever uid/gid the container is running as has permissions to access whatever cert files you're after (but if you're being bad and running as root, then congrats, that's not usually an issue!)

Edit: redacted docker-compose example of this:

  service-name:
    image: image-tag
    restart: unless-stopped
    container_name: service-name
    hostname: service-name
    command: '--cert /data/live/domain.com/cert.pem --key /data/live/domain.com/privkey.pem port ip:23'
    ports:
      - port-external:port-internal
    volumes:
      - /etc/letsencrypt:/data:ro

[–] [email protected] 1 points 1 month ago

Trying to add a direct path to files doesn't work.

Dunno what's wrong here, but I do add a files direct path to /etc/ssl into a docker container and works as expected.

I think It's related to miniflux and have my self-signed certificate in its truststore to communicate with wallabag (inter-docker communication).

I can't give you a snipped of my compose but will gladly edited my comment when home.