View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0010126 | Taler | merchant backend | public | 2025-06-23 23:39 | 2025-07-08 08:54 |
Reporter | hank | Assigned To | schanzen | ||
Priority | normal | Severity | minor | Reproducibility | always |
Status | resolved | Resolution | reopened | ||
Product Version | 1.0 | ||||
Target Version | 1.1 | Fixed in Version | 1.1 | ||
Summary | 0010126: taler.conf can't be symlink of symlink | ||||
Description | taler-merchant-httpd can't read taler.conf if it's a symlink pointing to a symlink pointing to the actual file. the rule in Linux is normally resolving a chain of symlinks recursively until the actual file. this is a problem e.g. for kubernetes which maps config files as configmaps into the file system using a 2-hop symlink. https://kubernetes.io/docs/concepts/configuration/configmap/#using-configmaps-as-files-from-a-pod | ||||
Steps To Reproduce | create "tmp2" with the actual config contents, and 2 symlinks: # ls -la total 20 drwxr-xr-x 2 root root 4096 Jun 23 23:32 . drwxr-xr-x 153 root root 12288 Jun 23 23:07 .. lrwxrwxrwx 1 root root 4 Jun 23 23:29 taler.conf -> tmp1 lrwxrwxrwx 1 root root 4 Jun 23 23:29 tmp1 -> tmp2 -rw-r--r-- 1 root root 401 Jun 23 23:07 tmp2 | ||||
Tags | No tags attached. | ||||
|
@schanzen: this seems strange, but probably something in libgnunetutil -- care to investigate? |
|
thanks for looking into this. I have a working Kubernetes configuration here that I can share once this is fixed. |
|
Fix committed to master branch. |
|
apologies but this is still failing on me with latest gnunet master have you actually tried the two-symlink arrangement from "steps to reproduce" |
|
Yes I tested against exactly that. With gnunet-config, however. |
|
Are you sure you recompiled merchant against the new libgnunetutil from gnunet master? taler-merchant-httpd also parses the config file for me (and not the symlink) which was the problem. |
|
I used the Dockerfile provided here https://bugs.gnunet.org/view.php?id=10119#c25392 I ran docker build 3 days ago meaning your commit was included. I can also run the image and see the actual source files with the patches so no mistakes here. I am using the docker-compose.yaml attached. my local ./config directory has this structure: $ ls -l config/ total 4 lrwxrwxrwx 1 tenant tenant 4 Jul 7 21:39 taler.conf -> tmp1 lrwxrwxrwx 1 tenant tenant 4 Jul 7 21:39 tmp1 -> tmp2 -rw-rw-r-- 1 tenant tenant 383 Jun 26 23:33 tmp2 it works if there aren't symlinks but doesn't work with the symlinks above docker-compose.yaml (3,240 bytes)
name: taler services: postgres: image: postgres:17-alpine environment: POSTGRES_PASSWORD: password POSTGRES_DB: taler-merchant volumes: - postgresql_socket:/var/run/postgresql - db-data:/var/lib/postgresql/data healthcheck: test: pg_isready --dbname=postgres://postgres:password@/postgres interval: 10s timeout: 1s retries: 5 start_period: 5s start_interval: 1s init-db: image: taler-merchant:latest command: taler-merchant-dbinit -c /etc/taler/taler.conf environment: PGUSER: postgres PGPASSWORD: password volumes: - type: bind source: ./config target: /etc/taler read_only: true - postgresql_socket:/var/run/postgresql depends_on: postgres: condition: service_healthy httpd: ports: - 8080:8080 image: taler-merchant:latest command: taler-merchant-httpd -c /etc/taler/taler.conf environment: PGUSER: postgres PGPASSWORD: password volumes: - type: bind source: ./config target: /etc/taler read_only: true - postgresql_socket:/var/run/postgresql depends_on: postgres: condition: service_healthy init-db: condition: service_completed_successfully webhook: image: taler-merchant:latest command: taler-merchant-webhook -c /etc/taler/taler.conf environment: PGUSER: postgres PGPASSWORD: password volumes: - type: bind source: ./config target: /etc/taler read_only: true - postgresql_socket:/var/run/postgresql depends_on: postgres: condition: service_healthy init-db: condition: service_completed_successfully wirewatch: image: taler-merchant:latest command: taler-merchant-wirewatch -c /etc/taler/taler.conf environment: PGUSER: postgres PGPASSWORD: password volumes: - type: bind source: ./config target: /etc/taler read_only: true - postgresql_socket:/var/run/postgresql depends_on: postgres: condition: service_healthy init-db: condition: service_completed_successfully depositcheck: image: taler-merchant:latest command: taler-merchant-depositcheck -c /etc/taler/taler.conf environment: PGUSER: postgres PGPASSWORD: password volumes: - type: bind source: ./config target: /etc/taler read_only: true - postgresql_socket:/var/run/postgresql depends_on: postgres: condition: service_healthy init-db: condition: service_completed_successfully exchangekeyupdate: image: taler-merchant:latest command: taler-merchant-exchangekeyupdate -c /etc/taler/taler.conf environment: PGUSER: postgres PGPASSWORD: password volumes: - type: bind source: ./config target: /etc/taler read_only: true - postgresql_socket:/var/run/postgresql depends_on: postgres: condition: service_healthy init-db: condition: service_completed_successfully volumes: db-data: postgresql_socket: driver: local |
|
I did not consider the directory path and only tested symlinks in PWD. Try e21d59ae2..3d682e5ff |
|
works. awesome. |
Date Modified | Username | Field | Change |
---|---|---|---|
2025-06-23 23:39 | hank | New Issue | |
2025-06-30 18:08 | Christian Grothoff | Assigned To | => schanzen |
2025-06-30 18:08 | Christian Grothoff | Status | new => assigned |
2025-06-30 18:08 | Christian Grothoff | Note Added: 0025383 | |
2025-06-30 18:09 | Christian Grothoff | Target Version | => 1.1 |
2025-06-30 20:17 | hank | Note Added: 0025384 | |
2025-07-01 12:00 | schanzen | Changeset attached | => gnunet master e21d59ae |
2025-07-01 12:00 | schanzen | Note Added: 0025385 | |
2025-07-01 12:00 | schanzen | Status | assigned => resolved |
2025-07-01 12:00 | schanzen | Resolution | open => fixed |
2025-07-05 00:39 | hank | Status | resolved => feedback |
2025-07-05 00:39 | hank | Resolution | fixed => reopened |
2025-07-05 00:39 | hank | Note Added: 0025423 | |
2025-07-07 21:20 | schanzen | Note Added: 0025434 | |
2025-07-07 21:24 | schanzen | Note Added: 0025435 | |
2025-07-07 21:45 | hank | Note Added: 0025436 | |
2025-07-07 21:45 | hank | File Added: docker-compose.yaml | |
2025-07-07 21:45 | hank | Status | feedback => assigned |
2025-07-07 23:21 | schanzen | Note Added: 0025437 | |
2025-07-07 23:21 | schanzen | Status | assigned => feedback |
2025-07-07 23:58 | hank | Note Added: 0025439 | |
2025-07-07 23:58 | hank | Status | feedback => assigned |
2025-07-08 08:54 | schanzen | Status | assigned => resolved |
2025-07-08 08:54 | schanzen | Fixed in Version | => 1.1 |