Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ziti edge service helper #1712

Open
wants to merge 19 commits into
base: release-next
Choose a base branch
from
Open

Conversation

gberl002
Copy link
Contributor

@gberl002 gberl002 commented Jan 29, 2024

Create the configs, service, and service policies for an endpoint using one cli command.

Example usages

Create dial and bind setup for localhost:1280 using tcp, the service is called myservice, with an endpoint at myservice.ziti (defaulted to servicename.ziti)
ziti edge secure myservice tcp:localhost:1280

Create dial and bind setup for localhost:1280 using tcp, the service is called myervice, with a custom endpoint at myendpoint.ziti
ziti edge secure myservice tcp:localhost:1280 --endpoint myendpoint.ziti

Create dial and bind setup for 127.0.0.1:1280 using "tcp,udp" protocols, the service is called myservice, with an endpoint at myservice.ziti. When not provided, allowed protocols defaults to both tcp and udp, and the assumed address is 127.0.0.1. At a minimum, port must always be provided.
ziti edge secure myservice 1280

Signed-off-by: gberl002 <geoff.berl@netfoundry.io>
Signed-off-by: gberl002 <geoff.berl@netfoundry.io>
Signed-off-by: gberl002 <geoff.berl@netfoundry.io>
Signed-off-by: gberl002 <geoff.berl@netfoundry.io>
closes #1663

Signed-off-by: gberl002 <geoff.berl@netfoundry.io>
Signed-off-by: gberl002 <geoff.berl@netfoundry.io>
Signed-off-by: gberl002 <geoff.berl@netfoundry.io>
Signed-off-by: gberl002 <geoff.berl@netfoundry.io>
Signed-off-by: gberl002 <geoff.berl@netfoundry.io>
Signed-off-by: gberl002 <geoff.berl@netfoundry.io>
…hare code

Signed-off-by: gberl002 <geoff.berl@netfoundry.io>
…review.

Signed-off-by: gberl002 <geoff.berl@netfoundry.io>
@gberl002 gberl002 requested review from a team as code owners January 29, 2024 14:32
Signed-off-by: gberl002 <geoff.berl@netfoundry.io>
Signed-off-by: gberl002 <geoff.berl@netfoundry.io>
@qrkourier qrkourier linked an issue Feb 22, 2024 that may be closed by this pull request
Signed-off-by: gberl002 <geoff.berl@netfoundry.io>
Signed-off-by: gberl002 <geoff.berl@netfoundry.io>
@@ -383,3 +384,18 @@ func waitForController(ctrlUrl string, done chan struct{}) {
}
done <- struct{}{}
}

func IsPortListening(host string, port int, timeout time.Duration) bool {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

function doesn't seem to be used?

Changing endpoint to intercept address

Signed-off-by: gberl002 <geoff.berl@netfoundry.io>
}

// Create a dial config
interceptAddress := svcName + ".ziti"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
interceptAddress := svcName + ".ziti"
interceptAddress := svcName + ".internal"

Provided an output summary with attribute and intercept details

Signed-off-by: gberl002 <geoff.berl@netfoundry.io>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

simplified service generation with a single command
3 participants