Ad Widget

Collapse

ZBX_TLSConnect ignored on docker container

Collapse
This topic has been answered.
X
X
 
  • Time
  • Show
Clear All
new posts
  • thomas.albech
    Junior Member
    • Nov 2023
    • 5

    #1

    ZBX_TLSConnect ignored on docker container

    Even if I specify the environment ZBX_TLSConnect=psk in my docker_compose.yml I get the following error when trying to start the container:

    zabbix_proxy [7]: ERROR: parameter "TLSPSKFile" is defined, but "TLSConnect" is not defined

    I know this isn't much information. I am relatively new to Docker, but have been running Zabbix for years.
  • Answer selected by thomas.albech at 25-11-2023, 11:23.
    solution
    Senior Member
    • Jun 2020
    • 269

    Is the variable not case sensitive?
    try
    ZBX_TLSCONNECT
    instead ZBX_TLSConnect​


    Wellington

    Comment

    • thomas.albech
      Junior Member
      • Nov 2023
      • 5

      #2
      The image I'm trying to install is: zabbix/zabbix-proxy-sqlite3:alpine-6.0-latest

      Comment

      • solution
        Senior Member
        • Jun 2020
        • 269

        #3
        I don't use docker, but see if this helps.
        I am trying to run a standalone zabbix-proxy using PSK, but I keep getting this error even though I do in fact have this defined in the .env file docker-compose.yml version: '3.5' services: zabbix-...



        Wellington

        Comment

        • thomas.albech
          Junior Member
          • Nov 2023
          • 5

          #4
          Thanks for the reply. I had already seen those posts. Unfortunately they do not solve the issue I have. Will dig a little more this coming weekend.

          Comment

          • thomas.albech
            Junior Member
            • Nov 2023
            • 5

            #5
            Snippet of docker log:

            ** Updating '/etc/zabbix/zabbix_proxy.conf' parameter "LoadModulePath": '/var/lib/zabbix/modules/'...updated
            ** Updating '/etc/zabbix/zabbix_proxy.conf' parameter "TLSConnect": ''...removed
            ** Updating '/etc/zabbix/zabbix_proxy.conf' parameter "TLSAccept": ''...removed
            ** Updating '/etc/zabbix/zabbix_proxy.conf' parameter "TLSCAFile": ''...removed
            ** Updating '/etc/zabbix/zabbix_proxy.conf' parameter "TLSCRLFile": ''...removed
            ** Updating '/etc/zabbix/zabbix_proxy.conf' parameter "TLSServerCertIssuer": ''...removed
            ** Updating '/etc/zabbix/zabbix_proxy.conf' parameter "TLSServerCertSubject": ''...removed
            ** Updating '/etc/zabbix/zabbix_proxy.conf' parameter "TLSCertFile": ''...removed
            ** Updating '/etc/zabbix/zabbix_proxy.conf' parameter "TLSCipherAll": ''...removed
            ** Updating '/etc/zabbix/zabbix_proxy.conf' parameter "TLSCipherAll13": ''...removed
            ** Updating '/etc/zabbix/zabbix_proxy.conf' parameter "TLSCipherCert": ''...removed
            ** Updating '/etc/zabbix/zabbix_proxy.conf' parameter "TLSCipherCert13": ''...removed
            ** Updating '/etc/zabbix/zabbix_proxy.conf' parameter "TLSCipherPSK": ''...removed
            ** Updating '/etc/zabbix/zabbix_proxy.conf' parameter "TLSCipherPSK13": ''...removed
            ** Updating '/etc/zabbix/zabbix_proxy.conf' parameter "TLSKeyFile": ''...removed
            ** Updating '/etc/zabbix/zabbix_proxy.conf' parameter "TLSPSKIdentity": '****'. Enable DEBUG_MODE to view value ...updated
            ** Updating '/etc/zabbix/zabbix_proxy.conf' parameter "TLSPSKFile": '/var/lib/zabbix/enc/secret.psk'...updated
            ** Updating '/etc/zabbix/zabbix_proxy.conf' parameter "User": 'zabbix'...updated
            zabbix_proxy [6]: ERROR: parameter "TLSPSKFile" is defined, but "TLSConnect" is not defined


            And here is my docker-compose.yml

            version: '3'
            services:
            zabbix-proxy:
            image: zabbix/zabbix-proxy-sqlite3:alpine-6.0-latest
            container_name: zabbix-proxy
            environment:
            - ZBX_SERVER_HOST=[hidden]
            - ZBX_SERVER_PORT=10051
            - ZBX_PROXYMODE=0
            - ZBX_STARTPOLLERS=5
            - ZBX_STARTTRAPPERS=5
            - ZBX_STARTPINGERS=1
            - ZBX_STARTDISCOVERERS=1
            - ZBX_STARTHTTPPOLLERS=1
            - ZBX_HOSTNAME=[hidden]
            - ZBX_TLSConnect=psk
            - ZBX_TLSPSKIDENTITY=[hidden]
            - ZBX_TLSPSKFILE=/var/lib/zabbix/enc/secret.psk
            # Optionally, you can set other environment variables as needed.
            # For example, to use MySQL instead of SQLite:
            # - DB_SERVER_HOST=your_mysql_server_ip
            # - DB_SERVER_PORT=3306
            # - DB_SERVER_DBNAME=zabbix
            # - DB_SERVER_USER=zabbix
            # - DB_SERVER_PASSWORD=zabbix
            volumes:
            - ./enc:/var/lib/zabbix/enc
            - ./db_data:/var/lib/zabbix/db_data
            - ./externalscripts:/usr/lib/zabbix/externalscripts

            ports:
            - "10051:10051"
            networks:
            - zabbix-net
            restart: unless-stopped

            networks:
            zabbix-net:
            driver: bridge

            ​As you can see its removing the TLSConnect though it is definately defined.

            Comment

            • solution
              Senior Member
              • Jun 2020
              • 269

              #6
              Is the variable not case sensitive?
              try
              ZBX_TLSCONNECT
              instead ZBX_TLSConnect​


              Wellington

              Comment

              • thomas.albech
                Junior Member
                • Nov 2023
                • 5

                #7
                That was in fact the issue. Was pretty sure I had tried that first due to the error message being ..TLSConnect​...
                Thanks

                Comment

                Working...