influxdata / influxdata/influxdata-docker

Possible Bug influxdb 2.x Karbon K8s initScripts

Open
#628 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

influxdb
Dominant language
Shell
Stars
364
Forks
255
Avg merge
3h 18m
Merged PRs (30d)
7

Description

Hi
i think i have one bug or same in Nutanix Karbon K8s.

i run one helm chart influxdata/influxdb2

i go to put true the .sh:

initScripts:
enabled: true
scripts:
init_dbs.sh: |-
#!/bin/bash
set -e
influx bucket create \
--name my_db \
--description my_db \
--token ${DOCKER_INFLUXDB_INIT_ADMIN_TOKEN} \
--org ${DOCKER_INFLUXDB_INIT_ORG}
my_db=`influx bucket list | grep " my_db" | awk '{printf $1}'` ; echo $ my_db; influx v1 dbrp create --db my_db --rp autogen --default -t ${DOCKER_INFLUXDB_INIT_ADMIN_TOKEN} --bucket-id $ my_db;
my_db=`influx bucket list | grep "my_db" | awk '{printf $1}'` ;

influx v1 auth create \
--username user \
--password pass \
--org orga \
--write-bucket $my_db \

So i put false in enable work, if i put true i have this problem in pod:

`022-08-12T15:18:16. info Executing user-provided scripts {"system": "docker", "script_dir": "/docker-entrypoint-initdb.d"}
/docker-entrypoint-initdb.d/init.sh:
Error: failed to read template(s) from "https://raw.githubusercontent.com/influxdata/community-templates/master/influxdb2_operational_monitoring/influxdb2_operational_monitoring.yml": Get "https://raw.githubusercontent.com/influxdata/community-templates/master/influxdb2_operational_monitoring/influxdb2_operational_monitoring.yml": dial tcp 1xxxxxxx:443: connect: network is unreachable
run-parts: /docker-entrypoint-initdb.d/init.sh exited with return code 1
2022-08-12T15:18:16. warn cleaning bolt and engine files to prevent conflicts on retry {"system": "docker", "bolt_path": "/var/lib/influxdb2/influxd.bolt", "engine_path": "/var/lib/influxdb2"}`

but if i run same chart/influxdata/influxdb2 in aks work fine... i dint modify anithing.

`Client Version: version.Info{Major:"1", Minor:"21", GitVersion:"v1.21.8", GitCommit:"4a3b558c52eb6995b3c5c1db5e54111bd0645a64", GitTreeState:"clean", BuildDate:"2021-12-15T14:52:11Z", GoVersion:"go1.16.12", Compiler:"gc", Platform:"linux/amd64"}
`

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the Helm chart's initScripts configuration and the /docker-entrypoint-initdb.d/init.sh failure shown in the pod log; compare the working AKS deployment with the Nutanix Karbon environment. Verify whether the user-provided init_dbs.sh can complete when the pod cannot reach raw.githubusercontent.com, and document the environment or chart behavior that explains the failure.

Written by the indexing model from the issue text.

Assessment

Tech stack
docker, helm, kubernetes, shell
Domain
databases, devops, infrastructure
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.