Giter Club home page Giter Club logo

kubesql's Issues

Add Azure AKS support

This is an awesome project! Would love if azure support could be added. If I had lots of time could potentially help here.

thread 'main' panicked at 'an error occurred during creating kube client: failed to create the kube client with context

Caused by:
    0: Error loading kubeconfig: Failed exec auth: Authentication with provider azure not supported
    1: Failed exec auth: Authentication with provider azure not supported

Stack backtrace:
   0: std::backtrace_rs::backtrace::libunwind::trace
             at /rustc/07e0e2ec268c140e607e1ac7f49f145612d0f597/library/std/src/../../backtrace/src/backtrace/libunwind.rs:90:5
      std::backtrace_rs::backtrace::trace_unsynchronized
             at /rustc/07e0e2ec268c140e607e1ac7f49f145612d0f597/library/std/src/../../backtrace/src/backtrace/mod.rs:66:5
      std::backtrace::Backtrace::create
             at /rustc/07e0e2ec268c140e607e1ac7f49f145612d0f597/library/std/src/backtrace.rs:327:13
   1: std::backtrace::Backtrace::capture
             at /rustc/07e0e2ec268c140e607e1ac7f49f145612d0f597/library/std/src/backtrace.rs:295:9
   2: kubesql::main::{{closure}}
   3: tokio::park::thread::CachedParkThread::block_on
   4: tokio::runtime::thread_pool::ThreadPool::block_on
   5: tokio::runtime::Runtime::block_on
   6: kubesql::main
   7: std::sys_common::backtrace::__rust_begin_short_backtrace
   8: std::rt::lang_start::{{closure}}
   9: core::ops::function::impls::<impl core::ops::function::FnOnce<A> for &F>::call_once
             at /rustc/07e0e2ec268c140e607e1ac7f49f145612d0f597/library/core/src/ops/function.rs:259:13
      std::panicking::try::do_call
             at /rustc/07e0e2ec268c140e607e1ac7f49f145612d0f597/library/std/src/panicking.rs:379:40
      std::panicking::try

Don't work if context isn't called "context"

I've installed from cargo and tried query from readme

# RUST_BACKTRACE=1 kubesql --query "SELECT namespace FROM context WHERE pod.status.phase = 'Running'"
thread 'main' panicked at 'Given contexts ["context"] not found in your KUBECONFIG!', src/validator.rs:29:9
stack backtrace:
   0: rust_begin_unwind
             at /rustc/7eac88abb2e57e752f3302f02be5f3ce3d7adfb4/library/std/src/panicking.rs:483
   1: std::panicking::begin_panic_fmt
             at /rustc/7eac88abb2e57e752f3302f02be5f3ce3d7adfb4/library/std/src/panicking.rs:437
   2: kubesql::validator::validate_contexts
   3: kubesql::main::{{closure}}
   4: std::thread::local::LocalKey<T>::with
   5: tokio::park::thread::CachedParkThread::block_on
   6: tokio::runtime::thread_pool::ThreadPool::block_on
   7: tokio::runtime::Runtime::block_on
   8: kubesql::main

It seems application is trying to find context with name context, not using current-context that is set with kubectl config use-context

~/.kube/config

  11   │ contexts:
  12   │ - context:
  13   │     cluster: XXXXXXXXXXXXXXXXXXX
  14   │     user: XXXXXXXXXXXXXXXX
  15   │   name: org_name-kube-dev
  16   │ - context:
  17   │     cluster: YYYYYYYYYYYYYYYYYYYY
  18   │     user: YYYYYYYYYYYYYYYYY
  19   │   name: org_name-kube-prod
  20   │ current-context: org_name-kube-dev

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.