Code Monkey home page Code Monkey logo

config-finder's People

Contributors

urbanblight avatar

Watchers

 avatar  avatar

Forkers

jessebmiller

config-finder's Issues

Cannot use `/env` as a kubernetes secret mountPath

Third spot checked in finders.py is "some line in the file at /env" However, it seems to be impossible to mount a kubernetes secret at the filesystem root. For example, trying to create a pod like:

apiVersion: v1
kind: Pod
metadata:
  labels:
    name: secret-test
  name: secret-test
spec:
  containers:
  - image: alpine
    name: secret-test
    command:
        - "tail"
        - "-f"
        - "/dev/null"
    ports:
    - containerPort: 22
    volumeMounts:
    - mountPath: /
      name: env
  volumes:
  - name: env
    secret:
      secretName: test-secret

Leaves the pod in RunContainerError status, with the error message

Error syncing pod, skipping: failed to "StartContainer" for "secret-test" with RunContainerError: "runContainer: Error response from daemon: Invalid bind mount spec "/var/lib/kubelet/pods/03ea2d38-63d8-11e6-8479-ae880d866a65/volumes/kubernetes.iosecret/env:/": Invalid specification: destination can't be '/' in '/var/lib/kubelet/pods/03ea2d38-63d8-11e6-8479-ae880d866a65/volumes/kubernetes.iosecret/env:/'

If you change the spec.volumeMounts.mountPath in the above YAML to (say) /secret then it works as expected, although the config-finder would need to check /secret/env for config instead of /env

What if we checked the request for config options first?

If we were to use configuration to turn on and off feature flags, the client could make requests with certain features turned on for that single request.

could also get scary allowing clients to turn on say "everyone is admin" mode. So security would be a concern.

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.