Try new syntax for telegraf ports, SC-2522

This commit is contained in:
Patrik Holmqvist 2025-04-02 13:24:35 +02:00
parent 79560df2d8
commit 4c11d448d4
Signed by: pahol
GPG key ID: 5D5B0D4E93F77273
3 changed files with 6 additions and 4 deletions

View file

@ -1264,7 +1264,7 @@ log-qa-sto1-1.komreg.net:
sunet::dockerhost2: sunet::dockerhost2:
eid::telegraf2: eid::telegraf2:
server_type: 'log' server_type: 'log'
ports: '127.0.0.1:9999:9999' ports: ['127.0.0.1:9999:9999']
sunet::fticks: sunet::fticks:
args: -j args: -j
url: http://127.0.0.1:9999/telegraf url: http://127.0.0.1:9999/telegraf

View file

@ -3,7 +3,7 @@
# @param version Version of the docker image to use. (referenced in compose file) # @param version Version of the docker image to use. (referenced in compose file)
# @param server_fqdn The FQDN of the server. (referenced in compose file) # @param server_fqdn The FQDN of the server. (referenced in compose file)
# @param server_type Type of server, used in compose for config differentiation # @param server_type Type of server, used in compose for config differentiation
# @param ports Port mappings for container # @param ports Port mappings for container to override default
# @param service_dir The directory where all related config and files are stored. (referenced in compose file) # @param service_dir The directory where all related config and files are stored. (referenced in compose file)
# @param influx_urls List of influxdb urls to send data to # @param influx_urls List of influxdb urls to send data to
# @param influxdb2_org Influx organization (referenced in compose file) # @param influxdb2_org Influx organization (referenced in compose file)

View file

@ -13,7 +13,9 @@ services:
- '<%= @service_dir %>:<%= @service_dir %>' - '<%= @service_dir %>:<%= @service_dir %>'
- '/var/run/utmp:/var/run/utmp:ro' - '/var/run/utmp:/var/run/utmp:ro'
<% if @ports != [] -%> <% if @ports != '' -%>
ports: ports:
- <%= @ports %> <% @ports.each do |port| -%>
- <%= port %>
<% end -%>
<% end -%> <% end -%>