Git Product home page Git Product logo

podman-machine-cni's Introduction

Deprecated

This repository is no longer maintained. The core logic has been merged into podman as of v4.0.

podman-machine-cni

This plugin collects the port information of the container and sends information to a server on the host operating system. The information is used by the server to open and close port mappings on the host. It is only meant to be used in a podman-machine virtual machine. The plugin can be enabled with the following stanza:

      {
         "type": "podman-machine",
         "capabilities": {
            "portMappings": true
         }
      },

The server in question is gvisor-tap-vsock. The plugin connects to the server via RESTful API calls on container start and stop (or die). The plugin converts the port data information into a JSON payload for the API endpoint. On container start, ports on the host are opened and mapped; on stop, they are closed.

podman-machine-cni's People

Contributors

baude avatar luap99 avatar mheon avatar rhatdan avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

podman-machine-cni's Issues

Don't hardcode host addr to 0.0.0.0

Right now this plugin sets the host addr for gvproxy to 0.0.0.0. This is the default for podman but it can be changed by a user. If you use -p 127.0.0.1:8080:80, gvproxy should only bind 127.0.0.1:8080 in this case. Adding support for this to the plugin is trivial the problem is that in the VM the actual port mapping into the container also tries to use the same host ip. This obviously conflicts, if 127.0.0.1 is also binded in the VM gvproxy cannot reach this addr from the host.

Generally speaking supporting the -p hostaddr:hostport:conport syntax correctly requires a lot of work in this plugin and podman. What needs to happen is that in the VM the host addr part will be ignored and only on the actual remote host applied.

udp port forwarding not working

This is blocked on containers/gvisor-tap-vsock#37. At the moment gvproxy cannot expose udp ports.

This plugin doesn't take the protocol into account and always exposes a tcp port even when udp was requested. Should this plugin error when udp was requested until gvproxy supports udp?

Testing

We need tests for this plugin.

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.