{"action":"reopened","issue":{"url":"https://api.github.com/repos/containers/libpod/issues/3653","repository_url":"https://api.github.com/repos/containers/libpod","labels_url":"https://api.github.com/repos/containers/libpod/issues/3653/labels{/name}","comments_url":"https://api.github.com/repos/containers/libpod/issues/3653/comments","events_url":"https://api.github.com/repos/containers/libpod/issues/3653/events","html_url":"https://github.com/containers/libpod/issues/3653","id":473533289,"node_id":"MDU6SXNzdWU0NzM1MzMyODk=","number":3653,"title":"journald driver: missing CONTAINER_TAG and not human readable CONTAINER_NAME","user":{"login":"abalage","id":6349914,"node_id":"MDQ6VXNlcjYzNDk5MTQ=","avatar_url":"https://avatars2.githubusercontent.com/u/6349914?v=4","gravatar_id":"","url":"https://api.github.com/users/abalage","html_url":"https://github.com/abalage","followers_url":"https://api.github.com/users/abalage/followers","following_url":"https://api.github.com/users/abalage/following{/other_user}","gists_url":"https://api.github.com/users/abalage/gists{/gist_id}","starred_url":"https://api.github.com/users/abalage/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/abalage/subscriptions","organizations_url":"https://api.github.com/users/abalage/orgs","repos_url":"https://api.github.com/users/abalage/repos","events_url":"https://api.github.com/users/abalage/events{/privacy}","received_events_url":"https://api.github.com/users/abalage/received_events","type":"User","site_admin":false},"labels":[{"id":1072791328,"node_id":"MDU6TGFiZWwxMDcyNzkxMzI4","url":"https://api.github.com/repos/containers/libpod/labels/kind/feature","name":"kind/feature","color":"c7def8","default":false,"description":"Categorizes issue or PR as related to a new feature."}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":7,"created_at":"2019-07-26T20:57:48Z","updated_at":"2019-11-21T02:11:13Z","closed_at":null,"author_association":"NONE","body":"**Is this a BUG REPORT or FEATURE REQUEST? (leave only one on its own line)**\r\n\r\n/kind feature\r\n\r\n**Description**\r\n\r\nI've been using journald logging driver in docker where I set \"--log-opt tag=\" to a value containing arbitrary strings and docker variables. I tried to mimic the behavior with podman but I have very different outcome. I am not sure whether this is a bug or a missing feature.\r\n\r\n**Steps to reproduce the issue:**\r\n\r\n1. podman run --rm -ti --log-driver journald --log-opt tag=\"nginx|{{.ImageName}}|{{.DaemonName}}\" --log-opt labels=app ubuntu:18.04 bash\r\n\r\n2. journalctl -u machine.slice -o json | tail -n1| json_pp|less -S\r\n\r\n**Describe the results you received:** (trimmed content to improve readability, will attach full sample)\r\n```\r\n{\r\n   \"_BOOT_ID\" : \"546ef9b86c7847b99e172835cb33011f\",\r\n   \"_SYSTEMD_INVOCATION_ID\" : \"8f745bf862c44c1094b6a91dbafcac11\",\r\n   \"CONTAINER_ID_FULL\" : \"04a0c89d323731b9405353fc9caa5416918e8a36301021f589c66c5133c64024\",\r\n   \"__MONOTONIC_TIMESTAMP\" : \"371906559497\",\r\n   \"_CAP_EFFECTIVE\" : \"3fffffffff\",\r\n   \"CONTAINER_ID\" : \"04a0c89d3237\",\r\n   \"_MACHINE_ID\" : \"151a80720f8fb46abd949ae05a99c4b1\",\r\n   \"_GID\" : \"0\",\r\n   \"MESSAGE\" : [\r\n      27,\r\n      93,\r\n      48,\r\n      59,\r\n      114,\r\n      111\r\n   ],\r\n   \"CODE_FUNC\" : \"write_journald\",\r\n   \"_COMM\" : \"conmon\",\r\n   \"_SOURCE_REALTIME_TIMESTAMP\" : \"1564173445318744\",\r\n   \"_UID\" : \"0\",\r\n   \"CONTAINER_PARTIAL_MESSAGE\" : \"true\",\r\n   \"CONTAINER_NAME\" : [\r\n      111,\r\n      112,\r\n      116,\r\n      105\r\n   ],\r\n   \"_CMDLINE\" : \"/usr/lib/podman/bin/conmon -s -c 04a0c89d323731b9405353fc9caa5416918e8a36301021f589c66c5133c64024 -u 04a0c89d323731b9405353fc9caa5416918e8a36301021f589c66c5133c64024 -n optimistic_goldwasser -r /usr/bin/runc -b /var/lib/containers/storage/btrfs-containers/04a0c89d323731b9405353fc9caa5416918e8a36301021f589c66c5133c64024/userdata -p /var/run/containers/storage/btrfs-containers/04a0c89d323731b9405353fc9caa5416918e8a36301021f589c66c5133c64024/userdata/pidfile --exit-dir /var/run/libpod/exits --runtime-arg --log-format=json --runtime-arg --log --runtime-arg=/var/run/containers/storage/btrfs-containers/04a0c89d323731b9405353fc9caa5416918e8a36301021f589c66c5133c64024/userdata/oci-log --exit-command /usr/bin/podman --exit-command-arg --root --exit-command-arg /var/lib/containers/storage --exit-command-arg --runroot --exit-command-arg /var/run/containers/storage --exit-command-arg --log-level --exit-command-arg error --exit-command-arg --cgroup-manager --exit-command-arg systemd --exit-command-arg --tmpdir --exit-command-arg /var/run/libpod --exit-command-arg --runtime --exit-command-arg runc --exit-command-arg --storage-driver --exit-command-arg btrfs --exit-command-arg container --exit-command-arg cleanup --exit-command-arg --rm --exit-command-arg 04a0c89d323731b9405353fc9caa5416918e8a36301021f589c66c5133c64024 --socket-dir-path /var/run/libpod/socket -t -l journald: --log-level error\",\r\n   \"_HOSTNAME\" : \"microchuck\",\r\n   \"_PID\" : \"9605\",\r\n   \"_EXE\" : \"/usr/lib/podman/bin/conmon\",\r\n   \"SYSLOG_IDENTIFIER\" : \"conmon\",\r\n   \"_SYSTEMD_SLICE\" : \"machine.slice\",\r\n   \"CODE_FILE\" : \"src/ctr_logging.c\",\r\n   \"CODE_LINE\" : \"213\",\r\n   \"PRIORITY\" : \"6\",\r\n   \"_TRANSPORT\" : \"journal\",\r\n   \"_SYSTEMD_CGROUP\" : \"/machine.slice/libpod-conmon-04a0c89d323731b9405353fc9caa5416918e8a36301021f589c66c5133c64024.scope\",\r\n   \"_SYSTEMD_UNIT\" : \"libpod-conmon-04a0c89d323731b9405353fc9caa5416918e8a36301021f589c66c5133c64024.scope\",\r\n   \"__REALTIME_TIMESTAMP\" : \"1564173445319716\",\r\n   \"__CURSOR\" : \"s=c252e0b60b794360b312576f0e41c3eb;i=d79edd;b=546ef9b86c7847b99e172835cb33011f;m=56975bbe09;t=58e9b82934c24;x=62364941f06c3b0b\"\r\n}\r\n```\r\n\r\n**Describe the results you expected:**\r\nExpect CONTAINER_TAG key to contain: \"nginx|ubuntu:18.04|docker\"\r\nExpect CONTAINER_NAME to be human readable like or at least first part of ID in case it is not given.\r\n\r\n**Additional information you deem important (e.g. issue happens only occasionally):**\r\n\r\nI know variables like {{.DaemonName}} does not make sense. My actual need is to get the name of the image and its tag the container is based on. For example: \"ubuntu:18.04\"\r\n\r\n**Output of `podman version`:**\r\n\r\n```\r\nVersion:            1.4.4\r\nRemoteAPI Version:  1\r\nGo Version:         go1.12.2\r\nOS/Arch:            linux/amd64\r\n```\r\n\r\n**Output of `podman info --debug`:**\r\n\r\n```\r\ndebug:\r\n  compiler: gc\r\n  git commit: \"\"\r\n  go version: go1.12.2\r\n  podman version: 1.4.4\r\nhost:\r\n  BuildahVersion: 1.9.0\r\n  Conmon:\r\n    package: podman-1.4.4-lp151.4.1.x86_64\r\n    path: /usr/lib/podman/bin/conmon\r\n    version: 'conmon version 0.3.0, commit: unknown'\r\n  Distribution:\r\n    distribution: '\"opensuse-leap\"'\r\n    version: \"15.1\"\r\n  MemFree: 3507871744\r\n  MemTotal: 7789297664\r\n  OCIRuntime:\r\n    package: runc-1.0.0~rc6-lp151.1.2.x86_64\r\n    path: /usr/bin/runc\r\n    version: |-\r\n      runc version 1.0.0-rc6\r\n      spec: 1.0.1-dev\r\n  SwapFree: 0\r\n  SwapTotal: 0\r\n  arch: amd64\r\n  cpus: 2\r\n  hostname: microchuck\r\n  kernel: 4.12.14-lp151.28.10-default\r\n  os: linux\r\n  rootless: false\r\n  uptime: 103h 36m 5.02s (Approximately 4.29 days)\r\nregistries:\r\n  blocked: null\r\n  insecure: null\r\n  search:\r\n  - docker.io\r\nstore:\r\n  ConfigFile: /etc/containers/storage.conf\r\n  ContainerStore:\r\n    number: 5\r\n  GraphDriverName: btrfs\r\n  GraphOptions: null\r\n  GraphRoot: /var/lib/containers/storage\r\n  GraphStatus:\r\n    Build Version: 'Btrfs v4.19.1 '\r\n    Library Version: \"102\"\r\n  ImageStore:\r\n    number: 7\r\n  RunRoot: /var/run/containers/storage\r\n  VolumePath: /var/lib/containers/storage/volumes\r\n```\r\n\r\n**Additional environment details (AWS, VirtualBox, physical, etc.):**\r\nOS is OpenSUSE Leap 15.1 amd64. Podman is from devel:kubic repository.\r\n\r\n[journald-json-output-docker.txt](https://github.com/containers/libpod/files/3437371/journald-json-output-docker.txt)\r\n[journald-json-output-podman.txt](https://github.com/containers/libpod/files/3437372/journald-json-output-podman.txt)\r\n\r\n"}}
{"actor":{"display_login":"mheon"}}