Skip to content

Atlantis crashes on atlantis plan after redis configuration #5379

Open
@jgatt513

Description

@jgatt513

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request. Searching for pre-existing feature requests helps us consolidate datapoints for identical requirements into a single place, thank you!
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request.
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment.

Overview of the Issue

After configuring Atlantis Server to use redis as lockingdbtype the container gets created without any issues but on the attempt to run a plan it fails with the following:

runtime error: invalid memory address or nil pointer dereference runtime/panic.go:262 (0x472a98) runtime/signal_unix.go:917 (0x472a68) github.com/runatlantis/atlantis/server/events/command_runner.go:340 (0x11539da) runtime/asm_amd64.s:1700 (0x478960)

Reproduction Steps

  • add redis cluster to your kubernetes cluster and same namespace as atlantis.

  • set atlanits server args
    args:
    - server
    - --log-level={{ .Values.log.level }}
    - --repo-config=/atlantis-config/repos.yaml
    - --redis-host="atlantis-leader-headless.atlantis.svc.cluster.local"
    - --redis-password=""
    - --locking-db-type="redis"
    - --checkout-strategy=merge
    - --atlantis-url=https://{{ get (first .Values.ingress.hosts ) "host" }}
    - --default-tf-version={{ .Values.defaultTFVersion }}
    - --enable-regexp-cmd
    - --hide-unchanged-plan-comments
    - --quiet-policy-checks

  • Once the environment and pods are stable and healthy attempt to run a plan.

Logs

{"level":"info","ts":"2025-03-04T15:37:05.261Z","caller":"events/events_controller.go:692","msg":"Handling 'plan' comment","json":{"repo":"alienadmin/terragrunt","pull":4185}} │
│ {"level":"info","ts":"2025-03-04T15:37:05.261Z","caller":"events/events_controller.go:736","msg":"Running comment command 'plan' for user '712020:1ba2ddde-b573-42df-a1d4-c6a7b1a4d83b'.","json":{"repo" │
│ {"level":"error","ts":"2025-03-04T15:37:05.262Z","caller":"events/command_runner.go:555","msg":"PANIC: runtime error: invalid memory address or nil pointer dereference\nruntime/panic.go:262 (0x472a98)

Environment details

atlantis version v.0.33.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    StalebugSomething isn't workingwaiting-on-responseWaiting for a response from the user

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions