Merge pull request #992 from openziti/release-next

Release 0.27.3
This commit is contained in:
Paul Lorenz
2023-02-03 14:42:40 -05:00
committed by GitHub
87 changed files with 1647 additions and 3182 deletions
+1 -2
View File
@@ -1,4 +1,3 @@
# see:
# https://docs.github.com/en/github/creating-cloning-and-archiving-repositories/creating-a-repository-on-github/about-code-owners
* @openziti/sig-core
* @openziti/maintainers
* @openziti/sig-core @openziti/maintainers
+24 -55
View File
@@ -89,9 +89,8 @@ jobs:
fablab-smoketest:
name: Fablab Smoketest
if: github.repository_owner == 'openziti'
runs-on: ubuntu-20.04
outputs:
ZITI_VERSION: ${{ steps.get_version.outputs.ZITI_VERSION }}
steps:
- name: Git Checkout
uses: actions/checkout@v3
@@ -154,7 +153,7 @@ jobs:
# END linux-build-steps
publish:
name: Publish Binaries and Docker Image
name: Publish Binaries
runs-on: ubuntu-20.04
needs: [ mac-os-build, windows-build, fablab-smoketest ]
outputs:
@@ -193,6 +192,14 @@ jobs:
CC=arm-linux-gnueabihf-gcc $(go env GOPATH)/bin/gox -cgo -os=linux -arch=arm -output=$GOX_OUTPUT ./...
CC=aarch64-linux-gnu-gcc $(go env GOPATH)/bin/gox -cgo -os=linux -arch=arm64 -output=$GOX_OUTPUT ./...
# upload Linux artifacts so we can copy them into a container image in another workflow
- name: Upload artifacts
uses: actions/upload-artifact@v3
with:
name: linux-release-${{ github.run_id }}
path: release/
retention-days: 5
- name: Download darwin release artifact
uses: actions/download-artifact@v3
with:
@@ -210,9 +217,9 @@ jobs:
with:
version: 1.51.1
# remaining steps in job only run on the upstream repo, not forks
- name: Publish
if: github.repository_owner == 'openziti' && (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release-v'))
- name: Publish GitHub Release
# forks need to run this step with their own GPG key because ziti-ci creates the GH release
if: env.ziti_ci_gpg_key_id != null && (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release-v'))
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
ziti_ci_gpg_key: ${{ secrets.ZITI_CI_GPG_KEY }}
@@ -255,55 +262,6 @@ jobs:
JFROG_API_KEY: ${{ secrets.JFROG_API_KEY }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Set up QEMU
if: github.repository_owner == 'openziti' && (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release-v'))
uses: docker/setup-qemu-action@v2
with:
platforms: amd64,arm64,arm
- name: Set up Docker BuildKit
if: github.repository_owner == 'openziti' && (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release-v'))
id: buildx
uses: docker/setup-buildx-action@v2
- name: Login to Docker Hub
if: github.repository_owner == 'openziti' && (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release-v'))
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_HUB_API_USER }}
password: ${{ secrets.DOCKER_HUB_API_TOKEN }}
- name: Set up Docker image tags
if: github.repository_owner == 'openziti' && (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release-v'))
env:
SNAPSHOT_REPO: openziti/ziti-tunnel
RELEASE_REPO: netfoundry/ziti-tunnel
ZITI_VERSION: ${{ steps.get_version.outputs.ZITI_VERSION }}
id: tagprep
run: |
# the Docker cross-build only runs on branches main or release-v*
# where ziti-ci always computes and publishes a new release tag
DOCKER_TAGS=""
for REPO in ${SNAPSHOT_REPO} ${RELEASE_REPO}; do
DOCKER_TAGS+=",${REPO}:${ZITI_VERSION},${REPO}:latest"
done
DOCKER_TAGS=${DOCKER_TAGS#,} # drop leading comma char
echo "DEBUG: DOCKER_TAGS=${DOCKER_TAGS}"
echo DOCKER_TAGS="${DOCKER_TAGS}" >> $GITHUB_OUTPUT
- name: Build & Push Multi-Platform Container Image to Hub
if: github.repository_owner == 'openziti' && (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release-v'))
uses: docker/build-push-action@v3
with:
builder: ${{ steps.buildx.outputs.name }}
context: ${{ github.workspace }} # build context is workspace so we can copy artifacts from ./release
file: ${{ github.workspace }}/ziti-tunnel/docker/Dockerfile.copy # a Dockerfile that does copy instead of fetch
build-args: | # base dir for copy/add operations should be dir containing Dockerfile
DOCKER_BUILD_DIR=./ziti-tunnel/docker
platforms: linux/amd64,linux/arm/v7,linux/arm64
push: true
tags: ${{ steps.tagprep.outputs.DOCKER_TAGS }}
jenkins-smoketest:
# BEGIN smoketest-job
#
@@ -311,7 +269,18 @@ jobs:
#
needs: publish
name: Call the On-Demand Smoketest Workflow
# not applicable to forks
if: github.repository_owner == 'openziti'
uses: ./.github/workflows/jenkins-smoketest.yml
secrets: inherit
with:
ziti-version: ${{ needs.publish.outputs.ZITI_VERSION }}
call-publish-docker-images:
if: github.ref == 'refs/heads/main'
name: Publish Docker Images
needs: publish
uses: ./.github/workflows/publish-docker-images.yml
secrets: inherit
with:
ziti-version: ${{ needs.publish.outputs.ZITI_VERSION }}
+1 -1
View File
@@ -15,7 +15,7 @@ jobs:
mattermost-ziti-webhook:
runs-on: ubuntu-latest
name: POST Webhook
if: github.actor != 'dependabot[bot]'
if: github.repository_owner == 'openziti' && github.actor != 'dependabot[bot]'
env:
ZITI_LOG: 99
ZITI_NODEJS_LOG: 99
+134
View File
@@ -0,0 +1,134 @@
name: CI build
on:
workflow_call:
inputs:
ziti-version:
description: 'Ziti Release Version'
type: string
required: true
jobs:
publish-docker-images:
runs-on: ubuntu-latest
env:
ZITI_VERSION: ${{ inputs.ziti-version || github.event.inputs.ziti-version }}
steps:
- name: Checkout Workspace
uses: actions/checkout@v3
- name: Download Linux Release Artifacts
uses: actions/download-artifact@v3
with:
name: linux-release-${{ github.run_id }}
path: release/
- name: Set Up QEMU
uses: docker/setup-qemu-action@v2
with:
platforms: amd64,arm64
- name: Set Up Docker BuildKit
id: buildx
uses: docker/setup-buildx-action@v2
- name: Login to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_HUB_API_USER }}
password: ${{ secrets.DOCKER_HUB_API_TOKEN }}
- name: Set Up Container Image Tags for Base CLI Container
env:
RELEASE_REPO: openziti/ziti-cli
id: tagprep_cli
run: |
DOCKER_TAGS=""
DOCKER_TAGS="${RELEASE_REPO}:${ZITI_VERSION},${RELEASE_REPO}:latest"
echo "DEBUG: DOCKER_TAGS=${DOCKER_TAGS}"
echo DOCKER_TAGS="${DOCKER_TAGS}" >> $GITHUB_OUTPUT
# this is the base image into which is stuffed the Linux binary for each
# arch that was downloaded in ./release/, hence the need to specify the
# Dockerfile and DOCKER_BUILD_DIR
- name: Build & Push Multi-Platform CLI Container Image to Hub
uses: docker/build-push-action@v3
with:
builder: ${{ steps.buildx.outputs.name }}
context: ${{ github.workspace }}/
file: ${{ github.workspace }}/docker-images/ziti-cli/Dockerfile
platforms: linux/amd64,linux/arm64
tags: ${{ steps.tagprep_cli.outputs.DOCKER_TAGS }}
build-args: |
DOCKER_BUILD_DIR=./docker-images/ziti-cli
push: true
- name: Set Up Container Image Tags for Controller Container
env:
RELEASE_REPO: openziti/ziti-controller
id: tagprep_ctrl
run: |
DOCKER_TAGS=""
DOCKER_TAGS="${RELEASE_REPO}:${ZITI_VERSION},${RELEASE_REPO}:latest"
echo "DEBUG: DOCKER_TAGS=${DOCKER_TAGS}"
echo DOCKER_TAGS="${DOCKER_TAGS}" >> $GITHUB_OUTPUT
# This is a use-case image based on the minimal CLI image. It needs the
# ZITI_VERSION env var so it can build from the versioned image that
# we pushed in the prior step.
- name: Build & Push Multi-Platform Controller Container Image to Hub
uses: docker/build-push-action@v3
with:
builder: ${{ steps.buildx.outputs.name }}
context: ${{ github.workspace }}/docker-images/ziti-controller/
platforms: linux/amd64,linux/arm64
tags: ${{ steps.tagprep_ctrl.outputs.DOCKER_TAGS }}
build-args: |
ZITI_VERSION=${{ env.ZITI_VERSION }}
push: true
- name: Set Up Container Image Tags for Router Container
env:
RELEASE_REPO: openziti/ziti-router
id: tagprep_router
run: |
DOCKER_TAGS=""
DOCKER_TAGS="${RELEASE_REPO}:${ZITI_VERSION},${RELEASE_REPO}:latest"
echo "DEBUG: DOCKER_TAGS=${DOCKER_TAGS}"
echo DOCKER_TAGS="${DOCKER_TAGS}" >> $GITHUB_OUTPUT
- name: Build & Push Multi-Platform Router Container Image to Hub
uses: docker/build-push-action@v3
with:
builder: ${{ steps.buildx.outputs.name }}
context: ${{ github.workspace }}/docker-images/ziti-router/
platforms: linux/amd64,linux/arm64
tags: ${{ steps.tagprep_router.outputs.DOCKER_TAGS }}
build-args: |
ZITI_VERSION=${{ env.ZITI_VERSION }}
push: true
- name: Set Up Container Image Tags for Go Tunneler Container
env:
SNAPSHOT_REPO: netfoundry/ziti-tunnel
RELEASE_REPO: openziti/ziti-tunnel
id: tagprep_tun
run: |
DOCKER_TAGS=""
for REPO in ${SNAPSHOT_REPO} ${RELEASE_REPO}; do
DOCKER_TAGS+=",${REPO}:${ZITI_VERSION},${REPO}:latest"
done
DOCKER_TAGS=${DOCKER_TAGS#,} # drop leading comma char
echo "DEBUG: DOCKER_TAGS=${DOCKER_TAGS}"
echo DOCKER_TAGS="${DOCKER_TAGS}" >> $GITHUB_OUTPUT
- name: Build & Push Multi-Platform Go Tunneler Container Image to Hub
uses: docker/build-push-action@v3
with:
builder: ${{ steps.buildx.outputs.name }}
context: ${{ github.workspace }}/docker-images/ziti-tunnel/
platforms: linux/amd64,linux/arm64
tags: ${{ steps.tagprep_tun.outputs.DOCKER_TAGS }}
build-args: |
ZITI_VERSION=${{ env.ZITI_VERSION }}
push: true
+1 -1
View File
@@ -22,4 +22,4 @@ Here's the list of projects using and adopting OpenZiti
|---------------------------|-----------------------------------------------|----------|-----------------|
| NetFoundry | https://nfconsole.io/signup | <img src="https://netfoundry.io/logos/Logo-Dark-Backgrounds.jpg" width="100px"> | NetFoundry SaaS provides management, orchestrations, support, and SLAs for OpenZiti networks. |
| HackBunker | https://www.hackbunker.com/ | <img src="https://irp.cdn-website.com/b429ad92/dms3rep/multi/hackbunker+logo+new.svg" width="100px"> | To open up a Zero Trust conversation in the C-Suite and Boardrooms of Blue-chip companies with a suite of products. |
| DeltaSecure GmbH | https://deltasecure.de/ | <img src="https://deltasecure.de/wp-content/uploads/2022/10/DeltaSecure-Logo-gross-hell.png.png" width="100px"> | To provide Managed Security Operations Center services for small and medium-sized enterprises. Ziti overlay forms the basis for secure data transmission of customer data and within the SOC infrastructure. |
+35 -1
View File
@@ -1,6 +1,40 @@
# Release 0.27.3
## What's New
* Docker images for `ziti` CLI
* New Raft interaction commands
* `raft-leave` allows removal of controllers from the raft cluster
* `raft-list` lists all connected controllers and their version/connected status
* `fabric raft list-members` same info as the agent command, but over rest
## Component Updates and Bug Fixes
* github.com/openziti/agent: [v1.0.7 -> v1.0.8](https://github.com/openziti/agent/compare/v1.0.7...v1.0.8)
* github.com/openziti/channel/v2: [v2.0.25 -> v2.0.26](https://github.com/openziti/channel/compare/v2.0.25...v2.0.26)
* github.com/openziti/edge: [v0.24.95 -> v0.24.115](https://github.com/openziti/edge/compare/v0.24.95...v0.24.115)
* [Issue #1292](https://github.com/openziti/edge/issues/1292) - Support alternative tproxy configuration methods
* github.com/openziti/edge-api: v0.25.6 (new)
* github.com/openziti/fabric: [v0.22.7 -> v0.22.19](https://github.com/openziti/fabric/compare/v0.22.7...v0.22.19)
* [Issue #592](https://github.com/openziti/fabric/issues/592) - Incoming "gateway" connections should be logged at a socket level
* [Issue #588](https://github.com/openziti/fabric/issues/588) - Make service events more consistent
* [Issue #589](https://github.com/openziti/fabric/issues/589) - Add duration to circuit updated and deleted events
* [Issue #508](https://github.com/openziti/fabric/issues/508) - Refactor router debug ops for multiple controllers
* github.com/openziti/identity: [v1.0.29 -> v1.0.30](https://github.com/openziti/identity/compare/v1.0.29...v1.0.30)
* github.com/openziti/runzmd: [v1.0.7 -> v1.0.9](https://github.com/openziti/runzmd/compare/v1.0.7...v1.0.9)
* github.com/openziti/sdk-golang: [v0.18.21 -> v0.18.26](https://github.com/openziti/sdk-golang/compare/v0.18.21...v0.18.26)
* github.com/openziti/storage: [v0.1.31 -> v0.1.33](https://github.com/openziti/storage/compare/v0.1.31...v0.1.33)
* github.com/openziti/transport/v2: [v2.0.49 -> v2.0.50](https://github.com/openziti/transport/compare/v2.0.49...v2.0.50)
* github.com/openziti/ziti: [v0.27.2 -> v0.27.3](https://github.com/openziti/ziti/compare/v0.27.2...v0.27.3)
* [Issue #974](https://github.com/openziti/ziti/issues/974) - tunnel "host" and "proxy" modes shouldn't run the nameserver
* [Issue #972](https://github.com/openziti/ziti/issues/972) - tunnel segfault
# Release 0.27.2
# What's New
## What's New
* Bug fixes
+26 -22
View File
@@ -1,6 +1,10 @@
# Ziti
[![Build Status](https://github.com/openziti/ziti/actions/workflows/main.yml/badge.svg)](https://github.com/openziti/ziti/actions/workflows/main.yml)
[![Go Report Card](https://goreportcard.com/badge/github.com/openziti/ziti)](https://goreportcard.com/report/github.com/openziti/ziti)
![OpenZiti Logo](https://raw.githubusercontent.com/openziti/ziti-doc/main/docusaurus/static/img/ziti-logo-dark.svg)
Ziti represents the next generation of secure, open-source networking for your applications. Ziti has several components.
# OpenZiti
OpenZiti represents the next generation of secure, open-source networking for your applications. OpenZiti has several components.
## Quick Reference
@@ -17,8 +21,8 @@ Ziti represents the next generation of secure, open-source networking for your a
* The OpenZiti fabric provides a scalable, plugable, networking mesh with built in smart routing
* The OpenZiti edge components provide a secure, Zero Trust entry point into your network
* The OpenZiti SDKs allow you to integrate Ziti directly into your applications
* The OpenZiti tunnelers and proxies allow existing applications and networks to take advantage of a Ziti deployment
* The OpenZiti SDKs allow you to integrate OpenZiti directly into your applications
* The OpenZiti tunnelers and proxies allow existing applications and networks to take advantage of a OpenZiti deployment
### Security Features
@@ -56,11 +60,11 @@ Let's break some of these buzzwords down.
Many networking security solutions act like a wall around an internal network. Once you are through the wall, you have access to everything inside. Zero trust solutions enforce not just access to a network, but access to individual applications within that network.
Every client in a Ziti system must have an identity with provisioned certificates. The certificates are used to establish secure communications channels as well as for authentication and authorization of the associated identity. Whenever the client attempts to access a network application, Ziti will first ensure that the identity has access to the application. If access is revoked, open network connections will be closed.
Every client in a OpenZiti system must have an identity with provisioned certificates. The certificates are used to establish secure communications channels as well as for authentication and authorization of the associated identity. Whenever the client attempts to access a network application, OpenZiti will first ensure that the identity has access to the application. If access is revoked, open network connections will be closed.
This model enables Ziti systems to provide access to multiple applications while ensuring that clients only get access to those applications to which they have been granted access.
This model enables OpenZiti systems to provide access to multiple applications while ensuring that clients only get access to those applications to which they have been granted access.
In addition to requiring cert based authentication for clients, Ziti uses certificates to authorize communication between Ziti components.
In addition to requiring cert based authentication for clients, OpenZiti uses certificates to authorize communication between OpenZiti components.
### Dark Services and Routers
@@ -74,15 +78,15 @@ There are various levels of accessibility a network application/service can have
1. For end users, VPNs add an extra step that needs to be done each time they want to access the service.
1. Services can be made dark, meaning they do not have any ports open for anyone to even try and connect to.
Making something dark can be done in a few ways, but the way it's generally handled in Ziti is that services reach out and establish one or more connections to the Ziti network fabric. Clients coming into the fabric can then reach the service through these connections after being authenticated and authorized.
Making something dark can be done in a few ways, but the way it's generally handled in OpenZiti is that services reach out and establish one or more connections to the OpenZiti network fabric. Clients coming into the fabric can then reach the service through these connections after being authenticated and authorized.
Ziti routers, which make up the fabric, can also be dark. Routers located in private networks will usually be made dark. These routers will reach out of the private network to talk to the controller and to make connections to join the network fabric mesh. This allows the services and routers in your private networks to make only outbound connections, so no holes have to be opened for inbound traffic.
OpenZiti routers, which make up the fabric, can also be dark. Routers located in private networks will usually be made dark. These routers will reach out of the private network to talk to the controller and to make connections to join the network fabric mesh. This allows the services and routers in your private networks to make only outbound connections, so no holes have to be opened for inbound traffic.
Services can be completely dark if they are implemented with a Ziti SDK. If this is not possible a Ziti tunneler or proxy can be colocated with the service. The service then only needs to allow connections from the local machine or network, depending on how close you colocate the proxy to the service.
Services can be completely dark if they are implemented with a OpenZiti SDK. If this is not possible a OpenZiti tunneler or proxy can be colocated with the service. The service then only needs to allow connections from the local machine or network, depending on how close you colocate the proxy to the service.
### End to End Encryption
If you take advantage of Ziti's developer SDKs and embed Ziti in your client and server applications, your traffic can be configured to be seamlessly encrypted from the client application to server application. If you prefer to use tunnelers or proxy applications, the traffic can be encrypted for you from machine to machine or private network to private network. Various combinations of the above are also supported.
If you take advantage of OpenZiti's developer SDKs and embed OpenZiti in your client and server applications, your traffic can be configured to be seamlessly encrypted from the client application to server application. If you prefer to use tunnelers or proxy applications, the traffic can be encrypted for you from machine to machine or private network to private network. Various combinations of the above are also supported.
End-to-end encryption means that even if systems between the client and server are compromised, your traffic cannot be decrypted or tampered with.
@@ -94,7 +98,7 @@ If you are looking to jump right in feet first you can follow along with one of
guides](https://openziti.github.io/ziti/quickstarts/quickstart-overview.html). These guides are designed to get an
overlay network quickly and allow you to run it all locally, use Docker or host it anywhere.
This environment is perfect for evaluators to get to know Ziti and the capabilities it offers. The environment was not
This environment is perfect for evaluators to get to know OpenZiti and the capabilities it offers. The environment was not
designed for large scale deployment or for long-term usage. If you are looking for a managed service to help you run a
truly global, scalable network browse over [the NetFoundry web site](https://netfoundry.io) to learn more.
@@ -121,21 +125,21 @@ cruise on over to [the OpenZiti Discourse forum](https://openziti.discourse.grou
### Contributing
The Ziti project welcomes contributions including, but not limited to, code, documentation and bug reports.
The OpenZiti project welcomes contributions including, but not limited to, code, documentation and bug reports.
* All Ziti code is found on Github under the [OpenZiti](https://github.com/openziti) organization.
* [ziti](https://github.com/openziti/ziti): top level project which builds all Ziti executables
* All OpenZiti code is found on Github under the [OpenZiti](https://github.com/openziti) organization.
* [ziti](https://github.com/openziti/ziti): top level project which builds all OpenZiti executables
* [edge](https://github.com/openziti/edge): edge components and model which includes identity, polices and config
* [fabric](https://github.com/openziti/fabric): fabric project which includes core controller and router
* [foundation](https://github.com/openziti/foundation): project which contains library code used across multiple projects
* SDKs
* [ziti-sdk-c] (https://github.com/openziti/ziti-sdk-c): C SDK
* [sdk-golang] (https://github.com/openziti/sdk-golang): Go SDK
* [ziti-sdk-jvm] (https://github.com/openziti/ziti-sdk-jvm): SDK for JVM based languages
* [ziti-sdk-swift] (https://github.com/openziti/ziti-sdk-swift): Swift SDK
* [ziti-sdk-nodejs] (https://github.com/openziti/ziti-sdk-nodejs): NodeJS SDK
* [ziti-sdk-csharp] (https://github.com/openziti/ziti-sdk-csharp): C# SDK
* [ziti-sdk-c](https://github.com/openziti/ziti-sdk-c): C SDK
* [sdk-golang](https://github.com/openziti/sdk-golang): Go SDK
* [ziti-sdk-jvm](https://github.com/openziti/ziti-sdk-jvm): SDK for JVM based languages
* [ziti-sdk-swift](https://github.com/openziti/ziti-sdk-swift): Swift SDK
* [ziti-sdk-nodejs](https://github.com/openziti/ziti-sdk-nodejs): NodeJS SDK
* [ziti-sdk-csharp](https://github.com/openziti/ziti-sdk-csharp): C# SDK
* [ziti-doc](https://github.com/openziti/ziti-doc): Powers the static documentation site
Ziti was developed and open sourced by [Netfoundry, Inc](https://netfoundry.io). NetFoundry continues to fund and
OpenZiti was developed and open sourced by [Netfoundry, Inc](https://netfoundry.io). NetFoundry continues to fund and
contribute to OpenZiti.
+2 -2
View File
@@ -1,8 +1,6 @@
v: 3
raft:
minClusterSize: 3
advertiseAddress: tls:localhost:6262
dataDir: ./data/ctrl1
bootstrapMembers:
- tls:127.0.0.1:6363
@@ -15,6 +13,8 @@ identity:
ctrl:
listener: tls:127.0.0.1:6262
options:
advertiseAddress: tls:localhost:6262
healthChecks:
boltCheck:
+2 -1
View File
@@ -2,7 +2,6 @@ v: 3
raft:
minClusterSize: 3
advertiseAddress: tls:localhost:6363
dataDir: ./data/ctrl2
identity:
@@ -12,6 +11,8 @@ identity:
ctrl:
listener: tls:127.0.0.1:6363
options:
advertiseAddress: tls:localhost:6363
healthChecks:
boltCheck:
+2 -1
View File
@@ -2,7 +2,6 @@ v: 3
raft:
minClusterSize: 3
advertiseAddress: tls:localhost:6464
dataDir: ./data/ctrl3
identity:
@@ -12,6 +11,8 @@ identity:
ctrl:
listener: tls:127.0.0.1:6464
options:
advertiseAddress: tls:localhost:6464
healthChecks:
boltCheck:
+54
View File
@@ -0,0 +1,54 @@
# this Dockerfile builds docker.io/openziti/ziti-cli
# get kubectl CLI from a source with Docker Content Trust (DCT)
# FIXME: require DCT at build time
FROM bitnami/kubectl as bitnami-kubectl
# FIXME: This repo requires terms acceptance and is only available on registry.redhat.io.
# FROM registry.access.redhat.com/openshift4/ose-cli as openshift-cli
FROM registry.access.redhat.com/ubi8/ubi-minimal
# This build stage grabs artifacts that are copied into the final image.
# It uses the same base as the final image to maximize docker cache hits.
ARG ARTIFACTS_DIR=./release
ARG DOCKER_BUILD_DIR=.
# e.g. linux
ARG TARGETOS
# e.g. arm64
ARG TARGETARCH
### Required OpenShift Labels
LABEL name="openziti/ziti-cli" \
maintainer="developers@openziti.org" \
vendor="NetFoundry" \
summary="Run the OpenZiti CLI" \
description="Run the OpenZiti CLI"
USER root
### install packages
RUN INSTALL_PKGS="python38 python38-pip" && \
microdnf -y update --setopt=install_weak_deps=0 --setopt=tsflags=nodocs && \
microdnf -y install --setopt=install_weak_deps=0 --setopt=tsflags=nodocs ${INSTALL_PKGS}
### install OpenShift CLI (oc)
# FIXME: This repo requires terms acceptance and is only available on registry.redhat.io.
# COPY --from=openshift-cli /path/to/oc /usr/local/bin/oc
### install Kubernetes CLI
COPY --from=bitnami-kubectl /opt/bitnami/kubectl/bin/kubectl /usr/local/bin/
### add license in the path prescribed by OpenShift
RUN mkdir -m0755 /licenses
COPY ./LICENSE /licenses/apache.txt
RUN mkdir -p /usr/local/bin
COPY ${ARTIFACTS_DIR}/${TARGETARCH}/${TARGETOS}/ziti /usr/local/bin/
RUN chmod 0755 /usr/local/bin/ziti
COPY ${DOCKER_BUILD_DIR}/entrypoint.sh /
RUN chmod +x /entrypoint.sh
USER nobody
ENTRYPOINT [ "/entrypoint.sh" ]
CMD [ "ziti" ]
+5
View File
@@ -0,0 +1,5 @@
#!/usr/bin/env bash
set -euo pipefail
exec ziti "${@}"
+20
View File
@@ -0,0 +1,20 @@
ARG ZITI_VERSION="latest"
# this builds docker.io/openziti/ziti-controller
FROM docker.io/openziti/ziti-cli:${ZITI_VERSION}
# This build stage grabs artifacts that are copied into the final image.
# It uses the same base as the final image to maximize docker cache hits.
### Required OpenShift Labels
LABEL name="openziti/ziti-controller" \
maintainer="developers@openziti.org" \
vendor="NetFoundry" \
summary="Run the OpenZiti Controller" \
description="Run the OpenZiti Controller"
USER root
COPY ./entrypoint.sh /
RUN chmod +x /entrypoint.sh
USER nobody
ENTRYPOINT [ "/entrypoint.sh" ]
CMD [ "run" ]
@@ -0,0 +1,5 @@
#!/usr/bin/env bash
set -euo pipefail
exec ziti controller "${@}"
+20
View File
@@ -0,0 +1,20 @@
ARG ZITI_VERSION="latest"
# this builds docker.io/openziti/ziti-router
FROM docker.io/openziti/ziti-cli:${ZITI_VERSION}
# This build stage grabs artifacts that are copied into the final image.
# It uses the same base as the final image to maximize docker cache hits.
### Required OpenShift Labels
LABEL name="openziti/ziti-router" \
maintainer="developers@openziti.org" \
vendor="NetFoundry" \
summary="Run the OpenZiti Router" \
description="Run the OpenZiti Router"
USER root
COPY ./entrypoint.sh /
RUN chmod +x /entrypoint.sh
USER nobody
ENTRYPOINT [ "/entrypoint.sh" ]
CMD [ "run" ]
+5
View File
@@ -0,0 +1,5 @@
#!/usr/bin/env bash
set -euo pipefail
exec ziti router "${@}"
+24
View File
@@ -0,0 +1,24 @@
ARG ZITI_VERSION="latest"
# this builds docker.io/openziti/ziti-tunnel, the legacy tunneler. The preferred tunneler is openziti/ziti-edge-tunnel documented in https://docs.openziti.io/docs/reference/tunnelers/linux/container/
FROM docker.io/openziti/ziti-cli:${ZITI_VERSION}
# This build stage grabs artifacts that are copied into the final image.
# It uses the same base as the final image to maximize docker cache hits.
### Required OpenShift Labels
LABEL name="openziti/ziti-tunnel" \
maintainer="developers@openziti.org" \
vendor="NetFoundry" \
summary="Run the OpenZiti Go Tunneler" \
description="Run the OpenZiti Go Tunneler"
### Add necessary Red Hat repos and packages: "mountpoint" used by entrypoint
USER root
RUN INSTALL_PKGS="util-linux iptables" && \
microdnf -y update --setopt=install_weak_deps=0 --setopt=tsflags=nodocs && \
microdnf -y install --setopt=install_weak_deps=0 --setopt=tsflags=nodocs ${INSTALL_PKGS}
COPY ./entrypoint.sh /
RUN chmod +x /entrypoint.sh
ENTRYPOINT [ "/entrypoint.sh" ]
CMD [ "run" ]
+165
View File
@@ -0,0 +1,165 @@
#!/usr/bin/env bash
#
# Copyright 2023 NetFoundry Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
set -e -u -o pipefail
function alldone() {
# if successfully sent to background then send SIGTERM to trigger a cleanup
# of resolver config, tun devices and associated routes
[[ "${ZITI_TUNNEL_PID:-}" =~ ^[0-9]+$ ]] && {
kill -TERM "$ZITI_TUNNEL_PID"
# let entrypoint script exit after ziti tunnel PID
kill -0 "$ZITI_TUNNEL_PID" && wait "$ZITI_TUNNEL_PID"
}
}
trap alldone SIGTERM SIGINT EXIT
IDENTITIES_DIR="/netfoundry"
if ! [[ -d "${IDENTITIES_DIR}" ]]; then
echo "ERROR: need directory ${IDENTITIES_DIR} to find tokens and identities" >&2
exit 1
fi
if ! mountpoint "${IDENTITIES_DIR}" &>/dev/null; then
echo "WARN: the identities directory is only available inside this container because ${IDENTITIES_DIR} is not a mounted volume. Be careful to not publish this image with identity inside or lose access to the identity by removing the image prematurely." >&2
else
if [[ -n "${ZITI_IDENTITY_JSON:-}" ]]; then
echo "WARNING: you supplied the Ziti identity as an env var and you mounted a volume on the identities dir. You may avoid this warning and future errors by not mounting a volume on ${IDENTITIES_DIR} when ZITI_IDENTITY_JSON is defined." >&2
fi
fi
#
## Map the preferred, Ziti var names to legacy NF names. This allows us to begin using the preferred vars right away
## while minimizing immediate differences to the main control structure. This eases code review. Later, the legacy
## names can be retired and replaced.
#
if [[ -n "${ZITI_IDENTITY_BASENAME:-}" ]]; then
echo "INFO: setting NF_REG_NAME to \${ZITI_IDENTITY_BASENAME} (${ZITI_IDENTITY_BASENAME})"
NF_REG_NAME="${ZITI_IDENTITY_BASENAME}"
fi
if [[ -n "${ZITI_ENROLL_TOKEN:-}" ]]; then
echo "INFO: setting NF_REG_TOKEN to \${ZITI_ENROLL_TOKEN} (${ZITI_ENROLL_TOKEN})"
NF_REG_TOKEN="${ZITI_ENROLL_TOKEN}"
fi
if [[ -n "${ZITI_IDENTITY_WAIT:-}" ]]; then
echo "INFO: setting NF_REG_WAIT to \${ZITI_IDENTITY_WAIT} (${ZITI_IDENTITY_WAIT})"
NF_REG_WAIT="${ZITI_IDENTITY_WAIT}"
fi
# treat IOTEDGE_DEVICEID, a standard var assigned by Azure IoT, as an alias for NF_REG_NAME
if [[ -z "${NF_REG_NAME:-}" ]]; then
if [[ -n "${IOTEDGE_DEVICEID:-}" ]]; then
echo "INFO: setting NF_REG_NAME to \${IOTEDGE_DEVICEID} (${IOTEDGE_DEVICEID})"
NF_REG_NAME="${IOTEDGE_DEVICEID}"
fi
fi
# if identity JSON var is defined then write to a file
if [[ -n "${ZITI_IDENTITY_JSON:-}" ]]; then
# if the basename is not defined then use a default basename to write JSON to a file
if [[ -z "${NF_REG_NAME:-}" ]]; then
NF_REG_NAME="ziti_id"
fi
if [[ -s "${IDENTITIES_DIR}/${NF_REG_NAME}.json" ]]; then
echo "ERROR: refusing to clobber non-empty Ziti identity file ${NF_REG_NAME}.json with contents of env var ZITI_IDENTITY_JSON!" >&2
exit 1
else
echo "${ZITI_IDENTITY_JSON}" > "${IDENTITIES_DIR}/${NF_REG_NAME}.json"
fi
fi
typeset -a TUNNEL_OPTS
# if identity file, else multiple identities dir
if [[ -n "${NF_REG_NAME:-}" ]]; then
IDENTITY_FILE="${IDENTITIES_DIR}/${NF_REG_NAME}.json"
TUNNEL_OPTS=("--identity" "${IDENTITY_FILE}")
: ${NF_REG_WAIT:=1}
if [[ "${NF_REG_WAIT}" =~ ^[0-9]+$ ]]; then
echo "DEBUG: waiting ${NF_REG_WAIT}s for ${IDENTITY_FILE} (or token) to appear"
elif (( "${NF_REG_WAIT}" < 0 )); then
echo "DEBUG: waiting forever for ${IDENTITY_FILE} (or token) to appear"
else
echo "ERROR: need integer for NF_REG_WAIT" >&2
exit 1
fi
while (( $NF_REG_WAIT > 0 || $NF_REG_WAIT < 0)); do
# if non-empty identity file
if [[ -s "${IDENTITY_FILE}" ]]; then
echo "INFO: found identity file ${IDENTITY_FILE}"
break 1
# look for enrollment token
else
echo "INFO: identity file ${IDENTITY_FILE} does not exist"
for dir in "/var/run/secrets/netfoundry.io/enrollment-token" \
"/enrollment-token" \
"${IDENTITIES_DIR}"; do
JWT_CANDIDATE="${dir}/${NF_REG_NAME}.jwt"
echo "INFO: looking for ${JWT_CANDIDATE}"
if [[ -s "${JWT_CANDIDATE}" ]]; then
JWT_FILE="${JWT_CANDIDATE}"
break 1
fi
done
if [[ -n "${JWT_FILE:-}" ]]; then
echo "INFO: enrolling ${JWT_FILE}"
ziti edge enroll --jwt "${JWT_FILE}" --out "${IDENTITY_FILE}" || {
echo "ERROR: failed to enroll with token from ${JWT_FILE} ($(wc -c < "${JWT_FILE}")B)" >&2
exit 1
}
elif [[ -n "${NF_REG_TOKEN:-}" ]]; then
echo "INFO: attempting enrollment with NF_REG_TOKEN"
if [[ -s "${IDENTITIES_DIR}/${NF_REG_NAME}.jwt" ]]; then
echo "ERROR: refusing to clobber non-empty enrollment OTP file ${NF_REG_NAME}.jwt with contents of env var NF_REG_TOKEN!" >&2
exit 1
else
echo "${NF_REG_TOKEN}" > "${IDENTITIES_DIR}/${NF_REG_NAME}.jwt"
fi
ziti edge enroll --jwt "${IDENTITIES_DIR}/${NF_REG_NAME}.jwt" --out "${IDENTITY_FILE}" || {
echo "ERROR: failed to enroll with token from NF_REG_TOKEN ($(wc -c <<<"${NF_REG_TOKEN}")B)" >&2
exit 1
}
fi
fi
# decrement the wait seconds until zero or forever if negative
(( NF_REG_WAIT-- ))
sleep 1
done
else
typeset -a JSON_FILES
mapfile -t JSON_FILES < <(ls -1 "${IDENTITIES_DIR}"/*.json)
if [[ ${#JSON_FILES[*]} -gt 0 ]]; then
echo "INFO: NF_REG_NAME not set, loading ${#JSON_FILES[*]} identities from ${IDENTITIES_DIR}"
TUNNEL_OPTS=("--identity-dir" "${IDENTITIES_DIR}")
else
echo "ERROR: NF_REG_NAME not set and zero identities found in ${IDENTITIES_DIR}" >&2
exit 1
fi
fi
echo "DEBUG: evaluating positionals: $*"
if (( ${#} )) && [[ ${1} =~ t?proxy|host ]]; then
TUNNEL_RUN_MODE=${1}
shift
else
TUNNEL_RUN_MODE=run
fi
echo "INFO: running \"ziti tunnel ${TUNNEL_RUN_MODE} ${TUNNEL_OPTS[*]} ${*}\""
ziti tunnel "${TUNNEL_RUN_MODE}" "${TUNNEL_OPTS[@]}" "${@}" &
ZITI_TUNNEL_PID=$!
wait $ZITI_TUNNEL_PID
+25 -24
View File
@@ -8,7 +8,7 @@ require (
github.com/MakeNowJust/heredoc v1.0.0
github.com/blang/semver v3.5.1+incompatible
github.com/docker/docker v20.10.21+incompatible
github.com/fatih/color v1.13.0
github.com/fatih/color v1.14.1
github.com/fullsailor/pkcs7 v0.0.0-20190404230743-d7302db945fa
github.com/go-acme/lego/v4 v4.2.0
github.com/go-openapi/runtime v0.25.0
@@ -20,29 +20,30 @@ require (
github.com/jedib0t/go-pretty/v6 v6.4.0
github.com/keybase/go-ps v0.0.0-20190827175125-91aafc93ba19
github.com/michaelquigley/pfxlog v0.6.9
github.com/openziti/agent v1.0.7
github.com/openziti/channel/v2 v2.0.25
github.com/openziti/edge v0.24.95
github.com/openziti/fabric v0.22.7
github.com/openziti/agent v1.0.8
github.com/openziti/channel/v2 v2.0.26
github.com/openziti/edge v0.24.115
github.com/openziti/edge-api v0.25.6
github.com/openziti/fabric v0.22.19
github.com/openziti/foundation/v2 v2.0.10
github.com/openziti/identity v1.0.29
github.com/openziti/runzmd v1.0.7
github.com/openziti/sdk-golang v0.18.21
github.com/openziti/storage v0.1.31
github.com/openziti/transport/v2 v2.0.49
github.com/openziti/identity v1.0.30
github.com/openziti/runzmd v1.0.9
github.com/openziti/sdk-golang v0.18.26
github.com/openziti/storage v0.1.33
github.com/openziti/transport/v2 v2.0.50
github.com/openziti/xweb/v2 v2.0.2
github.com/openziti/ziti-db-explorer v1.1.1
github.com/pborman/uuid v1.2.0
github.com/pkg/errors v0.9.1
github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475
github.com/russross/blackfriday v1.5.2
github.com/shirou/gopsutil/v3 v3.22.12
github.com/shirou/gopsutil/v3 v3.23.1
github.com/sirupsen/logrus v1.9.0
github.com/spf13/cobra v1.6.1
github.com/spf13/pflag v1.0.5
github.com/spf13/viper v1.10.0
github.com/stretchr/testify v1.8.1
go.etcd.io/bbolt v1.3.6
go.etcd.io/bbolt v1.3.7
golang.org/x/net v0.5.0
google.golang.org/grpc v1.42.0
google.golang.org/protobuf v1.28.1
@@ -73,10 +74,10 @@ require (
github.com/dgryski/dgoogauth v0.0.0-20190221195224-5a805980a5f3 // indirect
github.com/dineshappavoo/basex v0.0.0-20170425072625-481a6f6dc663 // indirect
github.com/disintegration/imaging v1.6.2 // indirect
github.com/dlclark/regexp2 v1.7.0 // indirect
github.com/dlclark/regexp2 v1.8.0 // indirect
github.com/docker/distribution v2.8.1+incompatible // indirect
github.com/docker/go-connections v0.4.0 // indirect
github.com/docker/go-units v0.4.0 // indirect
github.com/docker/go-units v0.5.0 // indirect
github.com/ef-ds/deque v1.0.4 // indirect
github.com/eliukblau/pixterm/pkg/ansimage v0.0.0-20191210081756-9fb6cf8c2f75 // indirect
github.com/emirpasic/gods v1.18.1 // indirect
@@ -87,12 +88,12 @@ require (
github.com/go-ole/go-ole v1.2.6 // indirect
github.com/go-openapi/analysis v0.21.4 // indirect
github.com/go-openapi/errors v0.20.3 // indirect
github.com/go-openapi/jsonpointer v0.19.5 // indirect
github.com/go-openapi/jsonreference v0.20.0 // indirect
github.com/go-openapi/jsonpointer v0.19.6 // indirect
github.com/go-openapi/jsonreference v0.20.2 // indirect
github.com/go-openapi/loads v0.21.2 // indirect
github.com/go-openapi/spec v0.20.7 // indirect
github.com/go-openapi/spec v0.20.8 // indirect
github.com/go-openapi/swag v0.22.3 // indirect
github.com/go-openapi/validate v0.22.0 // indirect
github.com/go-openapi/validate v0.22.1 // indirect
github.com/go-resty/resty/v2 v2.7.0 // indirect
github.com/gogo/protobuf v1.3.2 // indirect
github.com/golang-jwt/jwt v3.2.2+incompatible // indirect
@@ -119,7 +120,7 @@ require (
github.com/kyokomi/emoji/v2 v2.2.11 // indirect
github.com/lucasb-eyer/go-colorful v1.2.0 // indirect
github.com/lucsky/cuid v1.2.1 // indirect
github.com/lufia/plan9stats v0.0.0-20220913051719-115f729f3c8c // indirect
github.com/lufia/plan9stats v0.0.0-20230110061619-bbe2e5e100de // indirect
github.com/magiconair/properties v1.8.5 // indirect
github.com/mailru/easyjson v0.7.7 // indirect
github.com/mattn/go-colorable v0.1.13 // indirect
@@ -168,12 +169,12 @@ require (
github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415 // indirect
github.com/xeipuuv/gojsonschema v1.2.0 // indirect
github.com/yusufpapurcu/wmi v1.2.2 // indirect
go.mongodb.org/mongo-driver v1.10.0 // indirect
go.mongodb.org/mongo-driver v1.11.1 // indirect
go.mozilla.org/pkcs7 v0.0.0-20210826202110-33d05740a352 // indirect
go.opentelemetry.io/otel v1.11.1 // indirect
go.opentelemetry.io/otel/trace v1.11.1 // indirect
golang.org/x/crypto v0.4.0 // indirect
golang.org/x/exp v0.0.0-20221230185412-738e83a70c30 // indirect
go.opentelemetry.io/otel v1.11.2 // indirect
go.opentelemetry.io/otel/trace v1.11.2 // indirect
golang.org/x/crypto v0.5.0 // indirect
golang.org/x/exp v0.0.0-20230202163644-54bba9f4231b // indirect
golang.org/x/image v0.3.0 // indirect
golang.org/x/mod v0.6.0 // indirect
golang.org/x/sync v0.1.0 // indirect
+53 -47
View File
@@ -191,8 +191,8 @@ github.com/disintegration/imaging v1.6.2 h1:w1LecBlG2Lnp8B3jk5zSuNqd7b4DXhcjwek1
github.com/disintegration/imaging v1.6.2/go.mod h1:44/5580QXChDfwIclfc/PCwrr44amcmDAg8hxG0Ewe4=
github.com/dlclark/regexp2 v1.1.6/go.mod h1:2pZnwuY/m+8K6iRw6wQdMtk+rH5tNGR1i55kozfMjCc=
github.com/dlclark/regexp2 v1.4.0/go.mod h1:2pZnwuY/m+8K6iRw6wQdMtk+rH5tNGR1i55kozfMjCc=
github.com/dlclark/regexp2 v1.7.0 h1:7lJfhqlPssTb1WQx4yvTHN0uElPEv52sbaECrAQxjAo=
github.com/dlclark/regexp2 v1.7.0/go.mod h1:DHkYz0B9wPfa6wondMfaivmHpzrQ3v9q8cnmRbL6yW8=
github.com/dlclark/regexp2 v1.8.0 h1:rJD5HeGIT/2b5CDk63FVCwZA3qgYElfg+oQK7uH5pfE=
github.com/dlclark/regexp2 v1.8.0/go.mod h1:DHkYz0B9wPfa6wondMfaivmHpzrQ3v9q8cnmRbL6yW8=
github.com/dnsimple/dnsimple-go v0.63.0/go.mod h1:O5TJ0/U6r7AfT8niYNlmohpLbCSG+c71tQlGr9SeGrg=
github.com/docker/distribution v2.8.1+incompatible h1:Q50tZOPR6T/hjNsyc9g8/syEs6bk8XXApsHjKukMl68=
github.com/docker/distribution v2.8.1+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w=
@@ -200,8 +200,8 @@ github.com/docker/docker v20.10.21+incompatible h1:UTLdBmHk3bEY+w8qeO5KttOhy6OmX
github.com/docker/docker v20.10.21+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk=
github.com/docker/go-connections v0.4.0 h1:El9xVISelRB7BuFusrZozjnkIM5YnzCViNKohAFqRJQ=
github.com/docker/go-connections v0.4.0/go.mod h1:Gbd7IOopHjR8Iph03tsViu4nIes5XhDvyHbTtUxmeec=
github.com/docker/go-units v0.4.0 h1:3uh0PgVws3nIA0Q+MwDC8yjEPf9zjRfZZWXZYDct3Tw=
github.com/docker/go-units v0.4.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk=
github.com/docker/go-units v0.5.0 h1:69rxXcBk27SvSaaxTtLh/8llcHD8vYHT7WSdRZ/jvr4=
github.com/docker/go-units v0.5.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk=
github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk=
github.com/eapache/go-resiliency v1.1.0/go.mod h1:kFI+JgMyC7bLPUVY133qvEBtVayf5mFgVsvEsIPBvNs=
github.com/eapache/go-xerial-snappy v0.0.0-20180814174437-776d5712da21/go.mod h1:+020luEh2TKB4/GOp8oxxtq0Daoen/Cii55CzbTV6DU=
@@ -225,8 +225,9 @@ github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7
github.com/exoscale/egoscale v0.23.0/go.mod h1:hRo78jkjkCDKpivQdRBEpNYF5+cVpCJCPDg2/r45KaY=
github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4=
github.com/fatih/color v1.9.0/go.mod h1:eQcE1qtQxscV5RaZvpXrrb8Drkc3/DdQ+uUYCNjL+zU=
github.com/fatih/color v1.13.0 h1:8LOYc1KYPPmyKMuN8QV2DNRWNbLo6LZ0iLs8+mlH53w=
github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYFFOfk=
github.com/fatih/color v1.14.1 h1:qfhVLaG5s+nCROl1zJsZRxFeYrHLqWroPOQ8BWiNb4w=
github.com/fatih/color v1.14.1/go.mod h1:2oHN61fhTpgcxD3TSWCgKDiH1+x4OiDVVGH8WlgGZGg=
github.com/fatih/structs v1.1.0/go.mod h1:9NiDSp5zOcgEDl+j00MP/WkGVPOlPRLejGD8Ga6PJ7M=
github.com/felixge/httpsnoop v1.0.1 h1:lvB5Jl89CsZtGIWuTcDM1E/vkVs49/Ml7JJe07l8SPQ=
github.com/felixge/httpsnoop v1.0.1/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U=
@@ -271,11 +272,13 @@ github.com/go-openapi/errors v0.20.2/go.mod h1:cM//ZKUKyO06HSwqAelJ5NsEMMcpa6VpX
github.com/go-openapi/errors v0.20.3 h1:rz6kiC84sqNQoqrtulzaL/VERgkoCyB6WdEkc2ujzUc=
github.com/go-openapi/errors v0.20.3/go.mod h1:Z3FlZ4I8jEGxjUK+bugx3on2mIAk4txuAOhlsB1FSgk=
github.com/go-openapi/jsonpointer v0.19.3/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg=
github.com/go-openapi/jsonpointer v0.19.5 h1:gZr+CIYByUqjcgeLXnQu2gHYQC9o73G2XUeOFYEICuY=
github.com/go-openapi/jsonpointer v0.19.5/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg=
github.com/go-openapi/jsonpointer v0.19.6 h1:eCs3fxoIi3Wh6vtgmLTOjdhSpiqphQ+DaPn38N2ZdrE=
github.com/go-openapi/jsonpointer v0.19.6/go.mod h1:osyAmYz/mB/C3I+WsTTSgw1ONzaLJoLCyoi6/zppojs=
github.com/go-openapi/jsonreference v0.19.6/go.mod h1:diGHMEHg2IqXZGKxqyvWdfWU/aim5Dprw5bqpKkTvns=
github.com/go-openapi/jsonreference v0.20.0 h1:MYlu0sBgChmCfJxxUKZ8g1cPWFOB37YSZqewK7OKeyA=
github.com/go-openapi/jsonreference v0.20.0/go.mod h1:Ag74Ico3lPc+zR+qjn4XBUmXymS4zJbYVCZmcgkasdo=
github.com/go-openapi/jsonreference v0.20.2 h1:3sVjiK66+uXK/6oQ8xgcRKcFgQ5KXa2KvnJRumpMGbE=
github.com/go-openapi/jsonreference v0.20.2/go.mod h1:Bl1zwGIM8/wsvqjsOQLJ/SH+En5Ap4rVB5KVcIDZG2k=
github.com/go-openapi/loads v0.21.1/go.mod h1:/DtAMXXneXFjbQMGEtbamCZb+4x7eGwkvZCvBmwUG+g=
github.com/go-openapi/loads v0.21.2 h1:r2a/xFIYeZ4Qd2TnGpWDIQNcP80dIaZgf704za8enro=
github.com/go-openapi/loads v0.21.2/go.mod h1:Jq58Os6SSGz0rzh62ptiu8Z31I+OTHqmULx5e/gJbNw=
@@ -283,8 +286,8 @@ github.com/go-openapi/runtime v0.25.0 h1:7yQTCdRbWhX8vnIjdzU8S00tBYf7Sg71EBeorlP
github.com/go-openapi/runtime v0.25.0/go.mod h1:Ux6fikcHXyyob6LNWxtE96hWwjBPYF0DXgVFuMTneOs=
github.com/go-openapi/spec v0.20.4/go.mod h1:faYFR1CvsJZ0mNsmsphTMSoRrNV3TEDoAM7FOEWeq8I=
github.com/go-openapi/spec v0.20.6/go.mod h1:2OpW+JddWPrpXSCIX8eOx7lZ5iyuWj3RYR6VaaBKcWA=
github.com/go-openapi/spec v0.20.7 h1:1Rlu/ZrOCCob0n+JKKJAWhNWMPW8bOZRg8FJaY+0SKI=
github.com/go-openapi/spec v0.20.7/go.mod h1:2OpW+JddWPrpXSCIX8eOx7lZ5iyuWj3RYR6VaaBKcWA=
github.com/go-openapi/spec v0.20.8 h1:ubHmXNY3FCIOinT8RNrrPfGc9t7I1qhPtdOGoG2AxRU=
github.com/go-openapi/spec v0.20.8/go.mod h1:2OpW+JddWPrpXSCIX8eOx7lZ5iyuWj3RYR6VaaBKcWA=
github.com/go-openapi/strfmt v0.21.0/go.mod h1:ZRQ409bWMj+SOgXofQAGTIo2Ebu72Gs+WaRADcS5iNg=
github.com/go-openapi/strfmt v0.21.1/go.mod h1:I/XVKeLc5+MM5oPNN7P6urMOpuLXEcNrCX/rPGuWb0k=
github.com/go-openapi/strfmt v0.21.3 h1:xwhj5X6CjXEZZHMWy1zKJxvW9AfHC9pkyUjLvHtKG7o=
@@ -294,8 +297,8 @@ github.com/go-openapi/swag v0.19.15/go.mod h1:QYRuS/SOXUCsnplDa677K7+DxSOj6IPNl/
github.com/go-openapi/swag v0.21.1/go.mod h1:QYRuS/SOXUCsnplDa677K7+DxSOj6IPNl/eQntq43wQ=
github.com/go-openapi/swag v0.22.3 h1:yMBqmnQ0gyZvEb/+KzuWZOXgllrXT4SADYbvDaXHv/g=
github.com/go-openapi/swag v0.22.3/go.mod h1:UzaqsxGiab7freDnrUUra0MwWfN/q7tE4j+VcZ0yl14=
github.com/go-openapi/validate v0.22.0 h1:b0QecH6VslW/TxtpKgzpO1SNG7GU2FsaqKdP1E2T50Y=
github.com/go-openapi/validate v0.22.0/go.mod h1:rjnrwK57VJ7A8xqfpAOEKRH8yQSGUriMu5/zuPSQ1hg=
github.com/go-openapi/validate v0.22.1 h1:G+c2ub6q47kfX1sOBLwIQwzBVt8qmOAARyo/9Fqs9NU=
github.com/go-openapi/validate v0.22.1/go.mod h1:rjnrwK57VJ7A8xqfpAOEKRH8yQSGUriMu5/zuPSQ1hg=
github.com/go-resty/resty/v2 v2.1.1-0.20191201195748-d7b97669fe48/go.mod h1:dZGr0i9PLlaaTD4H/hoZIDjQ+r6xq8mgbRzHZf7f2J8=
github.com/go-resty/resty/v2 v2.7.0 h1:me+K9p3uhSmXtrBZ4k9jcEAfJmuC8IivWHwaLZwPrFY=
github.com/go-resty/resty/v2 v2.7.0/go.mod h1:9PWDzw47qPphMRFfhsyk0NnSgvluHcljSMVIq3w7q0I=
@@ -536,8 +539,9 @@ github.com/konsorten/go-windows-terminal-sequences v1.0.3/go.mod h1:T0+1ngSBFLxv
github.com/kr/fs v0.1.0/go.mod h1:FFnZGqtBN9Gxj7eW1uZ42v5BccTP0vu6NEaFoC2HwRg=
github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc=
github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo=
github.com/kr/pretty v0.2.0 h1:s5hAObm+yFO5uHYt5dYjxi2rXrsnmRpJx4OYvIWUaQs=
github.com/kr/pretty v0.2.0/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI=
github.com/kr/pretty v0.2.1 h1:Fmg33tUaq4/8ym9TJN1x7sLJnHVwhP33CNkpYV/7rwI=
github.com/kr/pretty v0.2.1/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI=
github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ=
github.com/kr/pty v1.1.3/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ=
github.com/kr/pty v1.1.8 h1:AkaSdXYQOWeaO3neb8EM634ahkXXe3jYbVh/F9lq+GI=
@@ -561,8 +565,8 @@ github.com/lucasb-eyer/go-colorful v1.2.0/go.mod h1:R4dSotOR9KMtayYi1e77YzuveK+i
github.com/lucsky/cuid v1.2.1 h1:MtJrL2OFhvYufUIn48d35QGXyeTC8tn0upumW9WwTHg=
github.com/lucsky/cuid v1.2.1/go.mod h1:QaaJqckboimOmhRSJXSx/+IT+VTfxfPGSo/6mfgUfmE=
github.com/lufia/plan9stats v0.0.0-20211012122336-39d0f177ccd0/go.mod h1:zJYVVT2jmtg6P3p1VtQj7WsuWi/y4VnjVBn7F8KPB3I=
github.com/lufia/plan9stats v0.0.0-20220913051719-115f729f3c8c h1:VtwQ41oftZwlMnOEbMWQtSEUgU64U4s+GHk7hZK+jtY=
github.com/lufia/plan9stats v0.0.0-20220913051719-115f729f3c8c/go.mod h1:JKx41uQRwqlTZabZc+kILPrO/3jlKnQ2Z8b7YiVw5cE=
github.com/lufia/plan9stats v0.0.0-20230110061619-bbe2e5e100de h1:V53FWzU6KAZVi1tPp5UIsMoUWJ2/PNwYIDXnu7QuBCE=
github.com/lufia/plan9stats v0.0.0-20230110061619-bbe2e5e100de/go.mod h1:JKx41uQRwqlTZabZc+kILPrO/3jlKnQ2Z8b7YiVw5cE=
github.com/lunixbochs/vtclean v1.0.0/go.mod h1:pHhQNgMf3btfWnGBVipUOjRYhoOsdGqdm/+2c2E2WMI=
github.com/magiconair/properties v1.8.1/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ=
github.com/magiconair/properties v1.8.5 h1:b6kJs+EmPFMYGkow9GiUyCyOvIwYetYJ3fSaWak/Gls=
@@ -693,32 +697,34 @@ github.com/opentracing/opentracing-go v1.2.0 h1:uEJPy/1a5RIPAJ0Ov+OIO8OxWu77jEv+
github.com/opentracing/opentracing-go v1.2.0/go.mod h1:GxEUsuufX4nBwe+T+Wl9TAgYrxe9dPLANfrWvHYVTgc=
github.com/openzipkin/zipkin-go v0.1.1/go.mod h1:NtoC/o8u3JlF1lSlyPNswIbeQH9bJTmOf0Erfk+hxe8=
github.com/openzipkin/zipkin-go v0.1.6/go.mod h1:QgAqvLzwWbR/WpD4A3cGpPtJrZXNIiJc5AZX7/PBEpw=
github.com/openziti/agent v1.0.7 h1:tEZlYQ5/y7oeuYUAdqN6AAayQAloL8Ms6prSddaUDVY=
github.com/openziti/agent v1.0.7/go.mod h1:6APWgkPP6Uxf1/VyirdTVLAJxwam2vVyakrVw6yvs40=
github.com/openziti/channel/v2 v2.0.25 h1:ihw9DDTfMHDL33gZFLqDyADFGKBec4beaThV/VJLWhI=
github.com/openziti/channel/v2 v2.0.25/go.mod h1:eHPS7dmvDV+Q/SmbB2gwvdvdz/NcnetFshHsdNzAnZs=
github.com/openziti/agent v1.0.8 h1:qB4zQO9dz3PL8qbeyzCWbwTrtHZPEZlYtjkJJ78SJPo=
github.com/openziti/agent v1.0.8/go.mod h1:6APWgkPP6Uxf1/VyirdTVLAJxwam2vVyakrVw6yvs40=
github.com/openziti/channel/v2 v2.0.26 h1:IIEnno26FuywcyCwCie1U7OHoB8HzuG95EzEnvtKmio=
github.com/openziti/channel/v2 v2.0.26/go.mod h1:zZO0bgVYY9FCDs2EMRakDl6wIfyOWuzgPzPL8EvQ5Ks=
github.com/openziti/dilithium v0.3.3 h1:PLgQ6PMNLSTzCFbX/h98cmudgz/cU6TmjdSv5NAPD8k=
github.com/openziti/dilithium v0.3.3/go.mod h1:vsCjI2AU/hon9e+dLhUFbCNGesJDj2ASgkySOcpmvjo=
github.com/openziti/edge v0.24.95 h1:Lj7ycWVOXbqt3TK6NSGPWXj5bp3/5rX7rA+bR5wA8Nc=
github.com/openziti/edge v0.24.95/go.mod h1:nVamtrBekK372q8bbKK/D6t0W7LBqQ+Miu0YE1u3od4=
github.com/openziti/fabric v0.22.7 h1:o0k/QnCpVZPiC77fh/NoUVCoeQNhfBm4oOICcJsdkWc=
github.com/openziti/fabric v0.22.7/go.mod h1:NITYnGTCeu0ENixTd7qXFzGyIDm5GkyJhxKYTnmFzjk=
github.com/openziti/edge v0.24.115 h1:8mFqSq/6Bzpkkh61p4GwX86mOi1tcRP2mdo8/x7umgk=
github.com/openziti/edge v0.24.115/go.mod h1:QZJ/5nJBewfkqcHwAEU0Wz8B6i1uB5+DQ5788XRXY4U=
github.com/openziti/edge-api v0.25.6 h1:gn7oJRgAojyJlMgbidAbPTuPhfGWr+stGsTtzkIfjFA=
github.com/openziti/edge-api v0.25.6/go.mod h1:Ohmiq2Fdz1UXiXIyxGUIPI1gXY3ZVNMiT7urvp8u6xw=
github.com/openziti/fabric v0.22.19 h1:QFieGI8mQYX+OooVLeKLl2nI30GS8jD7XXjF8/xp6A0=
github.com/openziti/fabric v0.22.19/go.mod h1:kU+xlaM0GFoVBPIOzVnTSSFDBmigEtfhdFhzTUWh/W4=
github.com/openziti/foundation/v2 v2.0.10 h1:IeOkcPbgBpBTw4JrWz8s9Z76vO/m+i2uIE0cMZ0C2DM=
github.com/openziti/foundation/v2 v2.0.10/go.mod h1:Z0gnQsGJb/H/B+pixLtmCIpw1dBllD4QoT6LeD35WzA=
github.com/openziti/identity v1.0.29 h1:FkY/Hzpfh2/U2cUzYR2X3380/IKGIQYpJaKWqXpOIAg=
github.com/openziti/identity v1.0.29/go.mod h1:SPZAaqvDToS2jtae4D2fvO9IsR6G6FKNZ8WTqAwKKJE=
github.com/openziti/identity v1.0.30 h1:N2WDdK7MpeXuHCRjMo6N/QMtUXUkenUEqfKWXFNu2oE=
github.com/openziti/identity v1.0.30/go.mod h1:SPZAaqvDToS2jtae4D2fvO9IsR6G6FKNZ8WTqAwKKJE=
github.com/openziti/jwks v1.0.2 h1:32BGXIAnefS+v7uXKPb1x8/cQ7srek6Ai06dsrMTY4E=
github.com/openziti/jwks v1.0.2/go.mod h1:KwO0x9FBG0aoJS5f6nH5xeHoplyR1H143SMI9kF0mC8=
github.com/openziti/metrics v1.2.3 h1:h9+mSU673QLSMOb3YibD1vNgE0yIDZ5leiUqDwN5szE=
github.com/openziti/metrics v1.2.3/go.mod h1:jK8BfZ9nXMhO+LPcUPpN/sebrLfIeF4uaHlm5JIF7BY=
github.com/openziti/runzmd v1.0.7 h1:2EC3bVjjAuFsECaZbwTOJdDbSk3I8JpfaI2ruGdEGiA=
github.com/openziti/runzmd v1.0.7/go.mod h1:0AlunP33eJ/S21az+ACP9/INVeUSR80pELXYXs2hK0I=
github.com/openziti/sdk-golang v0.18.21 h1:oWJXrvMbXvTGkQ0MF3oFKmAw6dBBKhNt2WxNjj/Z1zA=
github.com/openziti/sdk-golang v0.18.21/go.mod h1:LT+IOT2GqsmYLwjjO3YOlcejgBROyMI1a01xo8Xh+A8=
github.com/openziti/storage v0.1.31 h1:YO1c1mzn+DfmBOtzhBlMe6q5cgjSOUv+sY8iUOwXals=
github.com/openziti/storage v0.1.31/go.mod h1:DFRIpfCkI7lLuhGUl4CgZR6sGbsMJ/+nGnjkVIqCgrw=
github.com/openziti/transport/v2 v2.0.49 h1:P3gUazaC8Z7iy4eXk510wjTKot6GucWMtqexU3mn83U=
github.com/openziti/transport/v2 v2.0.49/go.mod h1:aFx8zQsuXttifuJI9WXZQ8p6CHm5H75Ab/cuPg/gFFw=
github.com/openziti/runzmd v1.0.9 h1:gQnZT5cACuVpcBBBHWIaN9Vmwv8KUNa7LBLG8Xi13/U=
github.com/openziti/runzmd v1.0.9/go.mod h1:s6amx7gbzewUqlnq8dcvJ50eb0ryjQtknPYubOHuIug=
github.com/openziti/sdk-golang v0.18.26 h1:Wk2s88R9b5SeP3D3uEpqE31ffY20Y1v2ZSyYfgud/BA=
github.com/openziti/sdk-golang v0.18.26/go.mod h1:QCoDwqjGm8qxcIDboY+jglfjZVdz8gREquRMpX7jz8I=
github.com/openziti/storage v0.1.33 h1:c3jdiJPIthYC51Ye2VOBGuz3g1DGVzmjGIlgPs1BcOg=
github.com/openziti/storage v0.1.33/go.mod h1:G4swa9DU8oG+B+tv4X7X5QjtI8nxbXhEUKlDbwNowBY=
github.com/openziti/transport/v2 v2.0.50 h1:bMk0CeQhg61vaCpAUANlu+hZTqyZSa7IFX3ZYFi1tns=
github.com/openziti/transport/v2 v2.0.50/go.mod h1:I3qtYJhHzEzydqqdIq8IZStwPV7ybynK0mJP17MB/q0=
github.com/openziti/x509-claims v1.0.3 h1:HNdQ8Nf1agB3lBs1gahcO6zfkeS4S5xoQ2/PkY4HRX0=
github.com/openziti/x509-claims v1.0.3/go.mod h1:Z0WIpBm6c4ecrpRKrou6Gk2wrLWxJO/+tuUwKh8VewE=
github.com/openziti/xweb/v2 v2.0.2 h1:XYlVFriTq/U1wcUrc+XPnWJGhXh9NJPhtQ7+r3aC0cU=
@@ -812,8 +818,8 @@ github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb
github.com/sacloud/libsacloud v1.36.2/go.mod h1:P7YAOVmnIn3DKHqCZcUKYUXmSwGBm3yS7IBEjKVSrjg=
github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc=
github.com/sergi/go-diff v1.0.0/go.mod h1:0CfEIISq7TuYL3j771MWULgwwjU+GofnZX9QAmXWZgo=
github.com/shirou/gopsutil/v3 v3.22.12 h1:oG0ns6poeUSxf78JtOsfygNWuEHYYz8hnnNg7P04TJs=
github.com/shirou/gopsutil/v3 v3.22.12/go.mod h1:Xd7P1kwZcp5VW52+9XsirIKd/BROzbb2wdX3Kqlz9uI=
github.com/shirou/gopsutil/v3 v3.23.1 h1:a9KKO+kGLKEvcPIs4W62v0nu3sciVDOOOPUD0Hz7z/4=
github.com/shirou/gopsutil/v3 v3.23.1/go.mod h1:NN6mnm5/0k8jw4cBfCnJtr5L7ErOTg18tMNpgFkn0hA=
github.com/shurcooL/component v0.0.0-20170202220835-f88ec8f54cc4/go.mod h1:XhFIlyj5a1fBNx5aJTbKoIq0mNaPvOagO+HjB3EtxrY=
github.com/shurcooL/events v0.0.0-20181021180414-410e4ca65f48/go.mod h1:5u70Mqkb5O5cxEA8nxTsgrgLehJeAw6Oc4Ab1c/P1HM=
github.com/shurcooL/github_flavored_markdown v0.0.0-20181002035957-2122de532470/go.mod h1:2dOwnU2uBioM+SGy2aZoq1f/Sd1l9OkAeAUvjSyvgU0=
@@ -945,15 +951,16 @@ github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5t
github.com/yusufpapurcu/wmi v1.2.2 h1:KBNDSne4vP5mbSWnJbO+51IMOXJB67QiYCSBrubbPRg=
github.com/yusufpapurcu/wmi v1.2.2/go.mod h1:SBZ9tNy3G9/m5Oi98Zks0QjeHVDvuK0qfxQmPyzfmi0=
go.etcd.io/bbolt v1.3.2/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU=
go.etcd.io/bbolt v1.3.6 h1:/ecaJf0sk1l4l6V4awd65v2C3ILy7MSj+s/x1ADCIMU=
go.etcd.io/bbolt v1.3.6/go.mod h1:qXsaaIqmgQH0T+OPdb99Bf+PKfBBQVAdyD6TY9G8XM4=
go.etcd.io/bbolt v1.3.7 h1:j+zJOnnEjF/kyHlDDgGnVL/AIqIJPq8UoB2GSNfkUfQ=
go.etcd.io/bbolt v1.3.7/go.mod h1:N9Mkw9X8x5fupy0IKsmuqVtoGDyxsaDlbk4Rd05IAQw=
go.etcd.io/etcd/api/v3 v3.5.0/go.mod h1:cbVKeC6lCfl7j/8jBhAK6aIYO9XOjdptoxU/nLQcPvs=
go.etcd.io/etcd/client/pkg/v3 v3.5.0/go.mod h1:IJHfcCEKxYu1Os13ZdwCwIUTUVGYTSAM3YSwc9/Ac1g=
go.etcd.io/etcd/client/v2 v2.305.0/go.mod h1:h9puh54ZTgAKtEbut2oe9P4L/oqKCVB6xsXlzd7alYQ=
go.mongodb.org/mongo-driver v1.7.3/go.mod h1:NqaYOwnXWr5Pm7AOpO5QFxKJ503nbMse/R79oO62zWg=
go.mongodb.org/mongo-driver v1.7.5/go.mod h1:VXEWRZ6URJIkUq2SCAyapmhH0ZLRBP+FT4xhp5Zvxng=
go.mongodb.org/mongo-driver v1.10.0 h1:UtV6N5k14upNp4LTduX0QCufG124fSu25Wz9tu94GLg=
go.mongodb.org/mongo-driver v1.10.0/go.mod h1:wsihk0Kdgv8Kqu1Anit4sfK+22vSFbUrAVEYRhCXrA8=
go.mongodb.org/mongo-driver v1.11.1 h1:QP0znIRTuL0jf1oBQoAoM0C6ZJfBK4kx0Uumtv1A7w8=
go.mongodb.org/mongo-driver v1.11.1/go.mod h1:s7p5vEtfbeR1gYi6pnj3c3/urpbLv2T5Sfd6Rp2HBB8=
go.mozilla.org/pkcs7 v0.0.0-20210826202110-33d05740a352 h1:CCriYyAfq1Br1aIYettdHZTy8mBTIPo7We18TuO/bak=
go.mozilla.org/pkcs7 v0.0.0-20210826202110-33d05740a352/go.mod h1:SNgMg+EgDFwmvSmLRTNKC5fegJjB7v23qTQ0XLGUNHk=
go.opencensus.io v0.18.0/go.mod h1:vKdFvxhtzZ9onBp9VKHK8z/sRpBMnKAsufL7wlDrCOA=
@@ -966,11 +973,11 @@ go.opencensus.io v0.22.3/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
go.opencensus.io v0.22.4/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
go.opencensus.io v0.22.5/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk=
go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E=
go.opentelemetry.io/otel v1.11.1 h1:4WLLAmcfkmDk2ukNXJyq3/kiz/3UzCaYq6PskJsaou4=
go.opentelemetry.io/otel v1.11.1/go.mod h1:1nNhXBbWSD0nsL38H6btgnFN2k4i0sNLHNNMZMSbUGE=
go.opentelemetry.io/otel v1.11.2 h1:YBZcQlsVekzFsFbjygXMOXSs6pialIZxcjfO/mBDmR0=
go.opentelemetry.io/otel v1.11.2/go.mod h1:7p4EUV+AqgdlNV9gL97IgUZiVR3yrFXYo53f9BM3tRI=
go.opentelemetry.io/otel/sdk v1.11.1 h1:F7KmQgoHljhUuJyA+9BiU+EkJfyX5nVVF4wyzWZpKxs=
go.opentelemetry.io/otel/trace v1.11.1 h1:ofxdnzsNrGBYXbP7t7zpUK281+go5rF7dvdIZXF8gdQ=
go.opentelemetry.io/otel/trace v1.11.1/go.mod h1:f/Q9G7vzk5u91PhbmKbg1Qn0rzH1LJ4vbPHFGkTPtOk=
go.opentelemetry.io/otel/trace v1.11.2 h1:Xf7hWSF2Glv0DE3MH7fBHvtpSBsjcBUe5MYAmZM/+y0=
go.opentelemetry.io/otel/trace v1.11.2/go.mod h1:4N+yC7QEz7TTsG9BSRLNAa63eg5E06ObSbKPmxQ/pKA=
go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI=
go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE=
go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE=
@@ -1008,8 +1015,8 @@ golang.org/x/crypto v0.0.0-20200820211705-5c72a883971a/go.mod h1:LzIPMQfyMNhhGPh
golang.org/x/crypto v0.0.0-20210616213533-5ff15b29337e/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4=
golang.org/x/crypto v0.4.0 h1:UVQgzMY87xqpKNgb+kDsll2Igd33HszWHFLmpaRMq/8=
golang.org/x/crypto v0.4.0/go.mod h1:3quD/ATkf6oY+rnes5c3ExXTbLc8mueNue5/DoinL80=
golang.org/x/crypto v0.5.0 h1:U/0M97KRkSFvyD/3FSmdP5W5swImpNgle/EHFhOsQPE=
golang.org/x/crypto v0.5.0/go.mod h1:NK/OQwhpMQP3MwtdjgLlYHnH9ebylxKWv3e0fK+mkQU=
golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8=
@@ -1020,8 +1027,8 @@ golang.org/x/exp v0.0.0-20191227195350-da58074b4299/go.mod h1:2RIsYlXP63K8oxa1u0
golang.org/x/exp v0.0.0-20200119233911-0405dc783f0a/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4=
golang.org/x/exp v0.0.0-20200207192155-f17229e696bd/go.mod h1:J/WKrq2StrnmMY6+EHIKF9dgMWnmCNThgcyBT1FY9mM=
golang.org/x/exp v0.0.0-20200224162631-6cc2880d07d6/go.mod h1:3jZMyOhIsHpP37uCMkUooju7aAi5cS1Q23tOzKc+0MU=
golang.org/x/exp v0.0.0-20221230185412-738e83a70c30 h1:m9O6OTJ627iFnN2JIWfdqlZCzneRO6EEBsHXI25P8ws=
golang.org/x/exp v0.0.0-20221230185412-738e83a70c30/go.mod h1:CxIveKay+FTh1D0yPZemJVgC/95VzuuOLq5Qi4xnoYc=
golang.org/x/exp v0.0.0-20230202163644-54bba9f4231b h1:EqBVA+nNsObCwQoBEHy4wLU0pi7i8a4AL3pbItPdPkE=
golang.org/x/exp v0.0.0-20230202163644-54bba9f4231b/go.mod h1:CxIveKay+FTh1D0yPZemJVgC/95VzuuOLq5Qi4xnoYc=
golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js=
golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0=
golang.org/x/image v0.0.0-20191009234506-e7c1f5e7dbb8/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0=
@@ -1201,7 +1208,6 @@ golang.org/x/sys v0.0.0-20200831180312-196b9ba8737a/go.mod h1:h1NjWce9XRLGQEsW7w
golang.org/x/sys v0.0.0-20200905004654-be1d3432aa8f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200909081042-eff7692f9009/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200918174421-af09f7315aff/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200923182605-d9f96fdee20d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20201201145000-ef89a241ccb3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
@@ -1228,7 +1234,6 @@ golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBc
golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220908164124-27713097b956/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.2.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.3.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.4.0 h1:Zr2JFtRQNX3BCZ8YtxRE9hNJYC8J6I1MVbMg6owUp18=
golang.org/x/sys v0.4.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
@@ -1454,6 +1459,7 @@ gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8
gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/check.v1 v1.0.0-20200902074654-038fdea0a05b/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk=
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q=
gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI=
gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys=
gopkg.in/h2non/gock.v1 v1.0.15/go.mod h1:sX4zAkdYX1TRGJ2JY156cFspQn4yRWn6p9EMdODlynE=
+51 -43
View File
@@ -3,9 +3,9 @@ module github.com/openziti/ziti/network-tests
go 1.19
require (
github.com/openziti/fablab v0.4.15
github.com/openziti/sdk-golang v0.18.2
github.com/openziti/zitilab v0.1.9
github.com/openziti/fablab v0.4.23
github.com/openziti/sdk-golang v0.18.26
github.com/openziti/zitilab v0.1.21
github.com/sirupsen/logrus v1.9.0
github.com/spf13/cobra v1.6.1
)
@@ -28,31 +28,34 @@ require (
github.com/boltdb/bolt v1.3.1 // indirect
github.com/c-bata/go-prompt v0.2.6 // indirect
github.com/cenkalti/backoff/v4 v4.2.0 // indirect
github.com/coreos/go-iptables v0.6.0 // indirect
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/dgryski/dgoogauth v0.0.0-20190221195224-5a805980a5f3 // indirect
github.com/dineshappavoo/basex v0.0.0-20170425072625-481a6f6dc663 // indirect
github.com/disintegration/imaging v1.6.2 // indirect
github.com/dlclark/regexp2 v1.7.0 // indirect
github.com/docker/go-units v0.4.0 // indirect
github.com/dlclark/regexp2 v1.8.0 // indirect
github.com/docker/go-units v0.5.0 // indirect
github.com/ef-ds/deque v1.0.4 // indirect
github.com/eliukblau/pixterm/pkg/ansimage v0.0.0-20191210081756-9fb6cf8c2f75 // indirect
github.com/emirpasic/gods v1.18.1 // indirect
github.com/fatih/color v1.13.0 // indirect
github.com/fatih/color v1.14.1 // indirect
github.com/felixge/httpsnoop v1.0.1 // indirect
github.com/fsnotify/fsnotify v1.6.0 // indirect
github.com/fullsailor/pkcs7 v0.0.0-20190404230743-d7302db945fa // indirect
github.com/go-acme/lego/v4 v4.2.0 // indirect
github.com/go-logr/logr v1.2.3 // indirect
github.com/go-logr/stdr v1.2.2 // indirect
github.com/go-ole/go-ole v1.2.6 // indirect
github.com/go-openapi/analysis v0.21.4 // indirect
github.com/go-openapi/errors v0.20.3 // indirect
github.com/go-openapi/jsonpointer v0.19.5 // indirect
github.com/go-openapi/jsonreference v0.20.0 // indirect
github.com/go-openapi/jsonpointer v0.19.6 // indirect
github.com/go-openapi/jsonreference v0.20.2 // indirect
github.com/go-openapi/loads v0.21.2 // indirect
github.com/go-openapi/runtime v0.24.2 // indirect
github.com/go-openapi/spec v0.20.7 // indirect
github.com/go-openapi/runtime v0.25.0 // indirect
github.com/go-openapi/spec v0.20.8 // indirect
github.com/go-openapi/strfmt v0.21.3 // indirect
github.com/go-openapi/swag v0.22.3 // indirect
github.com/go-openapi/validate v0.22.0 // indirect
github.com/go-openapi/validate v0.22.1 // indirect
github.com/go-resty/resty/v2 v2.7.0 // indirect
github.com/golang-jwt/jwt v3.2.2+incompatible // indirect
github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b // indirect
@@ -62,34 +65,37 @@ require (
github.com/google/uuid v1.3.0 // indirect
github.com/gorilla/handlers v1.5.1 // indirect
github.com/gorilla/websocket v1.5.0 // indirect
github.com/hashicorp/go-hclog v1.3.1 // indirect
github.com/hashicorp/go-hclog v1.4.0 // indirect
github.com/hashicorp/go-immutable-radix v1.3.1 // indirect
github.com/hashicorp/go-msgpack v0.5.5 // indirect
github.com/hashicorp/golang-lru v0.5.4 // indirect
github.com/hashicorp/golang-lru v0.6.0 // indirect
github.com/hashicorp/golang-lru/v2 v2.0.1 // indirect
github.com/hashicorp/hcl v1.0.0 // indirect
github.com/hashicorp/raft v1.3.11 // indirect
github.com/hashicorp/raft-boltdb v0.0.0-20220329195025-15018e9b97e0 // indirect
github.com/inconshreveable/mousetrap v1.0.1 // indirect
github.com/influxdata/influxdb1-client v0.0.0-20191209144304-8bf82d3c094d // indirect
github.com/jedib0t/go-pretty/v6 v6.4.2 // indirect
github.com/inconshreveable/mousetrap v1.1.0 // indirect
github.com/jedib0t/go-pretty/v6 v6.4.4 // indirect
github.com/jessevdk/go-flags v1.5.0 // indirect
github.com/jinzhu/copier v0.3.5 // indirect
github.com/jmespath/go-jmespath v0.4.0 // indirect
github.com/josharian/intern v1.0.0 // indirect
github.com/josharian/native v1.0.0 // indirect
github.com/kataras/go-events v0.0.3-0.20201007151548-c411dc70c0a6 // indirect
github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51 // indirect
github.com/keybase/go-ps v0.0.0-20190827175125-91aafc93ba19 // indirect
github.com/kr/fs v0.1.0 // indirect
github.com/kyokomi/emoji/v2 v2.2.10 // indirect
github.com/kyokomi/emoji/v2 v2.2.11 // indirect
github.com/lucasb-eyer/go-colorful v1.2.0 // indirect
github.com/lucsky/cuid v1.2.1 // indirect
github.com/lufia/plan9stats v0.0.0-20220913051719-115f729f3c8c // indirect
github.com/lufia/plan9stats v0.0.0-20230110061619-bbe2e5e100de // indirect
github.com/magiconair/properties v1.8.5 // indirect
github.com/mailru/easyjson v0.7.7 // indirect
github.com/mattn/go-colorable v0.1.13 // indirect
github.com/mattn/go-isatty v0.0.16 // indirect
github.com/mattn/go-isatty v0.0.17 // indirect
github.com/mattn/go-runewidth v0.0.14 // indirect
github.com/mattn/go-tty v0.0.3 // indirect
github.com/mdlayher/netlink v1.7.1 // indirect
github.com/mdlayher/socket v0.4.0 // indirect
github.com/mgutz/ansi v0.0.0-20200706080929-d51e80ef957d // indirect
github.com/michaelquigley/figlet v0.0.0-20191015203154-054d06db54b4 // indirect
github.com/michaelquigley/pfxlog v0.6.9 // indirect
@@ -103,34 +109,34 @@ require (
github.com/oklog/ulid v1.3.1 // indirect
github.com/oliveagle/jsonpath v0.0.0-20180606110733-2e52cf6e6852 // indirect
github.com/opentracing/opentracing-go v1.2.0 // indirect
github.com/openziti/agent v1.0.5 // indirect
github.com/openziti/channel/v2 v2.0.15 // indirect
github.com/openziti/edge v0.24.50 // indirect
github.com/openziti/fabric v0.21.21 // indirect
github.com/openziti/foundation/v2 v2.0.7 // indirect
github.com/openziti/identity v1.0.23 // indirect
github.com/openziti/agent v1.0.8 // indirect
github.com/openziti/channel/v2 v2.0.26 // indirect
github.com/openziti/edge v0.24.95 // indirect
github.com/openziti/fabric v0.22.7 // indirect
github.com/openziti/foundation/v2 v2.0.10 // indirect
github.com/openziti/identity v1.0.30 // indirect
github.com/openziti/jwks v1.0.2 // indirect
github.com/openziti/metrics v1.1.6 // indirect
github.com/openziti/runzmd v1.0.3 // indirect
github.com/openziti/storage v0.1.26 // indirect
github.com/openziti/transport/v2 v2.0.41 // indirect
github.com/openziti/metrics v1.2.3 // indirect
github.com/openziti/runzmd v1.0.9 // indirect
github.com/openziti/storage v0.1.33 // indirect
github.com/openziti/transport/v2 v2.0.50 // indirect
github.com/openziti/x509-claims v1.0.3 // indirect
github.com/openziti/xweb/v2 v2.0.2 // indirect
github.com/openziti/ziti v0.26.11 // indirect
github.com/openziti/ziti v0.27.2 // indirect
github.com/openziti/ziti-db-explorer v1.1.1 // indirect
github.com/orcaman/concurrent-map/v2 v2.0.0 // indirect
github.com/orcaman/concurrent-map/v2 v2.0.1 // indirect
github.com/parallaxsecond/parsec-client-go v0.0.0-20221025095442-f0a77d263cf9 // indirect
github.com/pelletier/go-toml v1.9.4 // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/pkg/sftp v1.13.5 // indirect
github.com/pkg/term v1.2.0-beta.2 // indirect
github.com/pmezard/go-difflib v1.0.0 // indirect
github.com/power-devops/perfstat v0.0.0-20220216144756-c35f1ee13d7c // indirect
github.com/power-devops/perfstat v0.0.0-20221212215047-62379fc7944b // indirect
github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 // indirect
github.com/rivo/uniseg v0.4.2 // indirect
github.com/rivo/uniseg v0.4.3 // indirect
github.com/rodaine/table v1.0.1 // indirect
github.com/russross/blackfriday v1.5.2 // indirect
github.com/shirou/gopsutil/v3 v3.22.10 // indirect
github.com/shirou/gopsutil/v3 v3.23.1 // indirect
github.com/skip2/go-qrcode v0.0.0-20200617195104-da1b6568686e // indirect
github.com/speps/go-hashids v2.0.0+incompatible // indirect
github.com/spf13/afero v1.6.0 // indirect
@@ -149,18 +155,20 @@ require (
github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415 // indirect
github.com/xeipuuv/gojsonschema v1.2.0 // indirect
github.com/yusufpapurcu/wmi v1.2.2 // indirect
go.etcd.io/bbolt v1.3.6 // indirect
go.mongodb.org/mongo-driver v1.10.0 // indirect
go.etcd.io/bbolt v1.3.7 // indirect
go.mongodb.org/mongo-driver v1.11.1 // indirect
go.mozilla.org/pkcs7 v0.0.0-20210826202110-33d05740a352 // indirect
golang.org/x/crypto v0.3.0 // indirect
golang.org/x/exp v0.0.0-20221126150942-6ab00d035af9 // indirect
golang.org/x/image v0.1.0 // indirect
go.opentelemetry.io/otel v1.11.2 // indirect
go.opentelemetry.io/otel/trace v1.11.2 // indirect
golang.org/x/crypto v0.5.0 // indirect
golang.org/x/exp v0.0.0-20230202163644-54bba9f4231b // indirect
golang.org/x/image v0.3.0 // indirect
golang.org/x/mod v0.6.0 // indirect
golang.org/x/net v0.2.0 // indirect
golang.org/x/net v0.5.0 // indirect
golang.org/x/sync v0.1.0 // indirect
golang.org/x/sys v0.2.0 // indirect
golang.org/x/term v0.2.0 // indirect
golang.org/x/text v0.4.0 // indirect
golang.org/x/sys v0.4.0 // indirect
golang.org/x/term v0.4.0 // indirect
golang.org/x/text v0.6.0 // indirect
golang.org/x/tools v0.2.0 // indirect
google.golang.org/protobuf v1.28.1 // indirect
gopkg.in/AlecAivazis/survey.v1 v1.8.7 // indirect
+107 -91
View File
@@ -137,14 +137,16 @@ github.com/cloudflare/cloudflare-go v0.13.2/go.mod h1:27kfc1apuifUmJhp069y0+hwlK
github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc=
github.com/cncf/udpa/go v0.0.0-20200629203442-efcf912fb354/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk=
github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk=
github.com/coreos/go-iptables v0.6.0 h1:is9qnZMPYjLd8LYqmm/qlE+wwEgJIkTYdhV3rfZo4jk=
github.com/coreos/go-iptables v0.6.0/go.mod h1:Qe8Bv2Xik5FyTXwgIbLAnv2sWSBmvWdFETJConOQ//Q=
github.com/coreos/go-semver v0.3.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk=
github.com/coreos/go-systemd/v22 v22.3.2/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc=
github.com/cpu/goacmedns v0.1.1/go.mod h1:MuaouqEhPAHxsbqjgnck5zeghuwBP1dLnPoobeGqugQ=
github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU=
github.com/cpuguy83/go-md2man/v2 v2.0.0/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU=
github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o=
github.com/creack/pty v1.1.9 h1:uDmaGzcdjhF4i/plgjmEsriH11Y0o7RKapEf/LDaM3w=
github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E=
github.com/creack/pty v1.1.11 h1:07n33Z8lZxZ2qwegKbObQohDhXDQxiMMz1NOUGYlesw=
github.com/danwakefield/fnmatch v0.0.0-20160403171240-cbb64ac3d964/go.mod h1:Xd9hchkHSWYkEqJwUGisez3G1QY8Ryz0sdWrLPMGjLk=
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
@@ -159,11 +161,11 @@ github.com/disintegration/imaging v1.6.2 h1:w1LecBlG2Lnp8B3jk5zSuNqd7b4DXhcjwek1
github.com/disintegration/imaging v1.6.2/go.mod h1:44/5580QXChDfwIclfc/PCwrr44amcmDAg8hxG0Ewe4=
github.com/dlclark/regexp2 v1.1.6/go.mod h1:2pZnwuY/m+8K6iRw6wQdMtk+rH5tNGR1i55kozfMjCc=
github.com/dlclark/regexp2 v1.4.0/go.mod h1:2pZnwuY/m+8K6iRw6wQdMtk+rH5tNGR1i55kozfMjCc=
github.com/dlclark/regexp2 v1.7.0 h1:7lJfhqlPssTb1WQx4yvTHN0uElPEv52sbaECrAQxjAo=
github.com/dlclark/regexp2 v1.7.0/go.mod h1:DHkYz0B9wPfa6wondMfaivmHpzrQ3v9q8cnmRbL6yW8=
github.com/dlclark/regexp2 v1.8.0 h1:rJD5HeGIT/2b5CDk63FVCwZA3qgYElfg+oQK7uH5pfE=
github.com/dlclark/regexp2 v1.8.0/go.mod h1:DHkYz0B9wPfa6wondMfaivmHpzrQ3v9q8cnmRbL6yW8=
github.com/dnsimple/dnsimple-go v0.63.0/go.mod h1:O5TJ0/U6r7AfT8niYNlmohpLbCSG+c71tQlGr9SeGrg=
github.com/docker/go-units v0.4.0 h1:3uh0PgVws3nIA0Q+MwDC8yjEPf9zjRfZZWXZYDct3Tw=
github.com/docker/go-units v0.4.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk=
github.com/docker/go-units v0.5.0 h1:69rxXcBk27SvSaaxTtLh/8llcHD8vYHT7WSdRZ/jvr4=
github.com/docker/go-units v0.5.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk=
github.com/eapache/go-resiliency v1.1.0/go.mod h1:kFI+JgMyC7bLPUVY133qvEBtVayf5mFgVsvEsIPBvNs=
github.com/eapache/go-xerial-snappy v0.0.0-20180814174437-776d5712da21/go.mod h1:+020luEh2TKB4/GOp8oxxtq0Daoen/Cii55CzbTV6DU=
github.com/eapache/queue v1.1.0/go.mod h1:6eCeP0CKFpHLu8blIFXhExK/dRa7WDZfr6jVFPTqq+I=
@@ -183,8 +185,9 @@ github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7
github.com/exoscale/egoscale v0.23.0/go.mod h1:hRo78jkjkCDKpivQdRBEpNYF5+cVpCJCPDg2/r45KaY=
github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4=
github.com/fatih/color v1.9.0/go.mod h1:eQcE1qtQxscV5RaZvpXrrb8Drkc3/DdQ+uUYCNjL+zU=
github.com/fatih/color v1.13.0 h1:8LOYc1KYPPmyKMuN8QV2DNRWNbLo6LZ0iLs8+mlH53w=
github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYFFOfk=
github.com/fatih/color v1.14.1 h1:qfhVLaG5s+nCROl1zJsZRxFeYrHLqWroPOQ8BWiNb4w=
github.com/fatih/color v1.14.1/go.mod h1:2oHN61fhTpgcxD3TSWCgKDiH1+x4OiDVVGH8WlgGZGg=
github.com/fatih/structs v1.1.0/go.mod h1:9NiDSp5zOcgEDl+j00MP/WkGVPOlPRLejGD8Ga6PJ7M=
github.com/felixge/httpsnoop v1.0.1 h1:lvB5Jl89CsZtGIWuTcDM1E/vkVs49/Ml7JJe07l8SPQ=
github.com/felixge/httpsnoop v1.0.1/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U=
@@ -208,6 +211,11 @@ github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2
github.com/go-kit/kit v0.9.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as=
github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE=
github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk=
github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A=
github.com/go-logr/logr v1.2.3 h1:2DntVwHkVopvECVRSlL5PSo9eG+cAkDCuckLubN+rq0=
github.com/go-logr/logr v1.2.3/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A=
github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag=
github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE=
github.com/go-ole/go-ole v1.2.6 h1:/Fpf6oFPoeFik9ty7siob0G6Ke8QvQEuVcuChpwXzpY=
github.com/go-ole/go-ole v1.2.6/go.mod h1:pprOEPIfldk/42T2oK7lQ4v4JSDwmV0As9GaiUsvbm0=
github.com/go-openapi/analysis v0.21.2/go.mod h1:HZwRk4RRisyG8vx2Oe6aqeSQcoxRp47Xkp3+K6q+LdY=
@@ -219,23 +227,24 @@ github.com/go-openapi/errors v0.20.2/go.mod h1:cM//ZKUKyO06HSwqAelJ5NsEMMcpa6VpX
github.com/go-openapi/errors v0.20.3 h1:rz6kiC84sqNQoqrtulzaL/VERgkoCyB6WdEkc2ujzUc=
github.com/go-openapi/errors v0.20.3/go.mod h1:Z3FlZ4I8jEGxjUK+bugx3on2mIAk4txuAOhlsB1FSgk=
github.com/go-openapi/jsonpointer v0.19.3/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg=
github.com/go-openapi/jsonpointer v0.19.5 h1:gZr+CIYByUqjcgeLXnQu2gHYQC9o73G2XUeOFYEICuY=
github.com/go-openapi/jsonpointer v0.19.5/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg=
github.com/go-openapi/jsonpointer v0.19.6 h1:eCs3fxoIi3Wh6vtgmLTOjdhSpiqphQ+DaPn38N2ZdrE=
github.com/go-openapi/jsonpointer v0.19.6/go.mod h1:osyAmYz/mB/C3I+WsTTSgw1ONzaLJoLCyoi6/zppojs=
github.com/go-openapi/jsonreference v0.19.6/go.mod h1:diGHMEHg2IqXZGKxqyvWdfWU/aim5Dprw5bqpKkTvns=
github.com/go-openapi/jsonreference v0.20.0 h1:MYlu0sBgChmCfJxxUKZ8g1cPWFOB37YSZqewK7OKeyA=
github.com/go-openapi/jsonreference v0.20.0/go.mod h1:Ag74Ico3lPc+zR+qjn4XBUmXymS4zJbYVCZmcgkasdo=
github.com/go-openapi/jsonreference v0.20.2 h1:3sVjiK66+uXK/6oQ8xgcRKcFgQ5KXa2KvnJRumpMGbE=
github.com/go-openapi/jsonreference v0.20.2/go.mod h1:Bl1zwGIM8/wsvqjsOQLJ/SH+En5Ap4rVB5KVcIDZG2k=
github.com/go-openapi/loads v0.21.1/go.mod h1:/DtAMXXneXFjbQMGEtbamCZb+4x7eGwkvZCvBmwUG+g=
github.com/go-openapi/loads v0.21.2 h1:r2a/xFIYeZ4Qd2TnGpWDIQNcP80dIaZgf704za8enro=
github.com/go-openapi/loads v0.21.2/go.mod h1:Jq58Os6SSGz0rzh62ptiu8Z31I+OTHqmULx5e/gJbNw=
github.com/go-openapi/runtime v0.24.2 h1:yX9HMGQbz32M87ECaAhGpJjBmErO3QLcgdZj9BzGx7c=
github.com/go-openapi/runtime v0.24.2/go.mod h1:AKurw9fNre+h3ELZfk6ILsfvPN+bvvlaU/M9q/r9hpk=
github.com/go-openapi/runtime v0.25.0 h1:7yQTCdRbWhX8vnIjdzU8S00tBYf7Sg71EBeorlPHvhc=
github.com/go-openapi/runtime v0.25.0/go.mod h1:Ux6fikcHXyyob6LNWxtE96hWwjBPYF0DXgVFuMTneOs=
github.com/go-openapi/spec v0.20.4/go.mod h1:faYFR1CvsJZ0mNsmsphTMSoRrNV3TEDoAM7FOEWeq8I=
github.com/go-openapi/spec v0.20.6/go.mod h1:2OpW+JddWPrpXSCIX8eOx7lZ5iyuWj3RYR6VaaBKcWA=
github.com/go-openapi/spec v0.20.7 h1:1Rlu/ZrOCCob0n+JKKJAWhNWMPW8bOZRg8FJaY+0SKI=
github.com/go-openapi/spec v0.20.7/go.mod h1:2OpW+JddWPrpXSCIX8eOx7lZ5iyuWj3RYR6VaaBKcWA=
github.com/go-openapi/spec v0.20.8 h1:ubHmXNY3FCIOinT8RNrrPfGc9t7I1qhPtdOGoG2AxRU=
github.com/go-openapi/spec v0.20.8/go.mod h1:2OpW+JddWPrpXSCIX8eOx7lZ5iyuWj3RYR6VaaBKcWA=
github.com/go-openapi/strfmt v0.21.0/go.mod h1:ZRQ409bWMj+SOgXofQAGTIo2Ebu72Gs+WaRADcS5iNg=
github.com/go-openapi/strfmt v0.21.1/go.mod h1:I/XVKeLc5+MM5oPNN7P6urMOpuLXEcNrCX/rPGuWb0k=
github.com/go-openapi/strfmt v0.21.2/go.mod h1:I/XVKeLc5+MM5oPNN7P6urMOpuLXEcNrCX/rPGuWb0k=
github.com/go-openapi/strfmt v0.21.3 h1:xwhj5X6CjXEZZHMWy1zKJxvW9AfHC9pkyUjLvHtKG7o=
github.com/go-openapi/strfmt v0.21.3/go.mod h1:k+RzNO0Da+k3FrrynSNN8F7n/peCmQQqbbXjtDfvmGg=
github.com/go-openapi/swag v0.19.5/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk=
@@ -243,15 +252,13 @@ github.com/go-openapi/swag v0.19.15/go.mod h1:QYRuS/SOXUCsnplDa677K7+DxSOj6IPNl/
github.com/go-openapi/swag v0.21.1/go.mod h1:QYRuS/SOXUCsnplDa677K7+DxSOj6IPNl/eQntq43wQ=
github.com/go-openapi/swag v0.22.3 h1:yMBqmnQ0gyZvEb/+KzuWZOXgllrXT4SADYbvDaXHv/g=
github.com/go-openapi/swag v0.22.3/go.mod h1:UzaqsxGiab7freDnrUUra0MwWfN/q7tE4j+VcZ0yl14=
github.com/go-openapi/validate v0.21.0/go.mod h1:rjnrwK57VJ7A8xqfpAOEKRH8yQSGUriMu5/zuPSQ1hg=
github.com/go-openapi/validate v0.22.0 h1:b0QecH6VslW/TxtpKgzpO1SNG7GU2FsaqKdP1E2T50Y=
github.com/go-openapi/validate v0.22.0/go.mod h1:rjnrwK57VJ7A8xqfpAOEKRH8yQSGUriMu5/zuPSQ1hg=
github.com/go-openapi/validate v0.22.1 h1:G+c2ub6q47kfX1sOBLwIQwzBVt8qmOAARyo/9Fqs9NU=
github.com/go-openapi/validate v0.22.1/go.mod h1:rjnrwK57VJ7A8xqfpAOEKRH8yQSGUriMu5/zuPSQ1hg=
github.com/go-resty/resty/v2 v2.1.1-0.20191201195748-d7b97669fe48/go.mod h1:dZGr0i9PLlaaTD4H/hoZIDjQ+r6xq8mgbRzHZf7f2J8=
github.com/go-resty/resty/v2 v2.7.0 h1:me+K9p3uhSmXtrBZ4k9jcEAfJmuC8IivWHwaLZwPrFY=
github.com/go-resty/resty/v2 v2.7.0/go.mod h1:9PWDzw47qPphMRFfhsyk0NnSgvluHcljSMVIq3w7q0I=
github.com/go-sql-driver/mysql v1.5.0/go.mod h1:DCzpHaOWr8IXmIStZouvnhqoel9Qv2LBy8hT2VhHyBg=
github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY=
github.com/go-stack/stack v1.8.1/go.mod h1:dcoOX6HbPZSZptuspn9bctJ+N/CnF5gGygcUP3XYfe4=
github.com/gobuffalo/attrs v0.0.0-20190224210810-a9411de4debd/go.mod h1:4duuawTqi2wkkpB4ePgWMaai6/Kc6WEz83bhFwpHzj0=
github.com/gobuffalo/depgen v0.0.0-20190329151759-d478694a28d3/go.mod h1:3STtPUQYuzV0gBVOY3vy6CfMm/ljR4pABfrTeHNLHUY=
github.com/gobuffalo/depgen v0.1.0/go.mod h1:+ifsuy7fhi15RWncXQQKjWS9JPkdah5sZvtHc2RXGlg=
@@ -380,8 +387,8 @@ github.com/hashicorp/go-cleanhttp v0.5.0/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtng
github.com/hashicorp/go-cleanhttp v0.5.1/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80=
github.com/hashicorp/go-hclog v0.9.1/go.mod h1:5CU+agLiy3J7N7QjHK5d05KxGsuXiQLrjA0H7acj2lQ=
github.com/hashicorp/go-hclog v0.9.2/go.mod h1:5CU+agLiy3J7N7QjHK5d05KxGsuXiQLrjA0H7acj2lQ=
github.com/hashicorp/go-hclog v1.3.1 h1:vDwF1DFNZhntP4DAjuTpOw3uEgMUpXh1pB5fW9DqHpo=
github.com/hashicorp/go-hclog v1.3.1/go.mod h1:W4Qnvbt70Wk/zYJryRzDRU/4r0kIg0PVHBcfoyhpF5M=
github.com/hashicorp/go-hclog v1.4.0 h1:ctuWFGrhFha8BnnzxqeRGidlEcQkDyL5u8J8t5eA11I=
github.com/hashicorp/go-hclog v1.4.0/go.mod h1:W4Qnvbt70Wk/zYJryRzDRU/4r0kIg0PVHBcfoyhpF5M=
github.com/hashicorp/go-immutable-radix v1.0.0/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60=
github.com/hashicorp/go-immutable-radix v1.3.1 h1:DKHmCUm2hRBK510BaiZlwvpD40f8bJFeZnpfm2KLowc=
github.com/hashicorp/go-immutable-radix v1.3.1/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60=
@@ -400,8 +407,10 @@ github.com/hashicorp/go-uuid v1.0.1/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/b
github.com/hashicorp/go.net v0.0.1/go.mod h1:hjKkEWcCURg++eb33jQU7oqQcI9XDCnUzHA0oac0k90=
github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8=
github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8=
github.com/hashicorp/golang-lru v0.5.4 h1:YDjusn29QI/Das2iO9M0BHnIbxPeyuCHsjMW+lJfyTc=
github.com/hashicorp/golang-lru v0.5.4/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4=
github.com/hashicorp/golang-lru v0.6.0 h1:uL2shRDx7RTrOrTCUZEGP/wJUFiUI8QT6E7z5o8jga4=
github.com/hashicorp/golang-lru v0.6.0/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4=
github.com/hashicorp/golang-lru/v2 v2.0.1 h1:5pv5N1lT1fjLg2VQ5KWc7kmucp2x/kvFOnxuVTqZ6x4=
github.com/hashicorp/golang-lru/v2 v2.0.1/go.mod h1:QeFd9opnmA6QUJc5vARoKUSoFhyfM2/ZepoAG6RGpeM=
github.com/hashicorp/hcl v1.0.0 h1:0Anlzjpi4vEasTeNFn2mLJgTSwt0+6sfsiTG8qcWGx4=
github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ=
github.com/hashicorp/logutils v1.0.0/go.mod h1:QIAnNjmIWmVIIkWDTG1z5v++HQmx9WQRO+LraFDTW64=
@@ -420,12 +429,11 @@ github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:
github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc=
github.com/iij/doapi v0.0.0-20190504054126-0bbf12d6d7df/go.mod h1:QMZY7/J/KSQEhKWFeDesPjMj+wCHReeknARU3wqlyN4=
github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8=
github.com/inconshreveable/mousetrap v1.0.1 h1:U3uMjPSQEBMNp1lFxmllqCPM6P5u/Xq7Pgzkat/bFNc=
github.com/inconshreveable/mousetrap v1.0.1/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw=
github.com/influxdata/influxdb1-client v0.0.0-20191209144304-8bf82d3c094d h1:/WZQPMZNsjZ7IlCpsLGdQBINg5bxKQ1K1sh6awxLtkA=
github.com/influxdata/influxdb1-client v0.0.0-20191209144304-8bf82d3c094d/go.mod h1:qj24IKcXYK6Iy9ceXlo3Tc+vtHo9lIhSX5JddghvEPo=
github.com/jedib0t/go-pretty/v6 v6.4.2 h1:DcJNSNIb1E17Tvy9w9S7z+sExvWvvjNbFdyr6C+FUL0=
github.com/jedib0t/go-pretty/v6 v6.4.2/go.mod h1:MgmISkTWDSFu0xOqiZ0mKNntMQ2mDgOcwOkwBEkMDJI=
github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2s0bqwp9tc8=
github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw=
github.com/jedib0t/go-pretty/v6 v6.4.4 h1:N+gz6UngBPF4M288kiMURPHELDMIhF/Em35aYuKrsSc=
github.com/jedib0t/go-pretty/v6 v6.4.4/go.mod h1:MgmISkTWDSFu0xOqiZ0mKNntMQ2mDgOcwOkwBEkMDJI=
github.com/jessevdk/go-flags v1.5.0 h1:1jKYvbxEjfUl0fmqTCOfonvskHHXMjBySTLW4y9LFvc=
github.com/jessevdk/go-flags v1.5.0/go.mod h1:Fw0T6WPc1dYxT4mKEZRfG5kJhaTDP9pj1c2EWnYs/m4=
github.com/jinzhu/copier v0.3.5 h1:GlvfUwHk62RokgqVNvYsku0TATCF7bAHVwEXoBh3iJg=
@@ -439,6 +447,8 @@ github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfC
github.com/joho/godotenv v1.3.0/go.mod h1:7hK45KPybAkOC6peb+G5yklZfMxEjkZhHbwpqxOKXbg=
github.com/josharian/intern v1.0.0 h1:vlS4z54oSdjm0bgjRigI+G1HpF+tI+9rE5LLzOg8HmY=
github.com/josharian/intern v1.0.0/go.mod h1:5DoeVV0s6jJacbCEi61lwdGj/aVlrQvzHFFd8Hwg//Y=
github.com/josharian/native v1.0.0 h1:Ts/E8zCSEsG17dUqv7joXJFybuMLjQfWE04tsBODTxk=
github.com/josharian/native v1.0.0/go.mod h1:7X/raswPFr05uY3HiLlYeyQntB6OO7E/d2Cu7qoaN2w=
github.com/json-iterator/go v1.1.5/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU=
github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU=
github.com/json-iterator/go v1.1.7/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4=
@@ -468,14 +478,15 @@ github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFB
github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo=
github.com/kr/pretty v0.2.0/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI=
github.com/kr/pretty v0.2.1 h1:Fmg33tUaq4/8ym9TJN1x7sLJnHVwhP33CNkpYV/7rwI=
github.com/kr/pretty v0.2.1/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI=
github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ=
github.com/kr/pty v1.1.8 h1:AkaSdXYQOWeaO3neb8EM634ahkXXe3jYbVh/F9lq+GI=
github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI=
github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY=
github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE=
github.com/kyokomi/emoji/v2 v2.2.8/go.mod h1:JUcn42DTdsXJo1SWanHh4HKDEyPaR5CqkmoirZZP9qE=
github.com/kyokomi/emoji/v2 v2.2.10 h1:1z5eMVcxFifsmEoNpdeq4UahbcicgQ4FEHuzrCVwmiI=
github.com/kyokomi/emoji/v2 v2.2.10/go.mod h1:JUcn42DTdsXJo1SWanHh4HKDEyPaR5CqkmoirZZP9qE=
github.com/kyokomi/emoji/v2 v2.2.11 h1:Pf/ZWVTbnAVkHOLJLWjPxM/FmgyPe+d85cv/OLP5Yus=
github.com/kyokomi/emoji/v2 v2.2.11/go.mod h1:JUcn42DTdsXJo1SWanHh4HKDEyPaR5CqkmoirZZP9qE=
github.com/labbsr0x/bindman-dns-webhook v1.0.2/go.mod h1:p6b+VCXIR8NYKpDr8/dg1HKfQoRHCdcsROXKvmoehKA=
github.com/labbsr0x/goh v1.0.1/go.mod h1:8K2UhVoaWXcCU7Lxoa2omWnC8gyW8px7/lmO61c027w=
github.com/linode/linodego v0.21.0/go.mod h1:UTpq1JUZD0CZsJ8rt+0CRkqbzrp1MbGakVPt2DXY5Mk=
@@ -486,8 +497,8 @@ github.com/lucasb-eyer/go-colorful v1.2.0/go.mod h1:R4dSotOR9KMtayYi1e77YzuveK+i
github.com/lucsky/cuid v1.2.1 h1:MtJrL2OFhvYufUIn48d35QGXyeTC8tn0upumW9WwTHg=
github.com/lucsky/cuid v1.2.1/go.mod h1:QaaJqckboimOmhRSJXSx/+IT+VTfxfPGSo/6mfgUfmE=
github.com/lufia/plan9stats v0.0.0-20211012122336-39d0f177ccd0/go.mod h1:zJYVVT2jmtg6P3p1VtQj7WsuWi/y4VnjVBn7F8KPB3I=
github.com/lufia/plan9stats v0.0.0-20220913051719-115f729f3c8c h1:VtwQ41oftZwlMnOEbMWQtSEUgU64U4s+GHk7hZK+jtY=
github.com/lufia/plan9stats v0.0.0-20220913051719-115f729f3c8c/go.mod h1:JKx41uQRwqlTZabZc+kILPrO/3jlKnQ2Z8b7YiVw5cE=
github.com/lufia/plan9stats v0.0.0-20230110061619-bbe2e5e100de h1:V53FWzU6KAZVi1tPp5UIsMoUWJ2/PNwYIDXnu7QuBCE=
github.com/lufia/plan9stats v0.0.0-20230110061619-bbe2e5e100de/go.mod h1:JKx41uQRwqlTZabZc+kILPrO/3jlKnQ2Z8b7YiVw5cE=
github.com/magiconair/properties v1.8.5 h1:b6kJs+EmPFMYGkow9GiUyCyOvIwYetYJ3fSaWak/Gls=
github.com/magiconair/properties v1.8.5/go.mod h1:y3VJvCyxH9uVvJTWEGAELF3aiYNyPKd5NZ3oSwXrF60=
github.com/mailru/easyjson v0.0.0-20190614124828-94de47d64c63/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc=
@@ -514,8 +525,9 @@ github.com/mattn/go-isatty v0.0.10/go.mod h1:qgIWMr58cqv1PHHyhnkY9lrL7etaEgOFcME
github.com/mattn/go-isatty v0.0.11/go.mod h1:PhnuNfih5lzO57/f3n+odYbM4JtupLOxQOAqxQCu2WE=
github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU=
github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27kJ6hsGG94=
github.com/mattn/go-isatty v0.0.16 h1:bq3VjFmv/sOjHtdEhmkEV4x1AJtvUvOJ2PFAZ5+peKQ=
github.com/mattn/go-isatty v0.0.16/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM=
github.com/mattn/go-isatty v0.0.17 h1:BTarxUcIeDqL27Mc+vyvdWYSL28zpIhv3RoTdsLMPng=
github.com/mattn/go-isatty v0.0.17/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM=
github.com/mattn/go-runewidth v0.0.2/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU=
github.com/mattn/go-runewidth v0.0.6/go.mod h1:H031xJmbD/WCDINGzjvQ9THkh0rPKHF+m2gUSrubnMI=
github.com/mattn/go-runewidth v0.0.7/go.mod h1:H031xJmbD/WCDINGzjvQ9THkh0rPKHF+m2gUSrubnMI=
@@ -528,6 +540,10 @@ github.com/mattn/go-tty v0.0.0-20180219170247-931426f7535a/go.mod h1:XPvLUNfbS4f
github.com/mattn/go-tty v0.0.3 h1:5OfyWorkyO7xP52Mq7tB36ajHDG5OHrmBGIS/DtakQI=
github.com/mattn/go-tty v0.0.3/go.mod h1:ihxohKRERHTVzN+aSVRwACLCeqIoZAWpoICkkvrWyR0=
github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0=
github.com/mdlayher/netlink v1.7.1 h1:FdUaT/e33HjEXagwELR8R3/KL1Fq5x3G5jgHLp/BTmg=
github.com/mdlayher/netlink v1.7.1/go.mod h1:nKO5CSjE/DJjVhk/TNp6vCE1ktVxEA8VEh8drhZzxsQ=
github.com/mdlayher/socket v0.4.0 h1:280wsy40IC9M9q1uPGcLBwXpcTQDtoGwVt+BNoITxIw=
github.com/mdlayher/socket v0.4.0/go.mod h1:xxFqz5GRCUN3UEOm9CZqEJsAbe1C8OwSK46NlmWuVoc=
github.com/mgutz/ansi v0.0.0-20170206155736-9520e82c474b/go.mod h1:01TrycV0kFyexm33Z7vhZRXopbI8J3TDReVlkTgMUxE=
github.com/mgutz/ansi v0.0.0-20200706080929-d51e80ef957d h1:5PJl274Y63IEHC+7izoQE9x6ikvDFZS2mDVS3drnohI=
github.com/mgutz/ansi v0.0.0-20200706080929-d51e80ef957d/go.mod h1:01TrycV0kFyexm33Z7vhZRXopbI8J3TDReVlkTgMUxE=
@@ -554,7 +570,6 @@ github.com/mitchellh/mapstructure v0.0.0-20160808181253-ca63d7c062ee/go.mod h1:F
github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y=
github.com/mitchellh/mapstructure v1.3.3/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo=
github.com/mitchellh/mapstructure v1.4.1/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo=
github.com/mitchellh/mapstructure v1.4.3/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo=
github.com/mitchellh/mapstructure v1.5.0 h1:jeMsZIYE/09sWLaz43PL7Gy6RuMjD2eJVyuac5Z2hdY=
github.com/mitchellh/mapstructure v1.5.0/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo=
github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q=
@@ -597,45 +612,45 @@ github.com/onsi/gomega v1.13.0 h1:7lLHu94wT9Ij0o6EWWclhu0aOh32VxhkwEJvzuWPeak=
github.com/opentracing/opentracing-go v1.2.0 h1:uEJPy/1a5RIPAJ0Ov+OIO8OxWu77jEv+1B0VhjKrZUs=
github.com/opentracing/opentracing-go v1.2.0/go.mod h1:GxEUsuufX4nBwe+T+Wl9TAgYrxe9dPLANfrWvHYVTgc=
github.com/openzipkin/zipkin-go v0.1.6/go.mod h1:QgAqvLzwWbR/WpD4A3cGpPtJrZXNIiJc5AZX7/PBEpw=
github.com/openziti/agent v1.0.5 h1:wZUcMYqvwspOjDSaejMtczSXnJoqK0edI9HcEIFsTIs=
github.com/openziti/agent v1.0.5/go.mod h1:6APWgkPP6Uxf1/VyirdTVLAJxwam2vVyakrVw6yvs40=
github.com/openziti/channel/v2 v2.0.15 h1:y1YwewnZTPTPtE3YVjaVpOWGoqJ3+I8+7KqQB4D3poQ=
github.com/openziti/channel/v2 v2.0.15/go.mod h1:LdoKRnefknW4WllUyHJtvKDtKK716lYdHqApKbBy3rk=
github.com/openziti/edge v0.24.50 h1:gmtjAJISV1mLXWSJmyRunVcZ6gk7WPS2aPkFaWh34uo=
github.com/openziti/edge v0.24.50/go.mod h1:71Cp8bypuFbJpt7FPsETZrmLdmHagFcWKDD+SzsIL0s=
github.com/openziti/fablab v0.4.15 h1:4sLJ9UC4rmpYOaxjTmwtfA2h/uwmVifwdpVJUBW6eQ4=
github.com/openziti/fablab v0.4.15/go.mod h1:FmnlfLEQUa/Gdf82wnkQLFe44lGexoIxGd+JOtRIMHs=
github.com/openziti/fabric v0.21.21 h1:vswdjm4xvZuCps62S4JjZZyA43YYLgc0uOCx6tdXWUY=
github.com/openziti/fabric v0.21.21/go.mod h1:F6L8c4AnNOACdx2IJqSW2JLG6J3Gm798BLL58sBYtZY=
github.com/openziti/foundation/v2 v2.0.7 h1:QtpP0ntUhr/7uLR1iM7eEkrusQ2b2ZqTblgdq8cac9Y=
github.com/openziti/foundation/v2 v2.0.7/go.mod h1:Z0gnQsGJb/H/B+pixLtmCIpw1dBllD4QoT6LeD35WzA=
github.com/openziti/identity v1.0.23 h1:SJ2UN3qCiUKwuwFc0dr3nuHyKvhOr5aN5bEJa2wY9Sw=
github.com/openziti/identity v1.0.23/go.mod h1:uVqZEC4Lr7pEud9b5g0h/cH0Ir5K0egCjUrEVup4ERc=
github.com/openziti/agent v1.0.8 h1:qB4zQO9dz3PL8qbeyzCWbwTrtHZPEZlYtjkJJ78SJPo=
github.com/openziti/agent v1.0.8/go.mod h1:6APWgkPP6Uxf1/VyirdTVLAJxwam2vVyakrVw6yvs40=
github.com/openziti/channel/v2 v2.0.26 h1:IIEnno26FuywcyCwCie1U7OHoB8HzuG95EzEnvtKmio=
github.com/openziti/channel/v2 v2.0.26/go.mod h1:zZO0bgVYY9FCDs2EMRakDl6wIfyOWuzgPzPL8EvQ5Ks=
github.com/openziti/edge v0.24.95 h1:Lj7ycWVOXbqt3TK6NSGPWXj5bp3/5rX7rA+bR5wA8Nc=
github.com/openziti/edge v0.24.95/go.mod h1:nVamtrBekK372q8bbKK/D6t0W7LBqQ+Miu0YE1u3od4=
github.com/openziti/fablab v0.4.23 h1:GKbSceX8hphBfY0RtYkrq7LTilnV61w4JCb4hh70Zio=
github.com/openziti/fablab v0.4.23/go.mod h1:ff6XCI4YryKcyhblK3zNVkiEH0JXDhO6ZkHQN4N0wDE=
github.com/openziti/fabric v0.22.7 h1:o0k/QnCpVZPiC77fh/NoUVCoeQNhfBm4oOICcJsdkWc=
github.com/openziti/fabric v0.22.7/go.mod h1:NITYnGTCeu0ENixTd7qXFzGyIDm5GkyJhxKYTnmFzjk=
github.com/openziti/foundation/v2 v2.0.10 h1:IeOkcPbgBpBTw4JrWz8s9Z76vO/m+i2uIE0cMZ0C2DM=
github.com/openziti/foundation/v2 v2.0.10/go.mod h1:Z0gnQsGJb/H/B+pixLtmCIpw1dBllD4QoT6LeD35WzA=
github.com/openziti/identity v1.0.30 h1:N2WDdK7MpeXuHCRjMo6N/QMtUXUkenUEqfKWXFNu2oE=
github.com/openziti/identity v1.0.30/go.mod h1:SPZAaqvDToS2jtae4D2fvO9IsR6G6FKNZ8WTqAwKKJE=
github.com/openziti/jwks v1.0.2 h1:32BGXIAnefS+v7uXKPb1x8/cQ7srek6Ai06dsrMTY4E=
github.com/openziti/jwks v1.0.2/go.mod h1:KwO0x9FBG0aoJS5f6nH5xeHoplyR1H143SMI9kF0mC8=
github.com/openziti/metrics v1.1.6 h1:fc4t5JEuYYr4gr+tF3qNpbvQ55QhoLyeOG+hiDfKLF8=
github.com/openziti/metrics v1.1.6/go.mod h1:07aMMS1VNzZvz0246fX73SFfuuoRz2nKcvDJumrVlZ0=
github.com/openziti/runzmd v1.0.3 h1:g+JyJS66ykMIidLTzroKBLwbsSF9S1hDvolj2PpD8lE=
github.com/openziti/runzmd v1.0.3/go.mod h1:2YuoQl5zZ6edfb+k1MjglW2cwfZvXwug2WldvBIUNrU=
github.com/openziti/sdk-golang v0.18.2 h1:RA+47vGtPwzqrgWlgTyqKurttvzhG25bu9qnhEU1Ghw=
github.com/openziti/sdk-golang v0.18.2/go.mod h1:79XTAIkizuRq5NpAex3Yg7oDH/fcNSlcrVeSiYEf2q0=
github.com/openziti/storage v0.1.26 h1:1tV4czY/TNmzX3raUZjbR8jVl5L92pdD0SjmdzCzUmE=
github.com/openziti/storage v0.1.26/go.mod h1:Zkm+4d2gckkIbuuCw/sKFWKKhPROZak3gLFzdII0KWQ=
github.com/openziti/transport/v2 v2.0.41 h1:T9RPXsJ0wbDgIx6mjKY1YDOg6ncRDmLPq8xU52B0mvU=
github.com/openziti/transport/v2 v2.0.41/go.mod h1:YM4hnHjHK1gQZuWgmDoPGSDP+8l7uT8kT8oBGM1u6nk=
github.com/openziti/metrics v1.2.3 h1:h9+mSU673QLSMOb3YibD1vNgE0yIDZ5leiUqDwN5szE=
github.com/openziti/metrics v1.2.3/go.mod h1:jK8BfZ9nXMhO+LPcUPpN/sebrLfIeF4uaHlm5JIF7BY=
github.com/openziti/runzmd v1.0.9 h1:gQnZT5cACuVpcBBBHWIaN9Vmwv8KUNa7LBLG8Xi13/U=
github.com/openziti/runzmd v1.0.9/go.mod h1:s6amx7gbzewUqlnq8dcvJ50eb0ryjQtknPYubOHuIug=
github.com/openziti/sdk-golang v0.18.26 h1:Wk2s88R9b5SeP3D3uEpqE31ffY20Y1v2ZSyYfgud/BA=
github.com/openziti/sdk-golang v0.18.26/go.mod h1:QCoDwqjGm8qxcIDboY+jglfjZVdz8gREquRMpX7jz8I=
github.com/openziti/storage v0.1.33 h1:c3jdiJPIthYC51Ye2VOBGuz3g1DGVzmjGIlgPs1BcOg=
github.com/openziti/storage v0.1.33/go.mod h1:G4swa9DU8oG+B+tv4X7X5QjtI8nxbXhEUKlDbwNowBY=
github.com/openziti/transport/v2 v2.0.50 h1:bMk0CeQhg61vaCpAUANlu+hZTqyZSa7IFX3ZYFi1tns=
github.com/openziti/transport/v2 v2.0.50/go.mod h1:I3qtYJhHzEzydqqdIq8IZStwPV7ybynK0mJP17MB/q0=
github.com/openziti/x509-claims v1.0.3 h1:HNdQ8Nf1agB3lBs1gahcO6zfkeS4S5xoQ2/PkY4HRX0=
github.com/openziti/x509-claims v1.0.3/go.mod h1:Z0WIpBm6c4ecrpRKrou6Gk2wrLWxJO/+tuUwKh8VewE=
github.com/openziti/xweb/v2 v2.0.2 h1:XYlVFriTq/U1wcUrc+XPnWJGhXh9NJPhtQ7+r3aC0cU=
github.com/openziti/xweb/v2 v2.0.2/go.mod h1:KQOOlnJk08EZT3TWkvDj/pbIUEVbgG0IrrNzl8gsi40=
github.com/openziti/ziti v0.26.11 h1:umXrmrBnbQeSV/hsKTdor/hWx/tJ5Hs/Xv/k5GXitL0=
github.com/openziti/ziti v0.26.11/go.mod h1:GJ6thwbiuCRf5rRO2/lalmvZVdWCQkLgiX7i8zAhuUo=
github.com/openziti/ziti v0.27.2 h1:OPNwVOy2OzucFrThOckWxr7GaD5CTBXsY2dZA23W5a4=
github.com/openziti/ziti v0.27.2/go.mod h1:ZnXzNonbbJPd+mmkeEY6moICdfNrdOs1DD8zdWDNMcc=
github.com/openziti/ziti-db-explorer v1.1.1 h1:G0eoTby+aIjjt5TxEfR+FMI2CWd4RvZFjzaIMX2lEBw=
github.com/openziti/ziti-db-explorer v1.1.1/go.mod h1:h76h7Tsb+khb0v+CqYKL6ifUfJbUMjGBFU2IvupfBE4=
github.com/openziti/zitilab v0.1.9 h1:NWUgq4ZyZIhXlH9HVL19JK6ArDnTNLnlKOteE6PLa8E=
github.com/openziti/zitilab v0.1.9/go.mod h1:ElsdjW6cyMBeLxda/n8DF9ec4KtZavys3hbYkgHpQf4=
github.com/openziti/zitilab v0.1.21 h1:ZZEq86qMvOAtzcgL1b2CqmZDnGqBH8cZ1nXcHdd3I+E=
github.com/openziti/zitilab v0.1.21/go.mod h1:CwMY50NZENpbVuSZMq+n8OngRVtoVe7qnZB/dEbmvcE=
github.com/oracle/oci-go-sdk v24.2.0+incompatible/go.mod h1:VQb79nF8Z2cwLkLS35ukwStZIg5F66tcBccjip/j888=
github.com/orcaman/concurrent-map/v2 v2.0.0 h1:iSMwuBQvQ1nX5i9gYuGMiSy0fjWHmazdjF+NdSO9JzI=
github.com/orcaman/concurrent-map/v2 v2.0.0/go.mod h1:9Eq3TG2oBe5FirmYWQfYO5iH1q0Jv47PLaNK++uCdOM=
github.com/orcaman/concurrent-map/v2 v2.0.1 h1:jOJ5Pg2w1oeB6PeDurIYf6k9PQ+aTITr/6lP/L/zp6c=
github.com/orcaman/concurrent-map/v2 v2.0.1/go.mod h1:9Eq3TG2oBe5FirmYWQfYO5iH1q0Jv47PLaNK++uCdOM=
github.com/ovh/go-ovh v1.1.0/go.mod h1:AxitLZ5HBRPyUd+Zl60Ajaag+rNTdVXWIkzfrVuTXWA=
github.com/parallaxsecond/parsec-client-go v0.0.0-20221025095442-f0a77d263cf9 h1:mOvehYivJ4Aqu2CPe3D3lv8jhqOI9/1o0THxJHBE0qw=
github.com/parallaxsecond/parsec-client-go v0.0.0-20221025095442-f0a77d263cf9/go.mod h1:gLH27qo/dvMhLTVVyMELpe3Tut7sOfkiDg7ZpeqKwsw=
@@ -663,8 +678,8 @@ github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZb
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
github.com/posener/complete v1.1.1/go.mod h1:em0nMJCgc9GFtwrmVmEMR/ZL6WyhyjMBndrE9hABlRI=
github.com/power-devops/perfstat v0.0.0-20210106213030-5aafc221ea8c/go.mod h1:OmDBASR4679mdNQnz2pUhc2G8CO2JrUAVFDRBDP/hJE=
github.com/power-devops/perfstat v0.0.0-20220216144756-c35f1ee13d7c h1:NRoLoZvkBTKvR5gQLgA3e0hqjkY9u1wm+iOL45VN/qI=
github.com/power-devops/perfstat v0.0.0-20220216144756-c35f1ee13d7c/go.mod h1:OmDBASR4679mdNQnz2pUhc2G8CO2JrUAVFDRBDP/hJE=
github.com/power-devops/perfstat v0.0.0-20221212215047-62379fc7944b h1:0LFwY6Q3gMACTjAbMZBjXAqTOzOwFaj2Ld6cjeQ7Rig=
github.com/power-devops/perfstat v0.0.0-20221212215047-62379fc7944b/go.mod h1:OmDBASR4679mdNQnz2pUhc2G8CO2JrUAVFDRBDP/hJE=
github.com/pquerna/otp v1.2.0/go.mod h1:dkJfzwRKNiegxyNb54X/3fLwhCynbMspSyWKnvi1AEg=
github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw=
github.com/prometheus/client_golang v0.9.2/go.mod h1:OsXs2jCmiKlQ1lTBmv21f2mNfw4xf/QclQDMrYNZzcM=
@@ -694,8 +709,8 @@ github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 h1:N/ElC8H3+5X
github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4=
github.com/rivo/uniseg v0.1.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc=
github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc=
github.com/rivo/uniseg v0.4.2 h1:YwD0ulJSJytLpiaWua0sBDusfsCZohxjxzVTYjwxfV8=
github.com/rivo/uniseg v0.4.2/go.mod h1:FN3SvrM+Zdj16jyLfmOkMNblXMcoc8DfTHruCPUcx88=
github.com/rivo/uniseg v0.4.3 h1:utMvzDsuh3suAEnhH0RdHmoPbU648o6CvXxTx4SBMOw=
github.com/rivo/uniseg v0.4.3/go.mod h1:FN3SvrM+Zdj16jyLfmOkMNblXMcoc8DfTHruCPUcx88=
github.com/rodaine/table v1.0.1 h1:U/VwCnUxlVYxw8+NJiLIuCxA/xa6jL38MY3FYysVWWQ=
github.com/rodaine/table v1.0.1/go.mod h1:UVEtfBsflpeEcD56nF4F5AocNFta0ZuolpSVdPtlmP4=
github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg=
@@ -711,8 +726,8 @@ github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb
github.com/sacloud/libsacloud v1.36.2/go.mod h1:P7YAOVmnIn3DKHqCZcUKYUXmSwGBm3yS7IBEjKVSrjg=
github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc=
github.com/sergi/go-diff v1.0.0/go.mod h1:0CfEIISq7TuYL3j771MWULgwwjU+GofnZX9QAmXWZgo=
github.com/shirou/gopsutil/v3 v3.22.10 h1:4KMHdfBRYXGF9skjDWiL4RA2N+E8dRdodU/bOZpPoVg=
github.com/shirou/gopsutil/v3 v3.22.10/go.mod h1:QNza6r4YQoydyCfo6rH0blGfKahgibh4dQmV5xdFkQk=
github.com/shirou/gopsutil/v3 v3.23.1 h1:a9KKO+kGLKEvcPIs4W62v0nu3sciVDOOOPUD0Hz7z/4=
github.com/shirou/gopsutil/v3 v3.23.1/go.mod h1:NN6mnm5/0k8jw4cBfCnJtr5L7ErOTg18tMNpgFkn0hA=
github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc=
github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo=
github.com/sirupsen/logrus v1.4.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo=
@@ -771,10 +786,8 @@ github.com/teris-io/shortid v0.0.0-20201117134242-e59966efd125 h1:3SNcvBmEPE1YlB
github.com/teris-io/shortid v0.0.0-20201117134242-e59966efd125/go.mod h1:M8agBzgqHIhgj7wEn9/0hJUZcrvt9VY+Ln+S1I5Mha0=
github.com/tidwall/pretty v1.0.0 h1:HsD+QiTn7sK6flMKIvNmpqz1qrpP3Ps6jOKIKMooyg4=
github.com/tidwall/pretty v1.0.0/go.mod h1:XNkn88O1ChpSDQmQeStsy+sBenx6DDtFZJxhVysOjyk=
github.com/tklauser/go-sysconf v0.3.10/go.mod h1:C8XykCvCb+Gn0oNCWPIlcb0RuglQTYaQ2hGm7jmxEFk=
github.com/tklauser/go-sysconf v0.3.11 h1:89WgdJhk5SNwJfu+GKyYveZ4IaJ7xAkecBo+KdJV0CM=
github.com/tklauser/go-sysconf v0.3.11/go.mod h1:GqXfhXY3kiPa0nAXPDIQIWzJbMCB7AmcWpGR8lSZfqI=
github.com/tklauser/numcpus v0.4.0/go.mod h1:1+UI3pD8NW14VMwdgJNJ1ESk2UnwhAnz5hMwiKKqXCQ=
github.com/tklauser/numcpus v0.6.0 h1:kebhY2Qt+3U6RNK7UqpYNA+tJ23IBEGKkB7JQBfDYms=
github.com/tklauser/numcpus v0.6.0/go.mod h1:FEZLMke0lhOUG6w2JadTzp0a+Nl8PF/GFkQ5UVIcaL4=
github.com/transip/gotransip/v6 v6.2.0/go.mod h1:pQZ36hWWRahCUXkFWlx9Hs711gLd8J4qdgLdRzmtY+g=
@@ -806,16 +819,16 @@ github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1
github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY=
github.com/yusufpapurcu/wmi v1.2.2 h1:KBNDSne4vP5mbSWnJbO+51IMOXJB67QiYCSBrubbPRg=
github.com/yusufpapurcu/wmi v1.2.2/go.mod h1:SBZ9tNy3G9/m5Oi98Zks0QjeHVDvuK0qfxQmPyzfmi0=
go.etcd.io/bbolt v1.3.6 h1:/ecaJf0sk1l4l6V4awd65v2C3ILy7MSj+s/x1ADCIMU=
go.etcd.io/bbolt v1.3.6/go.mod h1:qXsaaIqmgQH0T+OPdb99Bf+PKfBBQVAdyD6TY9G8XM4=
go.etcd.io/bbolt v1.3.7 h1:j+zJOnnEjF/kyHlDDgGnVL/AIqIJPq8UoB2GSNfkUfQ=
go.etcd.io/bbolt v1.3.7/go.mod h1:N9Mkw9X8x5fupy0IKsmuqVtoGDyxsaDlbk4Rd05IAQw=
go.etcd.io/etcd/api/v3 v3.5.0/go.mod h1:cbVKeC6lCfl7j/8jBhAK6aIYO9XOjdptoxU/nLQcPvs=
go.etcd.io/etcd/client/pkg/v3 v3.5.0/go.mod h1:IJHfcCEKxYu1Os13ZdwCwIUTUVGYTSAM3YSwc9/Ac1g=
go.etcd.io/etcd/client/v2 v2.305.0/go.mod h1:h9puh54ZTgAKtEbut2oe9P4L/oqKCVB6xsXlzd7alYQ=
go.mongodb.org/mongo-driver v1.7.3/go.mod h1:NqaYOwnXWr5Pm7AOpO5QFxKJ503nbMse/R79oO62zWg=
go.mongodb.org/mongo-driver v1.7.5/go.mod h1:VXEWRZ6URJIkUq2SCAyapmhH0ZLRBP+FT4xhp5Zvxng=
go.mongodb.org/mongo-driver v1.8.3/go.mod h1:0sQWfOeY63QTntERDJJ/0SuKK0T1uVSgKCuAROlKEPY=
go.mongodb.org/mongo-driver v1.10.0 h1:UtV6N5k14upNp4LTduX0QCufG124fSu25Wz9tu94GLg=
go.mongodb.org/mongo-driver v1.10.0/go.mod h1:wsihk0Kdgv8Kqu1Anit4sfK+22vSFbUrAVEYRhCXrA8=
go.mongodb.org/mongo-driver v1.11.1 h1:QP0znIRTuL0jf1oBQoAoM0C6ZJfBK4kx0Uumtv1A7w8=
go.mongodb.org/mongo-driver v1.11.1/go.mod h1:s7p5vEtfbeR1gYi6pnj3c3/urpbLv2T5Sfd6Rp2HBB8=
go.mozilla.org/pkcs7 v0.0.0-20210826202110-33d05740a352 h1:CCriYyAfq1Br1aIYettdHZTy8mBTIPo7We18TuO/bak=
go.mozilla.org/pkcs7 v0.0.0-20210826202110-33d05740a352/go.mod h1:SNgMg+EgDFwmvSmLRTNKC5fegJjB7v23qTQ0XLGUNHk=
go.opencensus.io v0.20.1/go.mod h1:6WKK9ahsWS3RSO+PY9ZHZUfv2irvY6gN279GOPZjmmk=
@@ -827,6 +840,11 @@ go.opencensus.io v0.22.3/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
go.opencensus.io v0.22.4/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
go.opencensus.io v0.22.5/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk=
go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E=
go.opentelemetry.io/otel v1.11.2 h1:YBZcQlsVekzFsFbjygXMOXSs6pialIZxcjfO/mBDmR0=
go.opentelemetry.io/otel v1.11.2/go.mod h1:7p4EUV+AqgdlNV9gL97IgUZiVR3yrFXYo53f9BM3tRI=
go.opentelemetry.io/otel/sdk v1.11.1 h1:F7KmQgoHljhUuJyA+9BiU+EkJfyX5nVVF4wyzWZpKxs=
go.opentelemetry.io/otel/trace v1.11.2 h1:Xf7hWSF2Glv0DE3MH7fBHvtpSBsjcBUe5MYAmZM/+y0=
go.opentelemetry.io/otel/trace v1.11.2/go.mod h1:4N+yC7QEz7TTsG9BSRLNAa63eg5E06ObSbKPmxQ/pKA=
go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE=
go.uber.org/atomic v1.7.0/go.mod h1:fEN4uk6kAWBTFdckzkM89CLk9XfWZrxpCo0nPH17wJc=
go.uber.org/multierr v1.6.0/go.mod h1:cdWPpRnG4AhwMwsgIHip0KRBQjJy5kYEpYjJxpXp9iU=
@@ -848,13 +866,12 @@ golang.org/x/crypto v0.0.0-20191202143827-86a70503ff7e/go.mod h1:LzIPMQfyMNhhGPh
golang.org/x/crypto v0.0.0-20200204104054-c9f3fb736b72/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
golang.org/x/crypto v0.0.0-20200302210943-78000ba7a073/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
golang.org/x/crypto v0.0.0-20201216223049-8b5274cf687f/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I=
golang.org/x/crypto v0.0.0-20210616213533-5ff15b29337e/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
golang.org/x/crypto v0.0.0-20211215153901-e495a2d5b3d3/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4=
golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4=
golang.org/x/crypto v0.3.0 h1:a06MkbcxBrEFc0w0QIZWXrH/9cCX6KJyWbBOIwAn+7A=
golang.org/x/crypto v0.3.0/go.mod h1:hebNnKkNXi2UzZN1eVRvBB7co0a+JxK6XbPiWVs/3J4=
golang.org/x/crypto v0.5.0 h1:U/0M97KRkSFvyD/3FSmdP5W5swImpNgle/EHFhOsQPE=
golang.org/x/crypto v0.5.0/go.mod h1:NK/OQwhpMQP3MwtdjgLlYHnH9ebylxKWv3e0fK+mkQU=
golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8=
@@ -865,14 +882,14 @@ golang.org/x/exp v0.0.0-20191227195350-da58074b4299/go.mod h1:2RIsYlXP63K8oxa1u0
golang.org/x/exp v0.0.0-20200119233911-0405dc783f0a/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4=
golang.org/x/exp v0.0.0-20200207192155-f17229e696bd/go.mod h1:J/WKrq2StrnmMY6+EHIKF9dgMWnmCNThgcyBT1FY9mM=
golang.org/x/exp v0.0.0-20200224162631-6cc2880d07d6/go.mod h1:3jZMyOhIsHpP37uCMkUooju7aAi5cS1Q23tOzKc+0MU=
golang.org/x/exp v0.0.0-20221126150942-6ab00d035af9 h1:yZNXmy+j/JpX19vZkVktWqAo7Gny4PBWYYK3zskGpx4=
golang.org/x/exp v0.0.0-20221126150942-6ab00d035af9/go.mod h1:CxIveKay+FTh1D0yPZemJVgC/95VzuuOLq5Qi4xnoYc=
golang.org/x/exp v0.0.0-20230202163644-54bba9f4231b h1:EqBVA+nNsObCwQoBEHy4wLU0pi7i8a4AL3pbItPdPkE=
golang.org/x/exp v0.0.0-20230202163644-54bba9f4231b/go.mod h1:CxIveKay+FTh1D0yPZemJVgC/95VzuuOLq5Qi4xnoYc=
golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js=
golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0=
golang.org/x/image v0.0.0-20191009234506-e7c1f5e7dbb8/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0=
golang.org/x/image v0.0.0-20191206065243-da761ea9ff43/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0=
golang.org/x/image v0.1.0 h1:r8Oj8ZA2Xy12/b5KZYj3tuv7NG/fBz3TwQVvpJ9l8Rk=
golang.org/x/image v0.1.0/go.mod h1:iyPr49SD/G/TBxYVB/9RRtGUT5eNbo2u4NamWeQcD5c=
golang.org/x/image v0.3.0 h1:HTDXbdK9bjfSWkPzDJIw89W8CAtfFGduujWs33NLLsg=
golang.org/x/image v0.3.0/go.mod h1:fXd9211C/0VTlYuAcOhW8dY/RtEJqODXOWBDpmYBf+A=
golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU=
golang.org/x/lint v0.0.0-20190301231843-5614ed5bae6f/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
@@ -951,8 +968,8 @@ golang.org/x/net v0.0.0-20211029224645-99673261e6eb/go.mod h1:9nx3DQGgdP8bBQD5qx
golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.0.0-20220127200216-cd36cc0744dd/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk=
golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c=
golang.org/x/net v0.2.0 h1:sZfSu1wtKLGlWI4ZZayP0ck9Y73K1ynO6gqzTdBVdPU=
golang.org/x/net v0.2.0/go.mod h1:KqCZLdyyvdV855qA2rE3GC2aiw5xGR5TEjj8smXukLY=
golang.org/x/net v0.5.0 h1:GyT4nK/YDHSqa1c4753ouYCDajOYKTja9Xb/OHtgvSw=
golang.org/x/net v0.5.0/go.mod h1:DivGGAXEgPSlEBzxGzZI+ZLohi+xUj054jfeKui00ws=
golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U=
golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
@@ -1033,7 +1050,6 @@ golang.org/x/sys v0.0.0-20200803210538-64077c9b5642/go.mod h1:h1NjWce9XRLGQEsW7w
golang.org/x/sys v0.0.0-20200905004654-be1d3432aa8f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200909081042-eff7692f9009/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200918174421-af09f7315aff/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200923182605-d9f96fdee20d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20201201145000-ef89a241ccb3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
@@ -1054,20 +1070,19 @@ golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBc
golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220128215802-99c3d69c2c27/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220503163025-988cb79eb6c6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220908164124-27713097b956/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.2.0 h1:ljd4t30dBnAvMZaQCevtY0xLLD0A+bRZXbgLMLU1F/A=
golang.org/x/sys v0.2.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw=
golang.org/x/sys v0.4.0 h1:Zr2JFtRQNX3BCZ8YtxRE9hNJYC8J6I1MVbMg6owUp18=
golang.org/x/sys v0.4.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8=
golang.org/x/term v0.2.0 h1:z85xZCsEl7bi/KwbNADeBYoOP0++7W1ipu+aGnpwzRM=
golang.org/x/term v0.2.0/go.mod h1:TVmDHMZPmdnySmBfhjOoOdhjzdE1h4u1VwSiw2l1Nuc=
golang.org/x/term v0.4.0 h1:O7UWfv5+A2qiuulQk30kVinPoMtoIPeVaKLEgLpVkvg=
golang.org/x/term v0.4.0/go.mod h1:9P2UbLfCdcvo3p/nzKvsmas4TnlujnuoV9hGgYzW1lQ=
golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
@@ -1077,8 +1092,8 @@ golang.org/x/text v0.3.4/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ=
golang.org/x/text v0.4.0 h1:BrVqGRd7+k1DiOgtnFvAkoQEWQvBc25ouMJM6429SFg=
golang.org/x/text v0.4.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8=
golang.org/x/text v0.6.0 h1:3XmdazWV+ubf7QgHSTWeykHOci5oeekaGJBLkrkaw4k=
golang.org/x/text v0.6.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8=
golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
@@ -1266,6 +1281,7 @@ gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8
gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/check.v1 v1.0.0-20200902074654-038fdea0a05b/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk=
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q=
gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI=
gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys=
gopkg.in/h2non/gock.v1 v1.0.15/go.mod h1:sX4zAkdYX1TRGJ2JY156cFspQn4yRWn6p9EMdODlynE=
+9 -30
View File
@@ -3,13 +3,9 @@ v: 3
db: /home/{{ .Model.MustVariable "credentials.ssh.username" }}/fablab/ctrl.db
identity:
cert: /home/{{ .Model.MustVariable "credentials.ssh.username" }}/fablab/pki/intermediate/certs/{{ .Component.PublicIdentity }}-client.cert
server_cert: /home/{{ .Model.MustVariable "credentials.ssh.username" }}/fablab/pki/intermediate/certs/{{ .Component.PublicIdentity }}-server.cert
key: /home/{{ .Model.MustVariable "credentials.ssh.username" }}/fablab/pki/intermediate/keys/{{ .Component.PublicIdentity }}.key
ca: /home/{{ .Model.MustVariable "credentials.ssh.username" }}/fablab/pki/intermediate/certs/{{ .Component.PublicIdentity }}-server.chain.pem
#trace:
# path: ctrl.trace
cert: /home/{{ .Model.MustVariable "credentials.ssh.username" }}/fablab/pki/ctrl/certs/{{ .Component.PublicIdentity }}-server.cert
key: /home/{{ .Model.MustVariable "credentials.ssh.username" }}/fablab/pki/ctrl/keys/{{ .Component.PublicIdentity }}-server.key
ca: /home/{{ .Model.MustVariable "credentials.ssh.username" }}/fablab/pki/ctrl/certs/{{ .Component.PublicIdentity }}-server.chain.pem
profile:
# cpu:
@@ -21,6 +17,7 @@ profile:
ctrl:
listener: tls:0.0.0.0:6262
options:
advertiseAddress: tls:{{.Host.PublicIp}}:6262
# (optional) settings
# set the maximum number of connect requests that are buffered and waiting to be acknowledged (1 to 5000, default 1000)
#maxQueuedConnects: 50
@@ -39,18 +36,6 @@ ctrl:
# connections. The value of newListener must be resolvable both via DNS and validate via certificates
#newListener: tls:localhost:6262
# the endpoint that management tools connect to the controller over.
mgmt:
listener: tls:0.0.0.0:10000
#options:
# (optional) settings
# set the maximum number of connect requests that are buffered and waiting to be acknowledged (1 to 5000, default 1000)
#maxQueuedConnects: 50
# the maximum number of connects that have begun hello synchronization (1 to 1000, default 16)
#maxOutstandingConnects: 100
# the number of milliseconds to wait before a hello synchronization fails and closes the connection (30ms to 60000ms, default: 1000ms)
#connectTimeoutMs: 3000
#metrics:
#file:
#path: /tmp/ziti-controller-metrics.log
@@ -87,12 +72,6 @@ mgmt:
# format: json
# path: /tmp/ziti-events.log
# xctrl_example
#
#example:
# enabled: false
# delay: 5
healthChecks:
boltCheck:
# How often to try entering a bolt read tx. Defaults to 30 seconds
@@ -127,8 +106,8 @@ edge:
# a signing certificate from the PKI that the Ziti environment is using to sign certificates. The signingCert.cert
# will be added to the /.well-known CA store that is used to bootstrap trust with the Ziti Controller.
signingCert:
cert: /home/{{ .Model.MustVariable "credentials.ssh.username" }}/fablab/pki/intermediate/certs/intermediate.cert
key: /home/{{ .Model.MustVariable "credentials.ssh.username" }}/fablab/pki/intermediate/keys/intermediate.key
cert: /home/{{ .Model.MustVariable "credentials.ssh.username" }}/fablab/pki/ctrl/certs/ctrl.cert
key: /home/{{ .Model.MustVariable "credentials.ssh.username" }}/fablab/pki/ctrl/keys/ctrl.key
# edgeIdentity - optional
# A section for identity enrollment specific settings
@@ -220,13 +199,13 @@ web:
# - edge-client
# - fabric-management
- binding: health-checks
options: { }
options: {}
- binding: fabric
- binding: edge-management
# options - variable optional/required
# This section is used to define values that are specified by the API they are associated with.
# These settings are per API. The example below is for the `edge-api` and contains both optional values and
# required values.
options: { }
options: {}
- binding: edge-client
options: { }
options: {}
@@ -8,10 +8,10 @@ v: 3
enableDebugOps: true
identity:
cert: /home/{{$ssh_username}}/fablab/pki/intermediate/certs/{{$identity}}-client.cert
server_cert: /home/{{$ssh_username}}/fablab/pki/intermediate/certs/{{$identity}}-server.cert
key: /home/{{$ssh_username}}/fablab/pki/intermediate/keys/{{$identity}}.key
ca: /home/{{$ssh_username}}/fablab/pki/intermediate/certs/{{$identity}}-server.chain.pem
cert: /home/{{$ssh_username}}/fablab/cfg/{{$identity}}-client.cert
server_cert: /home/{{$ssh_username}}/fablab/cfg/{{$identity}}-server.cert
key: /home/{{$ssh_username}}/fablab/cfg/{{$identity}}.key
ca: /home/{{$ssh_username}}/fablab/cfg/{{$identity}}-server.chain.pem
ctrl:
endpoint: tls:{{$ctrl_ip}}:6262
+1 -2
View File
@@ -177,8 +177,7 @@ var m = &model.Model{
Configuration: model.ConfigurationStages{
zitilib_runlevel_1_configuration.IfPkiNeedsRefresh(
zitilib_runlevel_1_configuration.Fabric(),
zitilib_runlevel_1_configuration.DotZiti(),
zitilib_runlevel_1_configuration.Fabric("simple-transfer.test", "#ctrl"),
),
config.Component(),
devkit.DevKitF(zitilab.ZitiRoot, []string{"ziti", "ziti-echo"}),
+17 -12
View File
@@ -1,18 +1,23 @@
# OpenZiti Variables
ZITI_IMAGE=openziti/quickstart
ZITI_VERSION=latest
ZITI_CONTROLLER_RAWNAME=ziti-controller
ZITI_EDGE_CONTROLLER_RAWNAME=ziti-edge-controller
# The duration of the enrollment period (in minutes), default if not set
ZITI_EDGE_IDENTITY_ENROLLMENT_DURATION=
ZITI_EDGE_ROUTER_ENROLLMENT_DURATION=
# shown - 7days
ZITI_EDGE_IDENTITY_ENROLLMENT_DURATION=10080
ZITI_EDGE_ROUTER_ENROLLMENT_DURATION=10080
## Additional variables to override.
#ZITI_EDGE_CONTROLLER_RAWNAME=some.other.name.com
#ZITI_EDGE_CTRL_ADVERTISED_HOST_PORT=some.other.name.com:1280
#ZITI_EDGE_CONTROLLER_HOSTNAME=some.other.name.com
#ZITI_EDGE_CONTROLLER_IP_OVERRIDE=20.20.20.20
#ZITI_CTRL_ADVERTISED_ADDRESS=some.other.name.com
#ZITI_CONTROLLER_HOSTNAME=some.other.name.com
#ZITI_CTRL_PORT=6262
# controller address/port information
ZITI_CONTROLLER_RAWNAME=ziti-controller
#ZITI_CONTROLLER_HOSTNAME=advertised.address
#ZITI_CTRL_PORT=8440
ZITI_EDGE_CONTROLLER_RAWNAME=ziti-edge-controller
#ZITI_EDGE_CONTROLLER_HOSTNAME=advertised.address
#ZITI_EDGE_CONTROLLER_PORT=8441
#ZITI_EDGE_CONTROLLER_IP_OVERRIDE=172.17.0.1
# router address/port information
#ZITI_EDGE_ROUTER_RAWNAME=advertised.address
#ZITI_EDGE_ROUTER_PORT=8442
#ZITI_EDGE_ROUTER_IP_OVERRIDE=172.17.0.1
+11 -10
View File
@@ -5,8 +5,8 @@ services:
env_file:
- ./.env
ports:
- "${ZITI_EDGE_CONTROLLER_PORT}:${ZITI_EDGE_CONTROLLER_PORT}"
- "${ZITI_CTRL_PORT}:${ZITI_CTRL_PORT}"
- ${ZITI_EDGE_CONTROLLER_PORT:-1280}:${ZITI_EDGE_CONTROLLER_PORT:-1280}
- ${ZITI_CTRL_PORT:-6262}:${ZITI_CTRL_PORT:-6262}
environment:
- ZITI_EDGE_IDENTITY_ENROLLMENT_DURATION=${ZITI_EDGE_IDENTITY_ENROLLMENT_DURATION}
- ZITI_EDGE_ROUTER_ENROLLMENT_DURATION=${ZITI_EDGE_ROUTER_ENROLLMENT_DURATION}
@@ -52,10 +52,10 @@ services:
environment:
- ZITI_CONTROLLER_RAWNAME="${ZITI_CONTROLLER_RAWNAME}"
- ZITI_EDGE_CONTROLLER_RAWNAME="${ZITI_EDGE_CONTROLLER_RAWNAME}"
- ZITI_EDGE_ROUTER_RAWNAME=ziti-edge-router
- ZITI_EDGE_ROUTER_RAWNAME=${ZITI_EDGE_ROUTER_RAWNAME:-ziti-edge-router}
- ZITI_EDGE_ROUTER_ROLES=public
ports:
- "3022:3022"
- ${ZITI_EDGE_ROUTER_PORT:-3022}:${ZITI_EDGE_ROUTER_PORT:-3022}
networks:
- zitiblue
- zitired
@@ -75,7 +75,7 @@ services:
- ZITI_EDGE_ROUTER_PORT=3023
- ZITI_EDGE_ROUTER_ROLES=public
ports:
- "3023:3023"
- 3023:3023
networks:
- zitiblue
- zitired
@@ -139,7 +139,7 @@ services:
web-test-blue:
image: crccheck/hello-world
ports:
- "80:8000"
- 80:8000
networks:
zitiblue:
aliases:
@@ -150,11 +150,12 @@ services:
ziti-console:
image: openziti/zac
environment:
- ZAC_SERVER_CERT_CHAIN=/persistent/pki/ziti-controller-intermediate/certs/ziti-controller-server.cert
- ZAC_SERVER_KEY=/persistent/pki/ziti-controller-intermediate/keys/ziti-controller-server.key
- ZAC_SERVER_CERT_CHAIN=/persistent/pki/${ZITI_EDGE_CONTROLLER_HOSTNAME:-ziti-controller}-intermediate/certs/${ZITI_EDGE_CONTROLLER_HOSTNAME:-ziti-controller}-server.cert
- ZAC_SERVER_KEY=/persistent/pki/${ZITI_EDGE_CONTROLLER_HOSTNAME:-ziti-controller}-intermediate/keys/${ZITI_EDGE_CONTROLLER_HOSTNAME:-ziti-controller}-server.key
- PORTTLS=8443
ports:
- "1408:1408"
- "8443:8443"
- 1408:1408
- 8443:8443
working_dir: /usr/src/app
volumes:
- ziti-fs:/persistent
+13 -1
View File
@@ -1,3 +1,15 @@
FROM ubuntu:rolling as fetch-ziti-bins
# optional arg to specify which version to fetch when local "ziti-bin" directory is not present
ARG ZITI_VERSION_OVERRIDE
COPY . /docker.build.context
RUN apt update && apt install jq curl -y && \
# get local ziti build in "ziti-bin", if present.
# otherwise fetch from releases (respecting ZITI_VERSION_OVERRIDE, if set).
# put the result in /ziti-bin
/bin/bash /docker.build.context/fetch-ziti-bins.sh /ziti-bin
FROM ubuntu:rolling
RUN apt update && \
@@ -20,7 +32,7 @@ ENV ZITI_BIN_ROOT="${ZITI_BIN_DIR}"
ENV ZITI_SCRIPTS=/var/openziti/scripts
# copy the ziti binaries to a directory already on the path
COPY --chown=ziti ziti.ignore "${ZITI_BIN_DIR}"
COPY --chown=ziti --from=fetch-ziti-bins /ziti-bin "${ZITI_BIN_DIR}"
COPY --chown=ziti ziti-cli-functions.sh "${ZITI_SCRIPTS}/"
COPY --chown=ziti run-controller.sh "${ZITI_SCRIPTS}/"
COPY --chown=ziti run-router.sh "${ZITI_SCRIPTS}/"
@@ -0,0 +1,13 @@
#!/bin/bash
# this script is executed during the docker build, after the build context has been copied to /docker.build.context
dest="${1}"
if [ -d /docker.build.context/ziti-bin -a ]; then
mv /docker.build.context/ziti-bin/ "${dest}"
else
source /docker.build.context/ziti-cli-functions.sh
getZiti
mv "${ZITI_BIN_DIR}" "${dest}"
fi
@@ -173,6 +173,7 @@ function verifyZitiVersionExists {
}
function detectArchitecture {
if [ -n "${ZITI_ARCH}" ]; then return; fi
ZITI_ARCH="amd64"
detected_arch="$(uname -m)"
# Apple M1 silicon
@@ -238,7 +239,7 @@ function getZiti {
if [[ "${ZITI_BIN_DIR-}" == "" ]]; then export ZITI_BIN_DIR="${ziti_bin_root}/ziti-${ZITI_BINARIES_VERSION}"; else echo "Using ZITI_BIN_DIR: ${ZITI_BIN_DIR}"; fi
ZITI_BINARIES_FILE_ABSPATH="${ZITI_HOME-}/ziti-bin/${ZITI_BINARIES_FILE}"
ZITI_BINARIES_FILE_ABSPATH="${ziti_bin_root}/${ZITI_BINARIES_FILE}"
if ! test -f "${ZITI_BINARIES_FILE_ABSPATH}"; then
zitidl="https://github.com/openziti/ziti/releases/download/${ZITI_BINARIES_VERSION-}/${ZITI_BINARIES_FILE}"
echo -e 'Downloading '"$(BLUE "${zitidl}")"' to '"$(BLUE "${ZITI_BINARIES_FILE_ABSPATH}")"
@@ -1076,7 +1077,7 @@ function ziti_createEnvFile {
if [[ "${ZITI_USER-}" == "" ]]; then export ZITI_USER="admin"; fi
if [[ "${ZITI_PWD-}" == "" ]]; then
ZITI_PWD="$(tr -dc _A-Z-a-z-0-9 < /dev/urandom | head -c32)"
ZITI_PWD="$(LC_ALL=C tr -dc _A-Z-a-z-0-9 < /dev/urandom | head -c32)"
echo -en "Do you want to keep the generated admin password '$ZITI_PWD'? (Y/n) "
# shellcheck disable=SC2162
read -r pwd_reply
@@ -1487,6 +1488,7 @@ HeredocForSystemd
}
function setOs {
if [ -n "${ZITI_OSTYPE}" ]; then return; fi
if [[ "$OSTYPE" == "linux-gnu"* ]]; then
export ZITI_OSTYPE="linux"
elif [[ "$OSTYPE" == "darwin"* ]]; then
+13 -37
View File
@@ -3,44 +3,20 @@ set -eo pipefail
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"
ZITI_QUICKSTART_ROOT="$(realpath ${SCRIPT_DIR}/..)"
ZITI_BIN_ROOT="${ZITI_QUICKSTART_ROOT}/docker"
mkdir -p "${ZITI_BIN_ROOT}/ziti-bin"
source "${ZITI_QUICKSTART_ROOT}/ziti-cli-functions.sh"
ZITI_HOME="${ZITI_BIN_ROOT}"
if [ -d "${ZITI_BIN_ROOT}/image/ziti.ignore" ]; then
rm -rf "${ZITI_BIN_ROOT}/image/ziti.ignore"
if [ -z "${ZITI_VERSION}" ]; then
ZITI_QUICKSTART_ROOT="$(realpath ${SCRIPT_DIR}/..)"
v=$(source "${ZITI_QUICKSTART_ROOT}/ziti-cli-functions.sh"; getLatestZitiVersion > /dev/null 2>&1; echo ${ZITI_BINARIES_VERSION})
ZITI_VERSION=$(echo "${v}" | sed -e 's/^v//')
fi
getZiti
mv "${ZITI_BIN_DIR}" "${SCRIPT_DIR}/image/ziti.ignore/"
docker build "${SCRIPT_DIR}/image" -t openziti/quickstart
if [ -d "${ZITI_BIN_ROOT}/image/ziti.ignore" ]; then
rm -rf "${ZITI_BIN_ROOT}/image/ziti.ignore"
if [ -z "${ZITI_VERSION}" ]; then
echo "ZITI_VERSION was not set and auto-detection failed."
exit 1
fi
#if [ -f "${ZITI_BIN_ROOT}/ziti-*tar.gz" ]; then
# rm "${ZITI_BIN_ROOT}/ziti-*tar.gz"
#fi
if [ -d "${ZITI_BIN_ROOT}/ziti-bin" ]; then
rm -rf "${ZITI_BIN_ROOT}/ziti-bin"
fi
if [ -d "${ZITI_BIN_ROOT}/image/ziti.ignore" ]; then
rm -rf "${ZITI_BIN_ROOT}/image/ziti.ignore/"
fi
vers="$(echo "${ZITI_BINARIES_VERSION}" | cut -c 2-100)"
echo DOCKERTAG: docker tag openziti/quickstart "openziti/quickstart:${vers}"
docker tag openziti/quickstart "openziti/quickstart:${vers}"
echo DOCKERTAG: docker tag openziti/quickstart "openziti/quickstart:latest"
docker tag openziti/quickstart "openziti/quickstart:latest"
echo DOCKERPUSH: docker push "openziti/quickstart:${vers}"
docker push "openziti/quickstart:${vers}"
echo DOCKERPUSH: docker push "openziti/quickstart:latest"
docker push "openziti/quickstart:latest"
docker buildx create --use --name=ziti-builder
docker buildx build --platform linux/amd64,linux/arm64 "${SCRIPT_DIR}/image" \
--build-arg ZITI_VERSION_OVERRIDE="${ZITI_VERSION}" \
--tag "openziti/quickstart:${ZITI_VERSION}" \
--tag "openziti/quickstart:latest" \
--push
+18 -10
View File
@@ -5,7 +5,11 @@ services:
env_file:
- ./.env
ports:
- "1280:1280"
- ${ZITI_EDGE_CONTROLLER_PORT:-1280}:${ZITI_EDGE_CONTROLLER_PORT:-1280}
- ${ZITI_CTRL_PORT:-6262}:${ZITI_CTRL_PORT:-6262}
environment:
- ZITI_EDGE_IDENTITY_ENROLLMENT_DURATION=${ZITI_EDGE_IDENTITY_ENROLLMENT_DURATION}
- ZITI_EDGE_ROUTER_ENROLLMENT_DURATION=${ZITI_EDGE_ROUTER_ENROLLMENT_DURATION}
networks:
zitiblue:
aliases:
@@ -40,16 +44,18 @@ services:
- "/var/openziti/scripts/run-with-ziti-cli.sh"
command:
- "/var/openziti/scripts/access-control.sh"
ziti-edge-router:
image: "${ZITI_IMAGE}:${ZITI_VERSION}"
environment:
- ZITI_EDGE_ROUTER_RAWNAME=ziti-edge-router
- ZITI_EDGE_ROUTER_ROLES=public
depends_on:
- ziti-controller
environment:
- ZITI_CONTROLLER_RAWNAME="${ZITI_CONTROLLER_RAWNAME}"
- ZITI_EDGE_CONTROLLER_RAWNAME="${ZITI_EDGE_CONTROLLER_RAWNAME}"
- ZITI_EDGE_ROUTER_RAWNAME=${ZITI_EDGE_ROUTER_RAWNAME:-ziti-edge-router}
- ZITI_EDGE_ROUTER_ROLES=public
ports:
- "3022:3022"
- ${ZITI_EDGE_ROUTER_PORT:-3022}:${ZITI_EDGE_ROUTER_PORT:-3022}
networks:
- zitiblue
- zitired
@@ -60,14 +66,16 @@ services:
ziti-console:
image: openziti/zac
working_dir: /usr/src/app
environment:
- ZAC_SERVER_CERT_CHAIN=/persistent/pki/ziti-controller-intermediate/certs/ziti-controller-server.cert
- ZAC_SERVER_KEY=/persistent/pki/ziti-controller-intermediate/keys/ziti-controller-server.key
- ZAC_SERVER_CERT_CHAIN=/persistent/pki/${ZITI_EDGE_CONTROLLER_HOSTNAME:-ziti-controller}-intermediate/certs/${ZITI_EDGE_CONTROLLER_HOSTNAME:-ziti-controller}-server.cert
- ZAC_SERVER_KEY=/persistent/pki/${ZITI_EDGE_CONTROLLER_HOSTNAME:-ziti-controller}-intermediate/keys/${ZITI_EDGE_CONTROLLER_HOSTNAME:-ziti-controller}-server.key
- PORTTLS=8443
depends_on:
- ziti-controller
ports:
- "1408:1408"
- "8443:8443"
- 1408:1408
- 8443:8443
volumes:
- ziti-fs:/persistent
@@ -1,152 +0,0 @@
# Kubernetes Sidecar Client
This guide shows you how to access a Ziti service from a pre-existing (or third party) application that's running
in a Kubernetes Pod. To provide access to the service, we will deploy the `ziti-tunnel` client in a sidecar
container.
## Overview
The [Ziti Network Quickstart](https://openziti.github.io/ziti/quickstarts/networks-overview.html)
walked you through standing up a Ziti instance and accessing a Ziti service from your workstation with
`ziti-tunnel`. In this guide we'll deploy the same `ziti-tunnel` client, but instead of running it from the
command line we will deploy it in a sidecar container in a Kubernetes Pod.
This guide also demonstrates `ziti-tunnel`'s internal DNS server, which allows us to access Ziti services
by hostname instead of IP address.
[Here's some detail on how the various intercept modes work on Linux](https://openziti.github.io/ziti/clients/linux.html)
### Solution Overview
![Diagram of solution](./sidecar-diagram.svg)
## Prerequisites
- Complete the [Ziti Network Quickstart](https://openziti.github.io/ziti/quickstarts/networks-overview.html). This guide
uses the Ziti Controller and Ziti Edge Router that are created in the Ziti Quickstart.
- Admin-level access to a Kubernetes cluster via `kubectl`.
## Create an Identity and AppWAN
This guide will re-use the "eth0.ziti.cli" service that was created in the Ziti Network Quickstart.
We will create a new identity for our client, with a new AppWAN that uses the eth0.ziti.cli service.
Create the Identity:
ziti edge controller create identity device tunnel-sidecar -o tunnel-sidecar.jwt
Create the AppWAN and reference the service created in the Ziti Network Quickstart. We'll be using `eth0.ziti.cli`
here but if you created `eth0.ziti.ui` in the quickstart - use that instead. Also note that in the
tunnel-sidecar-demo.yaml:
ziti edge controller create app-wan ziti-tunnel-appwan -i tunnel-sidecar -s eth0.ziti.cli
## Create a Kubernetes Secret
The `ziti-tunnel` sidecar will access its identity by mounting a Kubernetes secret in the container.
We can mount the JWT as a secret like this:
$ kubectl create secret generic tunnel-sidecar.jwt --from-file=tunnel-sidecar.jwt
secret/tunnel-sidecar.jwt created
## Deploy the Pod
Deploy a Pod that runs a client application and `ziti-tunnel` as a sidecar container. For this
demonstration, the client application is `curl`. Our Pod runs `curl` in a loop so we can see content
from our Ziti service in the Pod's logs.
Save the following yaml to a file named tunnel-sidecar-demo.yaml
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: tunnel-sidecar-pv-claim
spec:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 100Mi
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: ziti-tunnel-sidecar-demo
spec:
replicas: 1
selector:
matchLabels:
app: ziti-tunnel-sidecar-demo
strategy:
type: Recreate
template:
metadata:
labels:
app: ziti-tunnel-sidecar-demo
spec:
containers:
- image: centos
name: testclient
command: ["sh","-c","while true; set -x; do curl -sSLf eth0.ziti.cli 2>&1; set +x; sleep 5; done"]
- image: netfoundry/ziti-tunnel:latest
name: ziti-tunnel
env:
- name: NF_REG_NAME
value: tunnel-sidecar
volumeMounts:
- name: tunnel-sidecar-jwt
mountPath: "/var/run/secrets/kubernetes.io/enrollment-token"
readOnly: true
- name: ziti-tunnel-persistent-storage
mountPath: /netfoundry
securityContext:
capabilities:
add:
- NET_ADMIN
dnsPolicy: "None"
dnsConfig:
nameservers:
- 127.0.0.1
- 8.8.8.8
restartPolicy: Always
volumes:
- name: ziti-tunnel-persistent-storage
persistentVolumeClaim:
claimName: tunnel-sidecar-pv-claim
- name: tunnel-sidecar-jwt
secret:
secretName: tunnel-sidecar.jwt
You'll notice that the `ziti-tunnel` sidecar container has a few requirements:
1. The name of the identity that is assumed by `ziti-tunnel` must be passed into the container with the
`NF_REG_NAME` environment variable.
2. The secret that we created above for the enrollment token must be mounted into the container at
"/var/run/secrets/netfoundry.io/enrollment-token".
3. A persistent volume must be mounted at "/netfoundry". This volume is used to save the json file that is created
when the one-time enrollment token is used. If this volume is not persistent, you will need to provide a new
enrollment token each time the Pod is restarted!
Once the yaml is saved, we can deploy the Pod with `kubectl`
$ kubectl apply -f ./tunnel-sidecar-demo.yaml
persistentvolumeclaim/tunnel-sidecar-pv-claim created
deployment.apps/ziti-tunnel-sidecar-demo created
## Test the Service
First we need to get the name of the Pod that Kubernetes deployed for us:
$ kubectl get pods
ziti-tunnel-sidecar-demo-749c476989-6wpfn 1/1 Running 0 42s
Then we can tail the logs for the "testclient" container:
$ kubectl logs -f ziti-tunnel-sidecar-demo-749c476989-6wpfn --container testclient
54.67.121.213
54.67.121.213
54.67.121.213
Notice that the `curl` client is using the DNS name that we provided in the Ziti service definition to make the
request.
File diff suppressed because it is too large Load Diff

Before

Width:  |  Height:  |  Size: 89 KiB

+11 -11
View File
@@ -12,17 +12,17 @@ import (
"github.com/docker/docker/api/types"
"github.com/docker/docker/api/types/filters"
"github.com/docker/docker/client"
"github.com/openziti/edge/rest_management_api_client"
api_client_config "github.com/openziti/edge/rest_management_api_client/config"
"github.com/openziti/edge/rest_management_api_client/edge_router"
"github.com/openziti/edge/rest_management_api_client/edge_router_policy"
"github.com/openziti/edge/rest_management_api_client/identity"
"github.com/openziti/edge/rest_management_api_client/service"
"github.com/openziti/edge/rest_management_api_client/service_edge_router_policy"
"github.com/openziti/edge/rest_management_api_client/service_policy"
"github.com/openziti/edge/rest_management_api_client/terminator"
"github.com/openziti/edge/rest_model"
"github.com/openziti/edge/rest_util"
"github.com/openziti/edge-api/rest_management_api_client"
api_client_config "github.com/openziti/edge-api/rest_management_api_client/config"
"github.com/openziti/edge-api/rest_management_api_client/edge_router"
"github.com/openziti/edge-api/rest_management_api_client/edge_router_policy"
"github.com/openziti/edge-api/rest_management_api_client/identity"
"github.com/openziti/edge-api/rest_management_api_client/service"
"github.com/openziti/edge-api/rest_management_api_client/service_edge_router_policy"
"github.com/openziti/edge-api/rest_management_api_client/service_policy"
"github.com/openziti/edge-api/rest_management_api_client/terminator"
"github.com/openziti/edge-api/rest_model"
"github.com/openziti/edge-api/rest_util"
"github.com/openziti/sdk-golang/ziti"
sdk_config "github.com/openziti/sdk-golang/ziti/config"
"github.com/openziti/sdk-golang/ziti/enroll"
-6
View File
@@ -1,6 +0,0 @@
# enrollments in-use with Docker Compose
*.json
*.jwt
# executable from fetch bins script
/ziti-tunnel
-112
View File
@@ -1,112 +0,0 @@
The Dockerfile and scripts in this directory build a `ziti-tunnel` (Go tunneler) Docker image. This procedure is highly similar to that of the `ziti-edge-tunnel` (C tunneler) Docker image [documented here](https://github.com/openziti/ziti-tunnel-sdk-c/blob/main/docker/BUILD.md).
Ziti binaries are downloaded from https://netfoundry.artifactory.io/netfoundry/ziti-release
by default. The following build arguments are supported:
| Build Argument | Description |
| -------------------- | ----------------------------------------------------------------- |
| ZITI_VERSION | The version of the ziti binaries to fetch from artifactory. |
| ARTIFACTORY_TOKEN | An Artifactory token with read access to the artifact repository. This is not needed if using the default ARTIFACTORY_BASE_URL / ARTIFACTORY_REPO. |
| ARTIFACTORY_BASE_URL | Defaults to "https://netfoundry.jfrog.io/netfoundry". |
| ARTIFACTORY_REPO | Defaults to "ziti-release". |
# Building multi-platform Images
Use this build method if you're pushing the ziti-tunnel image to a public image
registry.
This build method creates images for the amd64 and arm/v7 platforms, but it
requires experimental Docker features and may involve more setup than you're
willing to endure. See "Building for Development" if you just want to build the
ziti-tunnel image for use on your local workstation, and don't plan on pushing
the image to a public registry.
## Prerequisites
1. Enable Docker Experimental Features
See https://docs.docker.com/engine/reference/commandline/cli/#experimental-features
2. Install & Enable qemu Emulation for Arm (Docker CE / Linux only)
This is taken care of by Docker Desktop if you're building on macOS or Windows,
but you'll need to install qemu emulation support and register Arm binaries to
run on your (presumably) x86_64 build host if you are running Docker CE on Linux:
$ sudo dnf install -y qemu-system-arm
$ docker run --rm --privileged docker/binfmt:66f9012c56a8316f9244ffd7622d7c21c1f6f28d
Verify that the Arm qemu handler is registered:
$ cat /proc/sys/fs/binfmt_misc/qemu-arm
enabled
interpreter /usr/bin/qemu-arm
...
Ensure that the first line of the file is "enabled".
3. Create a Builder Instance
$ docker buildx create --use --name=ziti-builder
## Building
Run `docker buildx` like this:
$ ziti_version="0.19.11"
$ docker buildx build \
--platform linux/amd64,linux/arm/v7,linux/aarch64 \
--build-arg ZITI_VERSION="${ziti_version}" \
-t "netfoundry/ziti-tunnel:${ziti_version}" .
Notes:
- You'll need to append "--push" to this command, and then subsequently pull the
image to be able to use the image locally.
Unfortunately `buildx` doesn't currently support building images directly into
the local docker cache. Although the `--load` and `--output=type=docker` options
exist, the underlying capability to load a multi-platform image (OCI) will be
implemented in a future Docker release (see https://github.com/docker/buildx/issues/59).
In the meantime, you'll need to push your image builds (with the `--push` build option)
and then pull them to run the image locally when building with `buildx`.
- The armv8 image uses armv7 (32-bit) ziti executables. The 32-bit compatibility
libraries are installed in the image, but your Arm CPU must support 32-bit emulation.
## References:
- <https://docs.docker.com/buildx/working-with-buildx/>
- <https://www.docker.com/blog/multi-arch-images/>
- <https://community.arm.com/developer/tools-software/tools/b/tools-software-ides-blog/posts/getting-started-with-docker-for-arm-on-linux>
- <https://medium.com/@drpdishant/installing-docker-on-fedora-31-a073db823bb8>
# Building for Development
This build method produces an image for the CPU that is running the build host
(typically amd64), and places the resulting image into your local Docker image
cache.
$ git fetch --tags && git tag -l | sort -Vr | head -1
v0.19.11
$ ziti_version="0.19.11" \
$ docker build \
--build-arg ZITI_VERSION="${ziti_version}" \
-t "netfoundry/ziti-tunnel:${ziti_version}" .
## Shell Script for Linux
$ ./buildx.sh -h
Usage: VARIABLES ./buildx.sh [OPTION]...
Build multi-platform Docker container image on Linux.
VARIABLES
ZITI_VERSION e.g. "0.16.1" corresponding to Git tag "v0.16.1"
OPTIONS
-r REPO container image repository e.g. netfoundry/ziti-edge-tunnel
-c don't check out v${ZITI_VERSION} (use Git working copy)
EXAMPLES
ZITI_VERSION=0.19.11 ./buildx.sh -r netfoundry/ziti-tunnel
-38
View File
@@ -1,38 +0,0 @@
FROM debian:buster-slim as fetch-ziti-artifacts
# This build stage grabs artifacts that are copied into the final image.
# It uses the same base as the final image to maximize docker cache hits.
ARG ZITI_VERSION
ARG ARTIFACTORY_TOKEN
ARG ARTIFACTORY_BASE_URL="https://netfoundry.jfrog.io/netfoundry"
# to fetch snapshots from the "feature-0.5" branch, set ZITI_REPO="ziti-snapshot/feature-0.5"
ARG ARTIFACTORY_REPO="ziti-release"
WORKDIR /tmp
RUN apt-get -q update && apt-get -q install -y --no-install-recommends curl ca-certificates
# workaround for `openssl rehash` not working on arm.
RUN /bin/bash -c "if ! compgen -G '/etc/ssl/certs/*.[0-9]' > /dev/null; then c_rehash /etc/ssl/certs; fi"
COPY fetch-ziti-bins.sh .
RUN bash ./fetch-ziti-bins.sh ziti-tunnel
################
#
# Main Image
#
################
FROM debian:buster-slim
RUN mkdir -p /usr/local/bin /etc/ssl/certs
RUN apt-get -q update && apt-get -q install -y --no-install-recommends iptables
COPY --from=fetch-ziti-artifacts /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs
COPY --from=fetch-ziti-artifacts /tmp/ziti-tunnel /usr/local/bin
COPY ./docker-entrypoint.sh /
RUN chmod +x /docker-entrypoint.sh
ENTRYPOINT [ "/docker-entrypoint.sh" ]
CMD [ "run" ]
-41
View File
@@ -1,41 +0,0 @@
FROM debian:buster-slim as fetch-ziti-artifacts
# This build stage grabs artifacts that are copied into the final image.
# It uses the same base as the final image to maximize docker cache hits.
ARG ARTIFACTS_DIR=./release
# e.g. linux
ARG TARGETOS
# e.g. arm
ARG TARGETARCH
# e.g. v7 (OS variant)
# TARGETVARIANT
WORKDIR /tmp
RUN apt-get -q update && apt-get -q install -y --no-install-recommends curl ca-certificates
# workaround for `openssl rehash` not working on arm.
RUN /bin/bash -c "if ! compgen -G '/etc/ssl/certs/*.[0-9]' > /dev/null; then c_rehash /etc/ssl/certs; fi"
COPY ${ARTIFACTS_DIR}/${TARGETARCH}/${TARGETOS}/ziti-tunnel .
################
#
# Main Image
#
################
FROM debian:buster-slim
ARG DOCKER_BUILD_DIR=.
ARG ZITI_TUNNELER_BIN=ziti-tunnel
RUN mkdir -p /usr/local/bin /etc/ssl/certs
RUN apt-get -q update && apt-get -q install -y --no-install-recommends iptables
COPY --from=fetch-ziti-artifacts /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs
COPY --from=fetch-ziti-artifacts /tmp/${ZITI_TUNNELER_BIN} /usr/local/bin
COPY ${DOCKER_BUILD_DIR}/docker-entrypoint.sh /
RUN chmod +x /docker-entrypoint.sh
ENTRYPOINT [ "/docker-entrypoint.sh" ]
CMD [ "run" ]
-299
View File
@@ -1,299 +0,0 @@
# Ziti-tunnel Docker Image
Run the ziti-tunnel NetFoundry client. ziti-tunnel captures network traffic that
is destined for Ziti services and proxes the packet payloads to the associated
Ziti service. See the [ziti-tunnel README](../README.md) for more details.
This image requires access to a Ziti enrollment token (JWT), and a persistent
volume mounted at "/netfoundry" to save the configuration file that is created
when the one-time enrollment token is consumed.
## Variables
- `NF_REG_NAME`: Required - file basename of the enroll token JWT file or identity config JSON file that ziti-tunnel will use
- `NF_REG_TOKEN`: Optional - one-time enrollment token to use instead of `${NF_REG_NAME}.jwt`
If `${NF_REG_NAME}.jwt` does not exist and `NF_REG_TOKEN` is not defined the enroller will try to get the token from
stdin if it is not a TTY.
## Volumes
- `/netfoundry`: Configuration files that result from enrollment will be stored
here. This volume should be persistent unless you don't mind losing the key for
your enrollment token.
## Files
The enrollment token (jwt) must be mounted into the ziti-tunnel container as a volume.
The token must be in a file named `${NF_REG_NAME}.jwt` that must be in one of the
following directories:
- `/netfoundry`: This would be used when running in the Docker engine (or IoT Edge).
This could be a bind mount or a docker volume.
- `/enrollment-token`: Alternative mount point for the enrollment token only.
- `/var/run/secrets/netfoundry.io/enrollment-token`: When running in Kubernetes,
the enrollment token should be mounted as a secret at this mount point.
## Examples
### Docker
The ziti-tunnel image can be used in a vanilla Docker environment.
# enroll with token from inherited env var and run hosting-only mode without any nameserver or IP routes
$ mkdir ./ziti_id
$ export NF_REG_TOKEN=eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJlbSI6Im90dCIsImV4cCI6MTY1MzE2NzcwOCwiaXNzIjoiaHR0cHM6Ly81MGEyMDc4Zi01MGQyLTRhZTAtYWI4Ny0wYTdjMjM1OWVjOTYucHJvZHVjdGlvbi5uZXRmb3VuZHJ5LmlvOjQ0MyIsImp0aSI6IjFiMjJkMzc2LTMzMWItNDMxNS1iZTFiLWJkOTUzYThiYWM4ZiIsInN1YiI6InRGLnZnLjdwM1kifQ.TWbk3-kjBRKwQCXMoD93sXtyQhZOMZ1iJzV73Sqft-cEOkV2kjbA4TBRwl0nuLPCdJqkhPl9Yc1WG7YaYWYXV4ghE1Hk0Gta_HlpWdNjNlB1cVrzMyxaoCXhaX5xqGnwDuqfOK7q6DItuNsKouM2G6KKZvhGOacax6TvP-sunsxFz6AdYQJizNBoL5fJ14r1_O6yczGd5GSd8x9-eP5rNMQuRdUtiu69b-rEu1gO2SXVTrADTD5p8sP9khbT_eQzIDD9jgagXoJJvOKTVdsUAWS7YKfk1On0BpxNvv30bQ6eAkliwU7GTXDR2IPW-blZYt1Wtf3sgeuTDCCtVO_7gjSn7WM7YJqpsB72V-43Xz8I7LCDa0u48baSmmpPDUSphIBDa_nksPZk8jfwx4pHoHYbSbD4r47Af_9P-JUQRT8hzNuvktG56kmcqVCfEZHT-4xgK0Lvxxp4mzqdcNyCB0VwC6kdk7OlxwqmftDWrJhNuxKMy2MtyTjG0mwHxt4P0y_fZo1ZYJZU5AzvxrE9OLTjsQ4nV5NliJ3Qxaw_taCaIWxn98BeiHfAiIc3EL7bWGjAfXz-XWvWG8-AcCmK-cxIj7Pvj0U7lIWH7bVcRmVVc0fQnXdACkeQe7ixWr4IopV5YJ607zm6Qk_am_MrERla6xyXblvroWIITN2aEUk
$ docker run --rm \
-v $(pwd)/ziti_id:/netfoundry \
-e NF_REG_NAME=ziti_id \
-e NF_REG_TOKEN \
openziti/ziti-tunnel:latest
# enroll with a JWT file and run a transparent proxy with built-in nameserver
$ mkdir ./ziti_id
$ cp ~/Downloads/ziti_id.jwt ./ziti_id
$ docker run -t --network=host --cap-add=NET_ADMIN \
-v $(pwd)/ziti_id:/netfoundry \
-e NF_REG_NAME=ziti_id \
openziti/ziti-tunnel:latest
Notes:
- The container that runs ziti-tunnel will only be able to intercept traffic for other processes within the same
container, unless the container uses the "host" network mode.
- No special network mode or additional capabilities are required when running `ziti-tunnel host`, which is the
hosting-only run mode without any built-in nameserver or IP routers or iptables rules
- The container requires NET_ADMIN capability to create iptables rules in the host network when running in the default
mode `ziti-tunnel tproxy` (implied by `ziti-tunnel run`).
- The `NF_REG_NAME` environment variable must be set to the name of the ziti identity that ziti-tunnel will assume when
connecting to the controller.
- The "/netfoundry" directory must be mounted on its own volume.
- The one-time enrollment token "/netfoundry/${NF_REG_NAME}.jwt" is sought by the enroller when the container is
started for the first time. This is the JWT that was downloaded from the controller when the Ziti identity was
created.
- If the JWT file is not found in one of the well-known directories then the token is subsequently sought from the
env var `NF_REG_TOKEN`, then stdin.
- "/netfoundry/${NF_REG_NAME}.json" is created when the identity is enrolled. The "/netfoundry" volume must be
persistent (that is, ${NF_REG_NAME}.json must endure container restarts), since the enrollment token is only valid
for one enrollment.
### Docker Compose
This example uses Compose to store in a file the Docker `build` and `run` parameters for several modes of operation of `ziti-tunnel`.
#### Docker Compose Setup
1. Install Docker Engine.
2. `docker-compose` is a utility you can install with the Python Package Index (PyPi) e.g. `pip install --upgrade
docker-compose`.
3. Save your Ziti identity enrollment token e.g. `my-ziti-identity-file.jwt` in the same directory as the file named
`docker-compose.yml`. Your identity will be enrolled the first time you run the container, and the permanent
identity file will be saved e.g. `my-ziti-identity-file.json`.
4. You may change `ZITI_VERSION` to [another release version from our ziti-release
repository](https://netfoundry.jfrog.io/ui/repos/simple/Properties/ziti-release%2Fziti-tunnel%2Famd64%2Flinux%2F0.15.2%2Fziti-tunnel.tar.gz).
#### Docker Transparent Proxy for Linux
1. Modify "ziti-tproxy" under "services" in the file named `docker-compose.yml` in this Git repo, optionally overriding
the default value of `command` to pass additional parameters to `ziti-tunnel`.
```yaml
version: "3.3"
services:
ziti-tproxy:
image: netfoundry/ziti-tunnel:tproxy
build:
context: .
args:
ZITI_VERSION: 0.15.3
volumes:
- .:/netfoundry
network_mode: host
cap_add:
- NET_ADMIN
environment:
- NF_REG_NAME
- NF_REG_TOKEN
# command: run --resolver udp://127.0.0.123:53
# command: run --resolver none
```
2. Run `NF_REG_NAME=my-ziti-identity-file docker-compose up --build ziti-tproxy` in the same directory.
This will cause the container to configure the Linux host to transparently proxy any domain names or IP addresses that match a Ziti service.
#### Docker Proxy or MacOS or Windows
1. Modify "ziti-proxy" under "services" in the file named `docker-compose.yml` in this Git repo. Change the service
name(s) and port number(s) to suit your actual services. You must align the mapped ports under `ports` with the
bound ports in the `command`.
```yaml
version: "3.3"
services:
ziti-proxy:
image: netfoundry/ziti-tunnel:proxy
build:
context: .
args:
ZITI_VERSION: 0.15.3
volumes:
- .:/netfoundry
environment:
- NF_REG_NAME
- NF_REG_TOKEN
ports:
- "8888:8888"
- "9999:9999"
command: proxy "my example service":8888 "my other example service":9999
```
2. Run in the same directory:
```bash
NF_REG_NAME=my-ziti-identity-file docker-compose up --build ziti-proxy
```
This will cause the container to listen on the mapped port(s) and proxy any received traffic to the Ziti service that
are bound to that port.
### Kubernetes
The ziti-tunnel image can be used in Kubernetes either as a sidecar, which would
intercept packets only from other containers in the pod definition or as a dedicated
pod that sets `hostNetwork` to true.
The following example manifest shows how to run ziti-tunnel as a sidecar:
$ cat app-with-ziti-tunnel-sidecar.yaml
```yaml
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: tunnel-sidecar-pv-claim
spec:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 1Gi
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: ziti-tunnel-sidecar-demo
spec:
replicas: 1
selector:
matchLabels:
app: ziti-tunnel-sidecar-demo
strategy:
type: Recreate
template:
metadata:
labels:
app: ziti-tunnel-sidecar-demo
spec:
containers:
- image: centos
name: testclient
command: ["sh","-c","while true; set -x; do curl -sSLf ethzero.ziti.ui 2>&1; set +x; sleep 5; done"]
- image: netfoundry/ziti-tunnel:0.5.8-2554
name: ziti-tunnel
env:
- name: NF_REG_NAME
value: tunnel-sidecar
volumeMounts:
- name: tunnel-sidecar-jwt
mountPath: "/var/run/secrets/netfoundry.io/enrollment-token"
readOnly: true
- name: ziti-tunnel-persistent-storage
mountPath: /netfoundry
securityContext:
capabilities:
add:
- NET_ADMIN
dnsPolicy: "None"
dnsConfig:
nameservers:
- 127.0.0.1
- 8.8.8.8
restartPolicy: Always
volumes:
- name: ziti-tunnel-persistent-storage
persistentVolumeClaim:
claimName: tunnel-sidecar-pv-claim
- name: tunnel-sidecar-jwt
secret:
secretName: tunnel-sidecar.jwt
```
### Azure IoT Hub
This image can be used to run a module on an Azure IoT runtime.
# createOption.HostConfig for tun (instead of tproxy): \"Devices\":[{\"PathOnHost\":\"/dev/net/tun\",\"PathInContainer\":\"/dev/net/tun\",\"CgroupPermissions\":\"rwm\"}],
$ cat module.json
```json
{
"modulesContent": {
"$edgeAgent": {
"properties.desired": {
"modules": {
"ziti-tunnel": {
"settings": {
"image": "netfoundry/ziti-tunnel:0.5.8-2554",
"createOptions": "{\"HostConfig\":{\"CapAdd\":[\"NET_ADMIN\"],\"Mounts\":[{\"Type\":\"bind\",\"Source\":\"/opt/netfoundry\",\"Target\":\"/netfoundry\"}],\"NetworkMode\":\"host\"},\"NetworkingConfig\":{\"EndpointsConfig\":{\"host\":{}}}}"
},
"type": "docker",
"version": "1.0",
"status": "running",
"restartPolicy": "always"
}
},
"runtime": {
"settings": {
"minDockerVersion": "v1.25"
},
"type": "docker"
},
"schemaVersion": "1.0",
"systemModules": {
"edgeAgent": {
"settings": {
"image": "mcr.microsoft.com/azureiotedge-agent:1.0",
"createOptions": ""
},
"type": "docker"
},
"edgeHub": {
"settings": {
"image": "mcr.microsoft.com/azureiotedge-hub:1.0",
"createOptions": "{\"HostConfig\":{\"PortBindings\":{\"443/tcp\":[{\"HostPort\":\"443\"}],\"5671/tcp\":[{\"HostPort\":\"5671\"}],\"8883/tcp\":[{\"HostPort\":\"8883\"}]}}}"
},
"type": "docker",
"status": "running",
"restartPolicy": "always"
}
}
}
},
"$edgeHub": {
"properties.desired": {
"routes": {},
"schemaVersion": "1.0",
"storeAndForwardConfiguration": {
"timeToLiveSecs": 7200
}
}
},
"ziti-tunnel": {
"properties.desired": {}
}
}
}
```
-89
View File
@@ -1,89 +0,0 @@
#!/usr/bin/env bash
set -euo pipefail
_usage(){
cat >&2 <<-EOF
Usage: VARIABLES ./${BASENAME} -r REPO [OPTIONS]
Build multi-platform Docker container image on Linux.
VARIABLES
ZITI_VERSION e.g. "0.16.1" corresponding to Git tag "v0.16.1"
REQUIRED
-r REPO required container image repository e.g. netfoundry/ziti-edge-tunnel
OPTIONS
-c don't check out v\${ZITI_VERSION} (use Git working copy)
-P don't push the container image to Hub
EXAMPLES
ZITI_VERSION=0.16.1 ./${BASENAME} -c
REFERENCE
https://github.com/openziti/ziti-tunnel-sdk-c/blob/main/docker/BUILD.md
EOF
[[ $# -eq 1 ]] && {
return "$1"
} || {
return 0
}
}
BASENAME=$(basename "$0") || exit $?
DIRNAME=$(dirname "$0") || exit $?
while getopts :chPr: OPT;do
case $OPT in
c) FLAGS+=$OPT # don't checkout vZITI_VERSION
;;
h) _usage; exit 0 # not an error
;;
P) FLAGS+=$OPT # don't push container image to Hub
;;
r) CONTAINER_REPO=$OPTARG
;;
*|\?) _usage 1 # error
;;
esac
done
shift "$((OPTIND-1))"
# default to latest
: "${ZITI_VERSION:=$(git fetch --quiet --tags && git tag -l|sort -Vr|head -1|sed -E 's/^v(.*)/\1/')}"
[[ -n "${CONTAINER_REPO:-}" ]] || {
echo "ERROR: missing -r REPO option to define container image repository name for tagging the image" >&2
_usage; exit 1
}
if [[ ${FLAGS:-} =~ c ]]; then
echo "WARN: not checking out Git tag v${ZITI_VERSION}"
else
git diff --exit-code # bail if unstaged differences
git fetch --tags
git checkout "v${ZITI_VERSION}"
fi
docker run --rm --privileged linuxkit/binfmt:v0.8
grep -E -q enabled /proc/sys/fs/binfmt_misc/qemu-arm
docker run --rm --platform arm arm32v7/alpine uname -a|grep -E -q 'armv7l Linux'
docker run --rm --platform arm64 arm64v8/alpine uname -a|grep -E -q 'aarch64 Linux'
docker buildx create --use --name=ziti-builder 2>/dev/null || docker buildx use --default ziti-builder
# if default then push to Hub
BUILDX_OUTPUT="--push"
if [[ ${FLAGS:-} =~ P ]]; then
# if no push then load in image cache
BUILDX_OUTPUT=""
fi
eval docker buildx build "$DIRNAME" \
--platform linux/amd64,linux/arm/v7,linux/arm64 \
--build-arg "ZITI_VERSION=${ZITI_VERSION}" \
--tag "${CONTAINER_REPO}:${ZITI_VERSION}" \
--tag "${CONTAINER_REPO}:latest" \
"${BUILDX_OUTPUT:-}"
docker buildx stop ziti-builder
-54
View File
@@ -1,54 +0,0 @@
version: "3.9"
x-base-service: &base-service
image: netfoundry/ziti-tunnel:latest # https://hub.docker.com/r/netfoundry/ziti-tunnel/tags?page=1&ordering=last_updated
volumes:
- .:/netfoundry # mount current dir (relative to Compose file) with identity config file
environment:
- NF_REG_NAME # NF_REG_NAME=AcmeIdentity docker-compose up ziti-host
- NF_REG_TOKEN # NF_REG_NAME=AcmeIdentity NF_REG_TOKEN=eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJlbSI6Im90dCIsImV4cCI6MTY1MzE2NzcwOCwiaXNzIjoiaHR0cHM6Ly81MGEyMDc4Zi01MGQyLTRhZTAtYWI4Ny0wYTdjMjM1OWVjOTYucHJvZHVjdGlvbi5uZXRmb3VuZHJ5LmlvOjQ0MyIsImp0aSI6IjFiMjJkMzc2LTMzMWItNDMxNS1iZTFiLWJkOTUzYThiYWM4ZiIsInN1YiI6InRGLnZnLjdwM1kifQ.TWbk3-kjBRKwQCXMoD93sXtyQhZOMZ1iJzV73Sqft-cEOkV2kjbA4TBRwl0nuLPCdJqkhPl9Yc1WG7YaYWYXV4ghE1Hk0Gta_HlpWdNjNlB1cVrzMyxaoCXhaX5xqGnwDuqfOK7q6DItuNsKouM2G6KKZvhGOacax6TvP-sunsxFz6AdYQJizNBoL5fJ14r1_O6yczGd5GSd8x9-eP5rNMQuRdUtiu69b-rEu1gO2SXVTrADTD5p8sP9khbT_eQzIDD9jgagXoJJvOKTVdsUAWS7YKfk1On0BpxNvv30bQ6eAkliwU7GTXDR2IPW-blZYt1Wtf3sgeuTDCCtVO_7gjSn7WM7YJqpsB72V-43Xz8I7LCDa0u48baSmmpPDUSphIBDa_nksPZk8jfwx4pHoHYbSbD4r47Af_9P-JUQRT8hzNuvktG56kmcqVCfEZHT-4xgK0Lvxxp4mzqdcNyCB0VwC6kdk7OlxwqmftDWrJhNuxKMy2MtyTjG0mwHxt4P0y_fZo1ZYJZU5AzvxrE9OLTjsQ4nV5NliJ3Qxaw_taCaIWxn98BeiHfAiIc3EL7bWGjAfXz-XWvWG8-AcCmK-cxIj7Pvj0U7lIWH7bVcRmVVc0fQnXdACkeQe7ixWr4IopV5YJ607zm6Qk_am_MrERla6xyXblvroWIITN2aEUk docker-compose up ziti-host
- PFXLOG_NO_JSON=true # suppress JSON logging
network_mode: host # use the Docker host's network, not the Docker bridge
x-iptables-capabilities: &iptables-capabilities
cap_add:
- NET_ADMIN # iptables filter
- NET_RAW # iptables mangle
services:
ziti-tproxy: # iptables transparent interceptor with DNS
<<: *base-service
<<: *iptables-capabilities
dns: # optionally, override DNS inherited from Docker host
- 127.0.0.1 # this first NS must match the built-in nameserver's bind address,
- 1.1.1.1 # and a recursive NS is also needed e.g. 8.8.8.8
command:
- tproxy
#- --resolver=udp://127.1.2.3:53 # override nameserver bind address (always 53/udp); default is 127.0.0.1
#- --dnsSvcIpRange=100.64.64.0/18 # override the IP range used for DNS intercepts; default is 100.64/10
ziti-tproxy-ip: # iptables transparent interceptor without DNS
<<: *base-service
<<: *iptables-capabilities
command:
- tproxy
- --resolver none
#- --dnsSvcIpRange=100.64.64.0/18 # override the IP range used for DNS intercepts; default is 100.64/10
ziti-test: # docker-compose exec ziti-test bash
<<: *base-service
<<: *iptables-capabilities
entrypoint: ["sh", "-c", "while true; do sleep infinity; done"]
ziti-host: # terminate a service for a server that's reachable by the host network
<<: *base-service
command: host
ziti-bridge: # terminate a service for a server that's reachable by this Docker network (default mode is "bridge")
<<: *base-service
network_mode: bridge
command: host
ziti-proxy: # bind a named service to a container TCP port, optionally forward host TCP port to container
<<: *base-service
ports:
- "8888:8888" # optionally forward host ports to container ports listening as TCP proxy
network_mode: bridge
command:
- proxy
- '"my example service":8888' # example named service and container port to bind as TCP proxy
-105
View File
@@ -1,105 +0,0 @@
#!/usr/bin/env bash
set -euo pipefail
function alldone() {
# if successfully sent to background then send SIGINT to trigger a cleanup
# of iptables mangle rules and loopback assignments
[[ "${ZITI_TUNNEL_PID:-}" =~ ^[0-9]+$ ]] && {
kill -INT "$ZITI_TUNNEL_PID"
# let entrypoint script exit after ziti-tunnel PID
wait "$ZITI_TUNNEL_PID"
}
}
trap alldone exit
# Ensure that ziti-tunnel's identity is stored on a volume
# so we don't throw away the one-time enrollment token
IDENTITIES_DIR="/netfoundry"
if ! mountpoint "${IDENTITIES_DIR}" &>/dev/null; then
echo "ERROR: please run this container with a volume mounted on ${IDENTITIES_DIR}" >&2
exit 1
fi
# IOTEDGE_DEVICEID is a standard var assigned by Azure IoT
if [[ -z "${NF_REG_NAME:-}" ]]; then
if [[ -n "${IOTEDGE_DEVICEID:-}" ]]; then
echo "DEBUG: setting NF_REG_NAME to \${IOTEDGE_DEVICEID} (${IOTEDGE_DEVICEID})"
NF_REG_NAME="${IOTEDGE_DEVICEID}"
fi
fi
typeset -a TUNNEL_OPTS
# if identity file name, else critical error
if [[ -n "${NF_REG_NAME:-}" ]]; then
IDENTITY_FILE="${IDENTITIES_DIR}/${NF_REG_NAME}.json"
TUNNEL_OPTS=("--identity" "${IDENTITY_FILE}")
# if non-empty identity file
if [[ -s "${IDENTITY_FILE}" ]]; then
echo "DEBUG: found identity file ${IDENTITY_FILE}"
# look for enrollment token
else
echo "DEBUG: identity file ${IDENTITY_FILE} does not exist"
for dir in "/var/run/secrets/netfoundry.io/enrollment-token" \
"/enrollment-token" \
"${IDENTITIES_DIR}"; do
JWT_CANDIDATE="${dir}/${NF_REG_NAME}.jwt"
echo "DEBUG: looking for ${JWT_CANDIDATE}"
if [[ -s "${JWT_CANDIDATE}" ]]; then
JWT_FILE="${JWT_CANDIDATE}"
break
fi
done
if [[ -n "${JWT_FILE:-}" ]]; then
echo "DEBUG: enrolling ${JWT_FILE}"
ziti-tunnel enroll --verbose --jwt "${JWT_FILE}" --identity "${IDENTITY_FILE}" || {
echo "ERROR: failed to enroll with token from ${JWT_FILE} ($(wc -c < "${JWT_FILE}")B)" >&2
exit 1
}
elif [[ -n "${NF_REG_TOKEN:-}" ]]; then
echo "DEBUG: attempting enrollment with NF_REG_TOKEN"
JWT_FILE=${IDENTITIES_DIR}/${NF_REG_NAME}.jwt
echo "${NF_REG_TOKEN}" >| ${JWT_FILE}
ziti-tunnel enroll --verbose --jwt ${JWT_FILE} --identity "${IDENTITY_FILE}" || {
echo "ERROR: failed to enroll with token from NF_REG_TOKEN ($(wc -c <<<"${NF_REG_TOKEN}")B)" >&2
exit 1
}
elif ! [[ -t 0 ]]; then
echo "DEBUG: trying to get token from stdin" >&2
JWT_FILE=${IDENTITIES_DIR}/${NF_REG_NAME}.jwt
while read -r; do
echo "$REPLY" >> ${JWT_FILE}
done
ziti-tunnel enroll --verbose --jwt ${JWT_FILE} --identity "${IDENTITY_FILE}" || {
echo "ERROR: failed to enroll with token from stdin, got $(wc -c < ${JWT_FILE})B" >&2
exit 1
}
else
echo "DEBUG: ${NF_REG_NAME}.jwt and env var \$NF_REG_TOKEN not found" >&2
exit 1
fi
fi
else
echo "ERROR: need NF_REG_NAME env var to save the identity file in volume mounted on ${IDENTITIES_DIR}" >&2
exit 1
fi
echo "INFO: probing iptables"
if iptables -t mangle -S --wait 2>&1 | grep -q "iptables-legacy tables present"; then
for LEGACY in {ip{,6},eb,arp}tables; do
if which ${LEGACY}-legacy &>/dev/null; then
echo "INFO: updating $LEGACY alternative to ${LEGACY}-legacy"
update-alternatives --set $LEGACY "$(which ${LEGACY}-legacy)"
else
echo "WARN: not updating $LEGACY alternative to ${LEGACY}-legacy" >&2
fi
done
fi
# optionally run an alternative shell CMD
echo "running ziti-tunnel"
set -x
ziti-tunnel "${TUNNEL_OPTS[@]}" "${@}" &
ZITI_TUNNEL_PID=$!
wait $ZITI_TUNNEL_PID
-68
View File
@@ -1,68 +0,0 @@
#!/bin/bash
set -euo pipefail
[[ $# -eq 0 ]] && {
echo "ERROR: need the base name(s) of the executable(s) to fetch e.g. \"ziti-tunnel ...\"." >&2
exit 1
}
: "${ARTIFACTORY_BASE_URL:="https://netfoundry.jfrog.io/netfoundry"}"
: "${ARTIFACTORY_REPO:="ziti-release"}"
for var in ARTIFACTORY_BASE_URL ARTIFACTORY_REPO ZITI_VERSION; do
if [ -z "${!var:-}" ]; then
echo "ERROR: ${var} must be set when fetching binaries from Artifactory." >&2
exit 1
fi
done
[[ "$ZITI_VERSION" =~ ^[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}$ ]] || {
echo "ERROR: '$ZITI_VERSION' is not a semantic version like 2.0.0" >&2
exit 1
}
echo "Fetching from Artifactory."
# map host architecture/os to directories that we use in netfoundry.jfrog.io.
# (our artifact directories seem to align with Docker's TARGETARCH and TARGETOS
# build arguments, which we could rely on if we fully committed to "docker buildx" - see
# https://docs.docker.com/engine/reference/builder/#automatic-platform-args-in-the-global-scope)
host_arch=$(uname -m)
case "${host_arch}" in
"x86_64") artifact_arch="amd64";;
"armv7l") artifact_arch="arm";;
"aarch64") artifact_arch="arm64";;
*) echo "ERROR: ziti binaries do not exist for architecture ${host_arch}"; exit 1;;
esac
host_os=$(uname -s)
case "${host_os}" in
"Linux") artifact_os="linux"
;;
"Darwin") artifact_os="darwin"
;;
"Windows") artifact_os="windows"
;;
*) echo "ERROR: ziti binaries do not exist for os ${host_os}";
exit 1
;;
esac
for exe in "${@}"; do
url="${ARTIFACTORY_BASE_URL}/${ARTIFACTORY_REPO}/${exe}/${artifact_arch}/${artifact_os}/${ZITI_VERSION}/${exe}.tar.gz"
echo "Fetching ${exe} from ${url}"
rm -f "${exe}" "${exe}.tar.gz" "${exe}.exe"
token_header="${ARTIFACTORY_TOKEN:+X-JFrog-Art-Api:$ARTIFACTORY_TOKEN}"
if { command -v curl > /dev/null; } 2>&1; then
curl ${token_header:+-H "$token_header"} -fLsS -O "${url}"
elif { command -v wget > /dev/null; } 2>&1; then
wget ${token_header:+--header "$token_header"} "${url}"
else
echo "ERROR: need one of curl or wget to fetch the artifact." >&2
exit 1
fi
tar -xzf "${exe}.tar.gz"
if [ -f "${exe}" ]; then chmod 755 "${exe}"; fi
if [ -f "${exe}.exe" ]; then chmod 755 "${exe}.exe"; fi
rm "${exe}.tar.gz"
done
+132 -13
View File
@@ -1,6 +1,13 @@
package agentcli
import (
"fmt"
"io"
"net"
"os"
"strings"
"time"
"github.com/openziti/agent"
"github.com/openziti/channel/v2"
"github.com/openziti/edge/router/debugops"
@@ -10,9 +17,8 @@ import (
"github.com/openziti/identity"
"github.com/openziti/ziti/ziti/cmd/common"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
"github.com/pkg/errors"
"github.com/spf13/cobra"
"net"
"time"
)
type AgentAppId byte
@@ -32,12 +38,13 @@ func NewAgentCmd(p common.OptionsProvider) *cobra.Command {
}
agentCmd.AddCommand(NewPsCmd(p))
agentCmd.AddCommand(NewGoVersionCmd(p))
agentCmd.AddCommand(NewGcCmd(p))
agentCmd.AddCommand(NewListCmd(p))
agentCmd.AddCommand(NewSimpleAgentCmd("goversion", agent.Version, p, "Returns the golang version of the target application"))
agentCmd.AddCommand(NewSimpleAgentCmd("gc", agent.GC, p, "Run garbage collection in the target application"))
agentCmd.AddCommand(NewSetGcCmd(p))
agentCmd.AddCommand(NewStackCmd(p))
agentCmd.AddCommand(NewMemstatsCmd(p))
agentCmd.AddCommand(NewStatsCmd(p))
agentCmd.AddCommand(NewSimpleAgentCmd("memstats", agent.MemStats, p, "Returns memory use summary of the target application"))
agentCmd.AddCommand(NewSimpleAgentCmd("stats", agent.Stats, p, "Emits some runtime information (# go-routines, threads, cpus, etc) from the target application"))
agentCmd.AddCommand(NewPprofHeapCmd(p))
agentCmd.AddCommand(NewPprofCpuCmd(p))
agentCmd.AddCommand(NewTraceCmd(p))
@@ -58,6 +65,7 @@ func NewAgentCmd(p common.OptionsProvider) *cobra.Command {
ctrlCmd.AddCommand(NewSimpleChAgentCustomCmd("snapshot-db", AgentAppController, int32(mgmt_pb.ContentType_SnapshotDbRequestType), p))
ctrlCmd.AddCommand(NewAgentCtrlRaftJoin(p))
ctrlCmd.AddCommand(NewAgentCtrlRaftList(p))
ctrlCmd.AddCommand(NewAgentCtrlRaftLeave(p))
ctrlCmd.AddCommand(NewAgentCtrlInit(p))
ctrlCmd.AddCommand(NewAgentCtrlInitFromDb(p))
@@ -73,12 +81,12 @@ func NewAgentCmd(p common.OptionsProvider) *cobra.Command {
agentCmd.AddCommand(routerCmd)
routerCmd.AddCommand(NewRouteCmd(p))
routerCmd.AddCommand(NewSimpleAgentCustomCmd("dump-routes", AgentAppRouter, router.DumpForwarderTables, p))
routerCmd.AddCommand(NewSimpleAgentCustomCmd("disconnect", AgentAppRouter, router.CloseControlChannel, p))
routerCmd.AddCommand(NewSimpleAgentCustomCmd("reconnect", AgentAppRouter, router.OpenControlChannel, p))
routerCmd.AddCommand(NewSimpleAgentCustomCmd("dump-api-sessions", AgentAppRouter, debugops.DumpApiSessions, p))
routerCmd.AddCommand(NewSimpleAgentCustomCmd("dump-links", AgentAppRouter, router.DumpLinks, p))
routerCmd.AddCommand(NewSimpleChAgentCustomCmd("dump-routes", AgentAppRouter, int32(mgmt_pb.ContentType_RouterDebugDumpForwarderTablesRequestType), p))
routerCmd.AddCommand(NewSimpleChAgentCustomCmd("dump-links", AgentAppRouter, int32(mgmt_pb.ContentType_RouterDebugDumpLinksRequestType), p))
routerCmd.AddCommand(NewForgetLinkAgentCmd(p))
routerCmd.AddCommand(NewToggleCtrlChannelAgentCmd(p, "disconnect", false))
routerCmd.AddCommand(NewToggleCtrlChannelAgentCmd(p, "reconnect", true))
return agentCmd
}
@@ -86,6 +94,113 @@ func NewAgentCmd(p common.OptionsProvider) *cobra.Command {
// AgentOptions contains the command line options
type AgentOptions struct {
common.CommonOptions
pid uint32
processName string
appId string
appType string
appAlias string
tcpAddr string
timeout time.Duration
}
func (self *AgentOptions) AddAgentOptions(cmd *cobra.Command) {
cmd.Flags().Uint32VarP(&self.pid, "pid", "p", 0, "Process ID of host application to talk to")
cmd.Flags().StringVarP(&self.processName, "process-name", "n", "", "Process name of host application to talk to")
cmd.Flags().StringVarP(&self.appId, "app-id", "i", "", "Id of host application to talk to (like controller or router id)")
cmd.Flags().StringVarP(&self.appType, "app-type", "t", "", "Type of host application to talk to (like controller or router)")
cmd.Flags().StringVarP(&self.appType, "app-alias", "a", "", "Alias of host application to talk to (specified in host application)")
cmd.Flags().StringVar(&self.tcpAddr, "tcp-addr", "", "Type of host application to talk to (like controller or router)")
cmd.Flags().DurationVar(&self.timeout, "timeout", 5*time.Second, "Operation timeout")
}
func (self *AgentOptions) GetProcess() (*agent.Process, error) {
procList, err := agent.GetGopsProcesses()
if err != nil {
return nil, err
}
var result []*agent.Process
for _, p := range procList {
if !p.Contactable {
continue
}
if self.Cmd.Flags().Changed("pid") && p.Pid != int(self.pid) {
continue
}
if self.Cmd.Flags().Changed("process-name") && p.Executable != self.processName {
continue
}
if self.Cmd.Flags().Changed("app-id") && p.AppId != self.appId {
continue
}
if self.Cmd.Flags().Changed("app-type") && p.AppType != self.appType {
continue
}
if self.Cmd.Flags().Changed("app-alias") && p.AppAlias != self.appAlias {
continue
}
result = append(result, p)
}
if len(result) == 0 {
return nil, errors.New("no processes found matching filter, use 'ziti agent ps' to list candidates")
}
if len(result) > 1 {
var pids []string
for _, r := range result {
pids = append(pids, fmt.Sprintf("%v", r.Pid))
}
return nil, errors.Errorf("too many processes found matching filter: [%v] use 'ziti agent list' for more information", strings.Join(pids, " "))
}
return result[0], nil
}
func (self *AgentOptions) MakeChannelRequest(appId byte, f func(ch channel.Channel) error) error {
return self.MakeRequest(agent.CustomOpAsync, []byte{appId}, connToChannelMapper(f))
}
func (self *AgentOptions) MakeRequest(signal byte, params []byte, f func(c net.Conn) error) error {
if self.Cmd.Flags().Changed("tcp-addr") {
conn, err := net.Dial("tcp", self.tcpAddr)
if err != nil {
return err
}
return agent.MakeRequestToConn(conn, signal, params, f)
}
p, err := self.GetProcess()
if err != nil {
return err
}
return agent.MakeProcessRequest(p, signal, params, f)
}
func (self *AgentOptions) CopyToWriter(out io.Writer) func(conn net.Conn) error {
return func(conn net.Conn) error {
_, err := io.Copy(out, conn)
return err
}
}
func (self *AgentOptions) RunCopyOut(op byte, params []byte, out io.Writer) error {
if self.Cmd.Flags().Changed("timeout") {
time.AfterFunc(self.timeout, func() {
fmt.Println("operation timed out")
os.Exit(-1)
})
}
if len(self.Args) == 0 {
return self.MakeRequest(op, params, self.CopyToWriter(out))
}
addr, err := agent.ParseGopsAddress(self.Args)
if err != nil {
return err
}
return agent.MakeRequest(addr, op, params, os.Stdout)
}
func NewAgentChannel(conn net.Conn) (channel.Channel, error) {
@@ -95,12 +210,16 @@ func NewAgentChannel(conn net.Conn) (channel.Channel, error) {
return channel.NewChannel("agent", dialer, nil, options)
}
func MakeAgentChannelRequest(addr string, signal byte, params []byte, f func(ch channel.Channel) error) error {
return agent.MakeRequestF(addr, signal, params, func(conn net.Conn) error {
func MakeAgentChannelRequest(addr string, appId byte, f func(ch channel.Channel) error) error {
return agent.MakeRequestF(addr, agent.CustomOpAsync, []byte{appId}, connToChannelMapper(f))
}
func connToChannelMapper(f func(ch channel.Channel) error) func(conn net.Conn) error {
return func(conn net.Conn) error {
ch, err := NewAgentChannel(conn)
if err != nil {
return err
}
return f(ch)
})
}
}
+22 -29
View File
@@ -20,22 +20,17 @@ import (
"fmt"
"github.com/openziti/agent"
"github.com/openziti/channel/v2"
"github.com/openziti/identity"
"github.com/openziti/ziti/ziti/cmd/common"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
"github.com/spf13/cobra"
"net"
"time"
)
type SimpleChAgentCmdOptions struct {
type SimpleChAgentCmdAction struct {
AgentOptions
requestType int32
timeout time.Duration
}
func NewSimpleChAgentCustomCmd(name string, appId AgentAppId, op int32, p common.OptionsProvider) *cobra.Command {
options := &SimpleChAgentCmdOptions{
action := &SimpleChAgentCmdAction{
AgentOptions: AgentOptions{
CommonOptions: p(),
},
@@ -45,47 +40,45 @@ func NewSimpleChAgentCustomCmd(name string, appId AgentAppId, op int32, p common
cmd := &cobra.Command{
Args: cobra.MaximumNArgs(1),
Use: name + " <optional-target> ",
Run: func(cmd *cobra.Command, args []string) {
options.Cmd = cmd
options.Args = args
err := options.Run(appId)
cmdhelper.CheckErr(err)
RunE: func(cmd *cobra.Command, args []string) error {
action.Cmd = cmd
action.Args = args
return action.Run(appId)
},
}
cmd.Flags().DurationVarP(&options.timeout, "timeout", "t", 5*time.Second, "How long to wait for operation to complete")
action.AddAgentOptions(cmd)
return cmd
}
// Run implements the command
func (o *SimpleChAgentCmdOptions) Run(appId AgentAppId) error {
addr, err := agent.ParseGopsAddress(o.Args)
func (self *SimpleChAgentCmdAction) Run(appId AgentAppId) error {
if len(self.Args) == 0 {
return self.MakeChannelRequest(byte(appId), self.makeRequest)
}
addr, err := agent.ParseGopsAddress(self.Args)
if err != nil {
return err
}
return agent.MakeRequestF(addr, agent.CustomOpAsync, []byte{byte(appId)}, o.makeRequest)
return MakeAgentChannelRequest(addr, byte(appId), self.makeRequest)
}
func (o *SimpleChAgentCmdOptions) makeRequest(conn net.Conn) error {
options := channel.DefaultOptions()
options.ConnectTimeout = time.Second
dialer := channel.NewExistingConnDialer(&identity.TokenId{Token: "agent"}, conn, nil)
ch, err := channel.NewChannel("agent", dialer, nil, options)
if err != nil {
return err
}
msg := channel.NewMessage(o.requestType, nil)
reply, err := msg.WithTimeout(o.timeout).SendForReply(ch)
func (self *SimpleChAgentCmdAction) makeRequest(ch channel.Channel) error {
msg := channel.NewMessage(self.requestType, nil)
reply, err := msg.WithTimeout(self.timeout).SendForReply(ch)
if err != nil {
return err
}
if reply.ContentType == channel.ContentTypeResultType {
result := channel.UnmarshalResult(reply)
if result.Success {
fmt.Println("success")
if len(result.Message) != 0 {
fmt.Print(result.Message)
} else {
fmt.Println("success")
}
} else {
fmt.Printf("error: %v\n", result.Message)
}
@@ -19,11 +19,13 @@ package agentcli
import (
"bytes"
"encoding/binary"
"fmt"
"github.com/openziti/agent"
"github.com/openziti/ziti/ziti/cmd/common"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
"github.com/spf13/cobra"
"os"
"time"
)
type AgentClearChannelLogLevelAction struct {
@@ -31,7 +33,7 @@ type AgentClearChannelLogLevelAction struct {
}
func NewClearChannelLogLevelCmd(p common.OptionsProvider) *cobra.Command {
options := &AgentClearChannelLogLevelAction{
action := &AgentClearChannelLogLevelAction{
AgentOptions: AgentOptions{
CommonOptions: p(),
},
@@ -42,31 +44,33 @@ func NewClearChannelLogLevelCmd(p common.OptionsProvider) *cobra.Command {
Short: "Clears a channel-specific log level in the target application",
Args: cobra.MinimumNArgs(1),
Run: func(cmd *cobra.Command, args []string) {
options.Cmd = cmd
options.Args = args
err := options.Run()
action.Cmd = cmd
action.Args = args
err := action.Run()
cmdhelper.CheckErr(err)
},
}
action.AddAgentOptions(cmd)
return cmd
}
// Run implements the command
func (self *AgentClearChannelLogLevelAction) Run() error {
var addr string
var err error
var channelArg string
if len(self.Args) == 1 {
addr, err = agent.ParseGopsAddress(nil)
channelArg = self.Args[0]
} else {
addr, err = agent.ParseGopsAddress(self.Args)
channelArg = self.Args[1]
if self.Cmd.Flags().Changed("timeout") {
time.AfterFunc(self.timeout, func() {
fmt.Println("operation timed out")
os.Exit(-1)
})
}
if err != nil {
return err
var channelArg string
if len(self.Args) == 1 {
channelArg = self.Args[0]
} else {
channelArg = self.Args[1]
}
lenBuf := make([]byte, 8)
@@ -75,5 +79,13 @@ func (self *AgentClearChannelLogLevelAction) Run() error {
buf.Write(lenBuf[:lenLen])
buf.Write([]byte(channelArg))
if len(self.Args) == 1 {
return self.MakeRequest(agent.ClearChannelLogLevel, buf.Bytes(), self.CopyToWriter(os.Stdout))
}
addr, err := agent.ParseGopsAddress(self.Args)
if err != nil {
return err
}
return agent.MakeRequest(addr, agent.ClearChannelLogLevel, buf.Bytes(), os.Stdout)
}
+14 -46
View File
@@ -18,16 +18,11 @@ package agentcli
import (
"fmt"
"github.com/openziti/agent"
"github.com/openziti/channel/v2"
"github.com/openziti/channel/v2/protobufs"
"github.com/openziti/edge/pb/edge_mgmt_pb"
"github.com/openziti/identity"
"github.com/openziti/ziti/ziti/cmd/common"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
"github.com/spf13/cobra"
"net"
"time"
)
type AgentCtrlInitOptions struct {
@@ -35,62 +30,35 @@ type AgentCtrlInitOptions struct {
}
func NewAgentCtrlInit(p common.OptionsProvider) *cobra.Command {
options := &AgentCtrlInitOptions{
action := &AgentCtrlInitOptions{
AgentOptions: AgentOptions{
CommonOptions: p(),
},
}
cmd := &cobra.Command{
Args: cobra.RangeArgs(3, 4),
Use: "init <optional-target> <username> <password> <name>",
Run: func(cmd *cobra.Command, args []string) {
options.Cmd = cmd
options.Args = args
err := options.Run()
cmdhelper.CheckErr(err)
Args: cobra.ExactArgs(3),
Use: "init <username> <password> <name>",
RunE: func(cmd *cobra.Command, args []string) error {
action.Cmd = cmd
action.Args = args
return action.MakeChannelRequest(byte(AgentAppController), action.makeRequest)
},
}
action.AddAgentOptions(cmd)
return cmd
}
// Run implements the command
func (o *AgentCtrlInitOptions) Run() error {
var addr string
var err error
if len(o.Args) == 4 {
addr, err = agent.ParseGopsAddress(o.Args)
if err != nil {
return err
}
}
return agent.MakeRequestF(addr, agent.CustomOpAsync, []byte{byte(AgentAppController)}, o.makeRequest)
}
func (o *AgentCtrlInitOptions) makeRequest(conn net.Conn) error {
options := channel.DefaultOptions()
options.ConnectTimeout = time.Second
dialer := channel.NewExistingConnDialer(&identity.TokenId{Token: "agent"}, conn, nil)
ch, err := channel.NewChannel("agent", dialer, nil, options)
if err != nil {
return err
}
offset := 0
if len(o.Args) == 4 {
offset = 1
}
func (self *AgentCtrlInitOptions) makeRequest(ch channel.Channel) error {
initEdgeRequest := &edge_mgmt_pb.InitEdgeRequest{
Username: o.Args[offset],
Password: o.Args[offset+1],
Name: o.Args[offset+2],
Username: self.Args[0],
Password: self.Args[1],
Name: self.Args[2],
}
reply, err := protobufs.MarshalTyped(initEdgeRequest).WithTimeout(5 * time.Second).SendForReply(ch)
reply, err := protobufs.MarshalTyped(initEdgeRequest).WithTimeout(self.timeout).SendForReply(ch)
if err != nil {
return err
}
@@ -18,76 +18,44 @@ package agentcli
import (
"fmt"
"github.com/openziti/agent"
"github.com/openziti/channel/v2"
"github.com/openziti/fabric/pb/mgmt_pb"
"github.com/openziti/identity"
"github.com/openziti/ziti/ziti/cmd/common"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
"github.com/spf13/cobra"
"net"
"time"
)
type AgentCtrlInitFromDbOptions struct {
type AgentCtrlInitFromDbAction struct {
AgentOptions
Voter bool
MemberId string
}
func NewAgentCtrlInitFromDb(p common.OptionsProvider) *cobra.Command {
options := &AgentCtrlInitFromDbOptions{
action := &AgentCtrlInitFromDbAction{
AgentOptions: AgentOptions{
CommonOptions: p(),
},
}
cmd := &cobra.Command{
Args: cobra.RangeArgs(1, 2),
Use: "init-from-db <optional-target> path/to/source.db",
Run: func(cmd *cobra.Command, args []string) {
options.Cmd = cmd
options.Args = args
err := options.Run()
cmdhelper.CheckErr(err)
Args: cobra.ExactArgs(1),
Use: "init-from-db path/to/source.db",
RunE: func(cmd *cobra.Command, args []string) error {
action.Cmd = cmd
action.Args = args
return action.MakeChannelRequest(byte(AgentAppController), action.makeRequest)
},
}
action.AddAgentOptions(cmd)
return cmd
}
// Run implements the command
func (o *AgentCtrlInitFromDbOptions) Run() error {
var addr string
var err error
func (self *AgentCtrlInitFromDbAction) makeRequest(ch channel.Channel) error {
msg := channel.NewMessage(int32(mgmt_pb.ContentType_RaftInitFromDb), []byte(self.Args[0]))
if len(o.Args) == 2 {
addr, err = agent.ParseGopsAddress(o.Args)
if err != nil {
return err
}
}
return agent.MakeRequestF(addr, agent.CustomOpAsync, []byte{byte(AgentAppController)}, o.makeRequest)
}
func (o *AgentCtrlInitFromDbOptions) makeRequest(conn net.Conn) error {
options := channel.DefaultOptions()
options.ConnectTimeout = time.Second
dialer := channel.NewExistingConnDialer(&identity.TokenId{Token: "agent"}, conn, nil)
ch, err := channel.NewChannel("agent", dialer, nil, options)
if err != nil {
return err
}
offset := 0
if len(o.Args) == 2 {
offset = 1
}
msg := channel.NewMessage(int32(mgmt_pb.ContentType_RaftInitFromDb), []byte(o.Args[offset]))
reply, err := msg.WithTimeout(5 * time.Second).SendForReply(ch)
reply, err := msg.WithTimeout(self.timeout).SendForReply(ch)
if err != nil {
return err
}
+16 -47
View File
@@ -18,86 +18,55 @@ package agentcli
import (
"fmt"
"github.com/openziti/agent"
"github.com/openziti/channel/v2"
"github.com/openziti/fabric/controller"
"github.com/openziti/fabric/pb/mgmt_pb"
"github.com/openziti/identity"
"github.com/openziti/ziti/ziti/cmd/common"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
"github.com/spf13/cobra"
"net"
"time"
)
type AgentCtrlRaftJoinOptions struct {
type AgentCtrlRaftJoinAction struct {
AgentOptions
Voter bool
MemberId string
}
func NewAgentCtrlRaftJoin(p common.OptionsProvider) *cobra.Command {
options := &AgentCtrlRaftJoinOptions{
action := &AgentCtrlRaftJoinAction{
AgentOptions: AgentOptions{
CommonOptions: p(),
},
}
cmd := &cobra.Command{
Args: cobra.RangeArgs(1, 2),
Use: "raft-join <optional-target> <addr>",
Args: cobra.ExactArgs(1),
Use: "raft-join <addr>",
Run: func(cmd *cobra.Command, args []string) {
options.Cmd = cmd
options.Args = args
err := options.Run()
action.Cmd = cmd
action.Args = args
err := action.MakeChannelRequest(byte(AgentAppController), action.makeRequest)
cmdhelper.CheckErr(err)
},
}
cmd.Flags().BoolVar(&options.Voter, "voter", true, "Is this member a voting member")
cmd.Flags().StringVar(&options.MemberId, "id", "", "The member id. If not provided, it will be looked up")
action.AddAgentOptions(cmd)
cmd.Flags().BoolVar(&action.Voter, "voter", true, "Is this member a voting member")
cmd.Flags().StringVar(&action.MemberId, "id", "", "The member id. If not provided, it will be looked up")
return cmd
}
// Run implements the command
func (o *AgentCtrlRaftJoinOptions) Run() error {
var addr string
var err error
if len(o.Args) == 2 {
addr, err = agent.ParseGopsAddress(o.Args)
if err != nil {
return err
}
}
return agent.MakeRequestF(addr, agent.CustomOpAsync, []byte{byte(AgentAppController)}, o.makeRequest)
}
func (o *AgentCtrlRaftJoinOptions) makeRequest(conn net.Conn) error {
options := channel.DefaultOptions()
options.ConnectTimeout = time.Second
dialer := channel.NewExistingConnDialer(&identity.TokenId{Token: "agent"}, conn, nil)
ch, err := channel.NewChannel("agent", dialer, nil, options)
if err != nil {
return err
}
offset := 0
if len(o.Args) == 2 {
offset = 1
}
func (self *AgentCtrlRaftJoinAction) makeRequest(ch channel.Channel) error {
msg := channel.NewMessage(int32(mgmt_pb.ContentType_RaftJoinRequestType), nil)
msg.PutStringHeader(controller.AgentAddrHeader, o.Args[offset])
msg.PutBoolHeader(controller.AgentIsVoterHeader, o.Voter)
msg.PutStringHeader(controller.AgentAddrHeader, self.Args[0])
msg.PutBoolHeader(controller.AgentIsVoterHeader, self.Voter)
if o.MemberId != "" {
msg.PutStringHeader(controller.AgentIdHeader, o.MemberId)
if self.MemberId != "" {
msg.PutStringHeader(controller.AgentIdHeader, self.MemberId)
}
reply, err := msg.WithTimeout(5 * time.Second).SendForReply(ch)
reply, err := msg.WithTimeout(self.timeout).SendForReply(ch)
if err != nil {
return err
}
@@ -0,0 +1,84 @@
/*
Copyright NetFoundry Inc.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
https://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
package agentcli
import (
"fmt"
"time"
"github.com/openziti/channel/v2"
"github.com/openziti/fabric/controller"
"github.com/openziti/fabric/pb/mgmt_pb"
"github.com/openziti/ziti/ziti/cmd/common"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
"github.com/spf13/cobra"
)
type AgentCtrlRaftLeaveAction struct {
AgentOptions
MemberId string
MemberAddr string
}
func NewAgentCtrlRaftLeave(p common.OptionsProvider) *cobra.Command {
action := AgentCtrlRaftLeaveAction{
AgentOptions: AgentOptions{
CommonOptions: p(),
},
}
cmd := &cobra.Command{
Args: cobra.RangeArgs(0, 1),
Use: "raft-leave",
Run: func(cmd *cobra.Command, args []string) {
action.Cmd = cmd
action.Args = args
err := action.MakeChannelRequest(byte(AgentAppController), action.makeRequest)
cmdhelper.CheckErr(err)
},
}
action.AddAgentOptions(cmd)
cmd.Flags().StringVar(&action.MemberId, "id", "", "The member id. If not provided, it will be looked up by the provided address")
cmd.Flags().StringVar(&action.MemberAddr, "address", "", "The member address")
return cmd
}
func (o *AgentCtrlRaftLeaveAction) makeRequest(ch channel.Channel) error {
msg := channel.NewMessage(int32(mgmt_pb.ContentType_RaftRemoveRequestType), nil)
if o.MemberId != "" {
msg.PutStringHeader(controller.AgentIdHeader, o.MemberId)
}
if o.MemberAddr != "" {
msg.PutStringHeader(controller.AgentAddrHeader, o.MemberAddr)
}
reply, err := msg.WithTimeout(5 * time.Second).SendForReply(ch)
if err != nil {
return err
}
result := channel.UnmarshalResult(reply)
if result.Success {
fmt.Println(result.Message)
} else {
fmt.Printf("error: %v\n", result.Message)
}
return nil
}
+21 -39
View File
@@ -18,24 +18,22 @@ package agentcli
import (
"fmt"
"github.com/golang/protobuf/proto"
"github.com/openziti/agent"
"github.com/jedib0t/go-pretty/v6/table"
"github.com/openziti/channel/v2"
"github.com/openziti/fabric/pb/mgmt_pb"
"github.com/openziti/identity"
"github.com/openziti/ziti/ziti/cmd/api"
"github.com/openziti/ziti/ziti/cmd/common"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
"github.com/spf13/cobra"
"net"
"time"
)
type AgentCtrlRaftListOptions struct {
type AgentCtrlRaftListAction struct {
AgentOptions
}
func NewAgentCtrlRaftList(p common.OptionsProvider) *cobra.Command {
options := &AgentCtrlRaftListOptions{
action := &AgentCtrlRaftListAction{
AgentOptions: AgentOptions{
CommonOptions: p(),
},
@@ -43,44 +41,22 @@ func NewAgentCtrlRaftList(p common.OptionsProvider) *cobra.Command {
cmd := &cobra.Command{
Args: cobra.RangeArgs(0, 1),
Use: "raft-list <optional-target>",
Run: func(cmd *cobra.Command, args []string) {
options.Cmd = cmd
options.Args = args
err := options.Run()
cmdhelper.CheckErr(err)
Use: "raft-list",
RunE: func(cmd *cobra.Command, args []string) error {
action.Cmd = cmd
action.Args = args
return action.MakeChannelRequest(byte(AgentAppController), action.makeRequest)
},
}
action.AddAgentOptions(cmd)
return cmd
}
// Run implements the command
func (o *AgentCtrlRaftListOptions) Run() error {
var addr string
var err error
if len(o.Args) == 1 {
addr, err = agent.ParseGopsAddress(o.Args)
if err != nil {
return err
}
}
return agent.MakeRequestF(addr, agent.CustomOpAsync, []byte{byte(AgentAppController)}, o.makeRequest)
}
func (o *AgentCtrlRaftListOptions) makeRequest(conn net.Conn) error {
options := channel.DefaultOptions()
options.ConnectTimeout = time.Second
dialer := channel.NewExistingConnDialer(&identity.TokenId{Token: "agent"}, conn, nil)
ch, err := channel.NewChannel("agent", dialer, nil, options)
if err != nil {
return err
}
func (self *AgentCtrlRaftListAction) makeRequest(ch channel.Channel) error {
msg := channel.NewMessage(int32(mgmt_pb.ContentType_RaftListMembersRequestType), nil)
reply, err := msg.WithTimeout(5 * time.Second).SendForReply(ch)
reply, err := msg.WithTimeout(self.timeout).SendForReply(ch)
if err != nil {
return err
}
@@ -96,9 +72,15 @@ func (o *AgentCtrlRaftListOptions) makeRequest(conn net.Conn) error {
if err = proto.Unmarshal(reply.Body, resp); err != nil {
return err
}
t := table.NewWriter()
t.SetStyle(table.StyleRounded)
t.AppendHeader(table.Row{"Id", "Address", "Voter", "Leader", "Version", "Connected"})
for _, m := range resp.Members {
fmt.Printf("id: %v, addr: %v, voter: %v, leader: %v\n", m.Id, m.Addr, m.IsVoter, m.IsLeader)
t.AppendRow(table.Row{m.Id, m.Addr, m.IsVoter, m.IsLeader, m.Version, m.IsConnected})
}
api.RenderTable(&api.Options{
CommonOptions: self.CommonOptions,
}, t, nil)
}
return nil
}
-60
View File
@@ -1,60 +0,0 @@
/*
Copyright NetFoundry Inc.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
https://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
package agentcli
import (
"github.com/openziti/agent"
"github.com/openziti/ziti/ziti/cmd/common"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
"github.com/spf13/cobra"
"os"
)
type AgentGcAction struct {
AgentOptions
}
func NewGcCmd(p common.OptionsProvider) *cobra.Command {
action := &AgentGcAction{
AgentOptions: AgentOptions{
CommonOptions: p(),
},
}
cmd := &cobra.Command{
Use: "gc <optional-target>",
Short: "Run garbage collection in the target application",
Args: cobra.MaximumNArgs(1),
Run: func(cmd *cobra.Command, args []string) {
action.Cmd = cmd
action.Args = args
err := action.Run()
cmdhelper.CheckErr(err)
},
}
return cmd
}
// Run implements the command
func (self *AgentGcAction) Run() error {
addr, err := agent.ParseGopsAddress(self.Args)
if err != nil {
return err
}
return agent.MakeRequest(addr, agent.GC, nil, os.Stdout)
}
@@ -1,61 +0,0 @@
/*
Copyright NetFoundry Inc.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
https://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
package agentcli
import (
"github.com/openziti/agent"
"github.com/openziti/ziti/ziti/cmd/common"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
"github.com/spf13/cobra"
"os"
)
type AgentGoVersionAction struct {
AgentOptions
CtrlListener string
}
func NewGoVersionCmd(p common.OptionsProvider) *cobra.Command {
action := &AgentGoVersionAction{
AgentOptions: AgentOptions{
CommonOptions: p(),
},
}
cmd := &cobra.Command{
Use: "goversion <optional-target>",
Short: "Returns the golang version of the target application",
Args: cobra.MaximumNArgs(1),
Run: func(cmd *cobra.Command, args []string) {
action.Cmd = cmd
action.Args = args
err := action.Run()
cmdhelper.CheckErr(err)
},
}
return cmd
}
// Run implements the command
func (self *AgentGoVersionAction) Run() error {
addr, err := agent.ParseGopsAddress(self.Args)
if err != nil {
return err
}
return agent.MakeRequest(addr, agent.Version, nil, os.Stdout)
}
@@ -17,6 +17,8 @@
package agentcli
import (
"fmt"
"github.com/jedib0t/go-pretty/v6/table"
"github.com/openziti/agent"
"github.com/openziti/ziti/ziti/cmd/common"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
@@ -24,22 +26,22 @@ import (
"os"
)
type AgentMemstatsAction struct {
type AgentListAction struct {
AgentOptions
CtrlListener string
}
func NewMemstatsCmd(p common.OptionsProvider) *cobra.Command {
action := &AgentMemstatsAction{
// NewListCmd Pss a command object for the "list" command
func NewListCmd(p common.OptionsProvider) *cobra.Command {
action := &AgentListAction{
AgentOptions: AgentOptions{
CommonOptions: p(),
},
}
cmd := &cobra.Command{
Use: "memstats <optional-target>",
Short: "Returns memory use summary of the target application",
Args: cobra.MaximumNArgs(1),
Use: "list",
Short: "List ziti processes",
Long: "Show information about currently running Ziti processes",
Run: func(cmd *cobra.Command, args []string) {
action.Cmd = cmd
action.Args = args
@@ -51,11 +53,22 @@ func NewMemstatsCmd(p common.OptionsProvider) *cobra.Command {
return cmd
}
// Run implements the command
func (o *AgentMemstatsAction) Run() error {
addr, err := agent.ParseGopsAddress(o.Args)
func (self *AgentListAction) Run() error {
processes, err := agent.GetGopsProcesses()
if err != nil {
return err
}
return agent.MakeRequest(addr, agent.MemStats, nil, os.Stdout)
t := table.NewWriter()
t.SetStyle(table.StyleRounded)
t.AppendHeader(table.Row{"PID", "Executable", "App ID", "Unix Socket", "App Type", "App Version", "App Alias"})
for _, p := range processes {
t.AppendRow(table.Row{p.Pid, p.Executable, p.AppId, p.UnixSocket, p.AppType, p.AppVersion, p.AppAlias})
}
if _, err = fmt.Fprintln(os.Stdout, t.Render()); err != nil {
panic(err)
}
return nil
}
+26
View File
@@ -17,16 +17,19 @@
package agentcli
import (
"fmt"
"github.com/openziti/agent"
"github.com/openziti/ziti/ziti/cmd/common"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
"github.com/spf13/cobra"
"io"
"os"
"time"
)
type AgentPprofCpuAction struct {
AgentOptions
outputFile string
}
func NewPprofCpuCmd(p common.OptionsProvider) *cobra.Command {
@@ -48,11 +51,34 @@ func NewPprofCpuCmd(p common.OptionsProvider) *cobra.Command {
},
}
action.AddAgentOptions(cmd)
cmd.Flags().StringVarP(&action.outputFile, "output-file", "o", "", "Output file for pprof")
return cmd
}
// Run implements the command
func (self *AgentPprofCpuAction) Run() error {
if self.Cmd.Flags().Changed("timeout") {
time.AfterFunc(self.timeout, func() {
fmt.Println("operation timed out")
os.Exit(-1)
})
}
if len(self.Args) == 0 {
var out io.WriteCloser = os.Stdout
var err error
if self.outputFile != "" {
out, err = os.Create(self.outputFile)
if err != nil {
return err
}
defer out.Close()
}
return self.RunCopyOut(agent.CPUProfile, nil, out)
}
addr, err := agent.ParseGopsAddress(self.Args)
if err != nil {
return err
+26
View File
@@ -17,16 +17,19 @@
package agentcli
import (
"fmt"
"github.com/openziti/agent"
"github.com/openziti/ziti/ziti/cmd/common"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
"github.com/spf13/cobra"
"io"
"os"
"time"
)
type AgentPprofHeapAction struct {
AgentOptions
outputFile string
}
func NewPprofHeapCmd(p common.OptionsProvider) *cobra.Command {
@@ -47,11 +50,34 @@ func NewPprofHeapCmd(p common.OptionsProvider) *cobra.Command {
},
}
action.AddAgentOptions(cmd)
cmd.Flags().StringVarP(&action.outputFile, "output-file", "o", "", "Output file for pprof")
return cmd
}
// Run implements the command
func (self *AgentPprofHeapAction) Run() error {
if self.Cmd.Flags().Changed("timeout") {
time.AfterFunc(self.timeout, func() {
fmt.Println("operation timed out")
os.Exit(-1)
})
}
if len(self.Args) == 0 {
var out io.WriteCloser = os.Stdout
var err error
if self.outputFile != "" {
out, err = os.Create(self.outputFile)
if err != nil {
return err
}
defer out.Close()
}
return self.RunCopyOut(agent.HeapProfile, nil, out)
}
addr, err := agent.ParseGopsAddress(self.Args)
if err != nil {
return err
+36 -39
View File
@@ -17,24 +17,22 @@
package agentcli
import (
"encoding/binary"
"github.com/openziti/agent"
"fmt"
"github.com/openziti/channel/v2"
"github.com/openziti/fabric/pb/ctrl_pb"
"github.com/openziti/fabric/pb/mgmt_pb"
"github.com/openziti/fabric/router"
"github.com/openziti/ziti/ziti/cmd/common"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
"github.com/spf13/cobra"
"google.golang.org/protobuf/proto"
"os"
)
type AgentRouteAction struct {
AgentOptions
CtrlListener string
}
func NewRouteCmd(p common.OptionsProvider) *cobra.Command {
options := &AgentRouteAction{
action := &AgentRouteAction{
AgentOptions: AgentOptions{
CommonOptions: p(),
},
@@ -42,38 +40,26 @@ func NewRouteCmd(p common.OptionsProvider) *cobra.Command {
cmd := &cobra.Command{
Args: cobra.RangeArgs(3, 4),
Use: "route <optional-target> <session id> <source-address> <destination-address>",
Run: func(cmd *cobra.Command, args []string) {
options.Cmd = cmd
options.Args = args
err := options.Run()
cmdhelper.CheckErr(err)
Use: "route <controller id> <circuit id> <source-address> <destination-address>",
RunE: func(cmd *cobra.Command, args []string) error {
action.Cmd = cmd
action.Args = args
return action.MakeChannelRequest(router.AgentAppId, action.makeRequest)
},
}
action.AddAgentOptions(cmd)
return cmd
}
// Run implements the command
func (self *AgentRouteAction) Run() error {
var addr string
var err error
offset := 0
if len(self.Args) == 4 {
addr, err = agent.ParseGopsAddress(self.Args)
if err != nil {
return err
}
offset = 1
}
func (self *AgentRouteAction) makeRequest(ch channel.Channel) error {
route := &ctrl_pb.Route{
CircuitId: self.Args[offset],
CircuitId: self.Args[1],
Forwards: []*ctrl_pb.Route_Forward{
{
SrcAddress: self.Args[offset+1],
DstAddress: self.Args[offset+2],
SrcAddress: self.Args[2],
DstAddress: self.Args[3],
},
},
}
@@ -83,15 +69,26 @@ func (self *AgentRouteAction) Run() error {
return err
}
fullBuf := make([]byte, len(buf)+6)
fullBuf[0] = byte(AgentAppRouter)
fullBuf[1] = router.UpdateRoute
msg := channel.NewMessage(int32(mgmt_pb.ContentType_RouterDebugUpdateRouteRequestType), buf)
msg.PutStringHeader(int32(mgmt_pb.Header_ControllerId), self.Args[0])
reply, err := msg.WithTimeout(self.timeout).SendForReply(ch)
if err != nil {
return err
}
sizeBuf := make([]byte, 4)
binary.LittleEndian.PutUint32(sizeBuf, uint32(len(buf)))
copy(fullBuf[2:], sizeBuf)
copy(fullBuf[6:], buf)
return agent.MakeRequest(addr, agent.CustomOp, fullBuf, os.Stdout)
if reply.ContentType == channel.ContentTypeResultType {
result := channel.UnmarshalResult(reply)
if result.Success {
if len(result.Message) > 0 {
fmt.Printf("success: %v\n", result.Message)
} else {
fmt.Println("success")
}
} else {
fmt.Printf("error: %v\n", result.Message)
}
} else {
fmt.Printf("unexpected response type %v\n", reply.ContentType)
}
return nil
}
+11 -33
View File
@@ -18,16 +18,12 @@ package agentcli
import (
"fmt"
"github.com/openziti/agent"
"github.com/openziti/channel/v2"
"github.com/openziti/fabric/pb/mgmt_pb"
"github.com/openziti/fabric/router"
"github.com/openziti/identity"
"github.com/openziti/ziti/ziti/cmd/common"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
"github.com/spf13/cobra"
"net"
"time"
)
type ForgetLinkAgentAction struct {
@@ -35,56 +31,38 @@ type ForgetLinkAgentAction struct {
}
func NewForgetLinkAgentCmd(p common.OptionsProvider) *cobra.Command {
options := &ForgetLinkAgentAction{
action := &ForgetLinkAgentAction{
AgentOptions: AgentOptions{
CommonOptions: p(),
},
}
cmd := &cobra.Command{
Args: cobra.RangeArgs(1, 2),
Use: "forget-link <optional-target> <link-id>",
Args: cobra.ExactArgs(1),
Use: "forget-link <link-id>",
Run: func(cmd *cobra.Command, args []string) {
options.Cmd = cmd
options.Args = args
err := options.Run()
action.Cmd = cmd
action.Args = args
err := action.Run()
cmdhelper.CheckErr(err)
},
}
action.AddAgentOptions(cmd)
return cmd
}
// Run implements the command
func (self *ForgetLinkAgentAction) Run() error {
var addr string
var err error
if len(self.Args) == 2 {
addr, err = agent.ParseGopsAddress(self.Args)
if err != nil {
return err
}
}
return agent.MakeRequestF(addr, agent.CustomOpAsync, []byte{router.AgentAppId}, self.makeRequest)
return self.MakeChannelRequest(router.AgentAppId, self.makeRequest)
}
func (self *ForgetLinkAgentAction) makeRequest(conn net.Conn) error {
options := channel.DefaultOptions()
options.ConnectTimeout = time.Second
dialer := channel.NewExistingConnDialer(&identity.TokenId{Token: "agent"}, conn, nil)
ch, err := channel.NewChannel("agent", dialer, nil, options)
if err != nil {
return err
}
func (self *ForgetLinkAgentAction) makeRequest(ch channel.Channel) error {
linkId := self.Args[0]
if len(self.Args) == 2 {
linkId = self.Args[1]
}
msg := channel.NewMessage(int32(mgmt_pb.ContentType_RouterDebugForgetLinkRequestType), []byte(linkId))
reply, err := msg.WithTimeout(5 * time.Second).SendForReply(ch)
reply, err := msg.WithTimeout(self.timeout).SendForReply(ch)
if err != nil {
return err
}
@@ -0,0 +1,90 @@
/*
Copyright NetFoundry Inc.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
https://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
package agentcli
import (
"fmt"
"github.com/openziti/channel/v2"
"github.com/openziti/fabric/pb/mgmt_pb"
"github.com/openziti/fabric/router"
"github.com/openziti/ziti/ziti/cmd/common"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
"github.com/spf13/cobra"
)
type ToggleCtrlChannelAgentAction struct {
AgentOptions
enable bool
}
func NewToggleCtrlChannelAgentCmd(p common.OptionsProvider, name string, enable bool) *cobra.Command {
options := &ToggleCtrlChannelAgentAction{
AgentOptions: AgentOptions{
CommonOptions: p(),
},
enable: enable,
}
cmd := &cobra.Command{
Args: cobra.RangeArgs(0, 1),
Use: name + " <ctrl-id>",
Run: func(cmd *cobra.Command, args []string) {
options.Cmd = cmd
options.Args = args
err := options.Run()
cmdhelper.CheckErr(err)
},
}
options.AddAgentOptions(cmd)
return cmd
}
// Run implements the command
func (self *ToggleCtrlChannelAgentAction) Run() error {
return self.MakeChannelRequest(router.AgentAppId, self.makeRequest)
}
func (self *ToggleCtrlChannelAgentAction) makeRequest(ch channel.Channel) error {
var ctrlId string
if len(self.Args) > 0 {
ctrlId = self.Args[0]
}
msg := channel.NewMessage(int32(mgmt_pb.ContentType_RouterDebugToggleCtrlChannelRequestType), []byte(ctrlId))
msg.PutBoolHeader(int32(mgmt_pb.Header_CtrlChanToggle), self.enable)
reply, err := msg.WithTimeout(self.timeout).SendForReply(ch)
if err != nil {
return err
}
if reply.ContentType == channel.ContentTypeResultType {
result := channel.UnmarshalResult(reply)
if result.Success {
if len(result.Message) > 0 {
fmt.Printf("success: %v\n", result.Message)
} else {
fmt.Println("success")
}
} else {
fmt.Printf("error: %v\n", result.Message)
}
} else {
fmt.Printf("unexpected response type %v\n", reply.ContentType)
}
return nil
}
@@ -19,6 +19,7 @@ package agentcli
import (
"bytes"
"encoding/binary"
"fmt"
"github.com/openziti/agent"
"github.com/openziti/ziti/ziti/cmd/common"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
@@ -27,6 +28,7 @@ import (
"github.com/spf13/cobra"
"os"
"strings"
"time"
)
type AgentSetChannelLogLevelAction struct {
@@ -52,29 +54,30 @@ func NewSetChannelLogLevelCmd(p common.OptionsProvider) *cobra.Command {
},
}
action.AddAgentOptions(cmd)
return cmd
}
// Run implements the command
func (self *AgentSetChannelLogLevelAction) Run() error {
var addr string
var err error
if self.Cmd.Flags().Changed("timeout") {
time.AfterFunc(self.timeout, func() {
fmt.Println("operation timed out")
os.Exit(-1)
})
}
var channelArg string
var levelArg string
if len(self.Args) == 2 {
addr, err = agent.ParseGopsAddress(nil)
channelArg = self.Args[0]
levelArg = self.Args[1]
} else {
addr, err = agent.ParseGopsAddress(self.Args)
channelArg = self.Args[1]
levelArg = self.Args[2]
}
if err != nil {
return err
}
var level logrus.Level
var found bool
for _, l := range logrus.AllLevels {
@@ -95,5 +98,13 @@ func (self *AgentSetChannelLogLevelAction) Run() error {
buf.Write([]byte(channelArg))
buf.WriteByte(byte(level))
if len(self.Args) == 2 {
return self.MakeRequest(agent.SetChannelLogLevel, buf.Bytes(), self.CopyToWriter(os.Stdout))
}
addr, err := agent.ParseGopsAddress(self.Args)
if err != nil {
return err
}
return agent.MakeRequest(addr, agent.SetChannelLogLevel, buf.Bytes(), os.Stdout)
}
+23 -11
View File
@@ -17,6 +17,7 @@
package agentcli
import (
"fmt"
"github.com/openziti/agent"
"github.com/openziti/ziti/ziti/cmd/common"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
@@ -25,6 +26,7 @@ import (
"github.com/spf13/cobra"
"os"
"strings"
"time"
)
type AgentSetLogLevelAction struct {
@@ -50,24 +52,25 @@ func NewSetLogLevelCmd(p common.OptionsProvider) *cobra.Command {
},
}
action.AddAgentOptions(cmd)
return cmd
}
// Run implements the command
func (self *AgentSetLogLevelAction) Run() error {
var addr string
var err error
var levelArg string
if len(self.Args) == 1 {
addr, err = agent.ParseGopsAddress(nil)
levelArg = self.Args[0]
} else {
addr, err = agent.ParseGopsAddress(self.Args)
levelArg = self.Args[1]
if self.Cmd.Flags().Changed("timeout") {
time.AfterFunc(self.timeout, func() {
fmt.Println("operation timed out")
os.Exit(-1)
})
}
if err != nil {
return err
var levelArg string
if len(self.Args) == 1 {
levelArg = self.Args[0]
} else {
levelArg = self.Args[1]
}
var level logrus.Level
@@ -84,5 +87,14 @@ func (self *AgentSetLogLevelAction) Run() error {
}
buf := []byte{byte(level)}
if len(self.Args) == 1 {
return self.MakeRequest(agent.SetLogLevel, buf, self.CopyToWriter(os.Stdout))
}
addr, err := agent.ParseGopsAddress(self.Args)
if err != nil {
return err
}
return agent.MakeRequest(addr, agent.SetLogLevel, buf, os.Stdout)
}
+24 -12
View File
@@ -18,12 +18,14 @@ package agentcli
import (
"encoding/binary"
"fmt"
"github.com/openziti/agent"
"github.com/openziti/ziti/ziti/cmd/common"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
"github.com/spf13/cobra"
"os"
"strconv"
"time"
)
type AgentSetGcAction struct {
@@ -49,24 +51,25 @@ func NewSetGcCmd(p common.OptionsProvider) *cobra.Command {
},
}
action.AddAgentOptions(cmd)
return cmd
}
// Run implements the command
func (o *AgentSetGcAction) Run() error {
var addr string
var err error
var pctArg string
if len(o.Args) == 1 {
addr, err = agent.ParseGopsAddress(nil)
pctArg = o.Args[0]
} else {
addr, err = agent.ParseGopsAddress(o.Args)
pctArg = o.Args[1]
func (self *AgentSetGcAction) Run() error {
if self.Cmd.Flags().Changed("timeout") {
time.AfterFunc(self.timeout, func() {
fmt.Println("operation timed out")
os.Exit(-1)
})
}
if err != nil {
return err
var pctArg string
if len(self.Args) == 1 {
pctArg = self.Args[0]
} else {
pctArg = self.Args[1]
}
perc, err := strconv.ParseInt(pctArg, 10, strconv.IntSize)
@@ -76,5 +79,14 @@ func (o *AgentSetGcAction) Run() error {
buf := make([]byte, binary.MaxVarintLen64)
binary.PutVarint(buf, perc)
if len(self.Args) == 1 {
return self.MakeRequest(agent.SetGCPercent, buf, self.CopyToWriter(os.Stdout))
}
addr, err := agent.ParseGopsAddress(self.Args)
if err != nil {
return err
}
return agent.MakeRequest(addr, agent.SetGCPercent, buf, os.Stdout)
}
+26 -7
View File
@@ -28,6 +28,29 @@ type SimpleAgentAction struct {
AgentOptions
}
func NewSimpleAgentCmd(name string, op byte, p common.OptionsProvider, desc string) *cobra.Command {
action := &SimpleAgentAction{
AgentOptions: AgentOptions{
CommonOptions: p(),
},
}
cmd := &cobra.Command{
Args: cobra.MaximumNArgs(1),
Use: name + " <optional-target> ",
Short: desc,
RunE: func(cmd *cobra.Command, args []string) error {
action.Cmd = cmd
action.Args = args
return action.RunCopyOut(op, nil, os.Stdout)
},
}
action.AddAgentOptions(cmd)
return cmd
}
func NewSimpleAgentCustomCmd(name string, appId AgentAppId, op byte, p common.OptionsProvider) *cobra.Command {
action := &SimpleAgentAction{
AgentOptions: AgentOptions{
@@ -46,17 +69,13 @@ func NewSimpleAgentCustomCmd(name string, appId AgentAppId, op byte, p common.Op
},
}
action.AddAgentOptions(cmd)
return cmd
}
// Run implements the command
func (self *SimpleAgentAction) Run(appId AgentAppId, op byte) error {
addr, err := agent.ParseGopsAddress(self.Args)
if err != nil {
return err
}
buf := []byte{byte(appId), op}
return agent.MakeRequest(addr, agent.CustomOp, buf, os.Stdout)
return self.RunCopyOut(agent.CustomOpAsync, buf, os.Stdout)
}
+5 -6
View File
@@ -17,6 +17,7 @@
package agentcli
import (
"fmt"
"github.com/openziti/agent"
"github.com/openziti/ziti/ziti/cmd/common"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
@@ -49,7 +50,8 @@ func NewStackCmd(p common.OptionsProvider) *cobra.Command {
},
}
cmd.Flags().DurationVar(&action.StackTimeout, "stack-timeout", 5*time.Second, "Timeout for stack operation")
action.AddAgentOptions(cmd)
cmd.Flags().DurationVar(&action.StackTimeout, "stack-timeout", 5*time.Second, "Timeout for stack operation (deprecated, use --timeout instead)")
return cmd
}
@@ -57,11 +59,8 @@ func NewStackCmd(p common.OptionsProvider) *cobra.Command {
// Run implements the command
func (o *AgentStackAction) Run() error {
time.AfterFunc(o.StackTimeout, func() {
fmt.Println("operation timed out")
os.Exit(-1)
})
addr, err := agent.ParseGopsAddress(o.Args)
if err != nil {
return err
}
return agent.MakeRequest(addr, agent.StackTrace, nil, os.Stdout)
return o.RunCopyOut(agent.Stats, nil, os.Stdout)
}
-60
View File
@@ -1,60 +0,0 @@
/*
Copyright NetFoundry Inc.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
https://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
package agentcli
import (
"github.com/openziti/agent"
"github.com/openziti/ziti/ziti/cmd/common"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
"github.com/spf13/cobra"
"os"
)
type AgentStatsAction struct {
AgentOptions
}
func NewStatsCmd(p common.OptionsProvider) *cobra.Command {
action := &AgentStatsAction{
AgentOptions: AgentOptions{
CommonOptions: p(),
},
}
cmd := &cobra.Command{
Use: "stats <optional-target>",
Short: "Emits some runtime information (# go-routines, threads, cpus, etc) from the target application",
Args: cobra.MaximumNArgs(1),
Run: func(cmd *cobra.Command, args []string) {
action.Cmd = cmd
action.Args = args
err := action.Run()
cmdhelper.CheckErr(err)
},
}
return cmd
}
// Run implements the command
func (self *AgentStatsAction) Run() error {
addr, err := agent.ParseGopsAddress(self.Args)
if err != nil {
return err
}
return agent.MakeRequest(addr, agent.Stats, nil, os.Stdout)
}
+4 -13
View File
@@ -19,7 +19,6 @@ package agentcli
import (
"github.com/openziti/agent"
"github.com/openziti/ziti/ziti/cmd/common"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
"github.com/spf13/cobra"
"os"
)
@@ -38,22 +37,14 @@ func NewTraceCmd(p common.OptionsProvider) *cobra.Command {
cmd := &cobra.Command{
Use: "trace",
Short: "Turn tracing on for 5 seconds in the target application",
Run: func(cmd *cobra.Command, args []string) {
RunE: func(cmd *cobra.Command, args []string) error {
action.Cmd = cmd
action.Args = args
err := action.Run()
cmdhelper.CheckErr(err)
return action.RunCopyOut(agent.Trace, nil, os.Stdout)
},
}
action.AddAgentOptions(cmd)
return cmd
}
// Run implements the command
func (self *AgentTraceAction) Run() error {
addr, err := agent.ParseGopsAddress(self.Args)
if err != nil {
return err
}
return agent.MakeRequest(addr, agent.Trace, nil, os.Stdout)
}
@@ -70,7 +70,7 @@ func (self *AgentEchoServerUpdateTerminatorAction) Run() error {
}
}
return agentcli.MakeAgentChannelRequest(addr, agent.CustomOpAsync, []byte{byte(EchoServerAppId)}, self.makeRequest)
return agentcli.MakeAgentChannelRequest(addr, EchoServerAppId, self.makeRequest)
}
func (self *AgentEchoServerUpdateTerminatorAction) makeRequest(ch channel.Channel) error {
+1 -1
View File
@@ -21,7 +21,7 @@ import (
"errors"
"fmt"
"github.com/Jeffail/gabs"
"github.com/openziti/edge/rest_management_api_client/authenticator"
"github.com/openziti/edge-api/rest_management_api_client/authenticator"
"github.com/openziti/foundation/v2/term"
"github.com/openziti/ziti/ziti/cmd/api"
"github.com/openziti/ziti/ziti/cmd/helpers"
+2 -2
View File
@@ -18,8 +18,8 @@ package edge
import (
"fmt"
"github.com/openziti/edge/rest_management_api_client/certificate_authority"
"github.com/openziti/edge/rest_model"
"github.com/openziti/edge-api/rest_management_api_client/certificate_authority"
"github.com/openziti/edge-api/rest_model"
"github.com/openziti/ziti/ziti/cmd/api"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
"github.com/openziti/ziti/ziti/util"
+2 -2
View File
@@ -20,8 +20,8 @@ import (
"context"
"fmt"
"github.com/go-openapi/strfmt"
"github.com/openziti/edge/rest_management_api_client/enrollment"
"github.com/openziti/edge/rest_model"
"github.com/openziti/edge-api/rest_management_api_client/enrollment"
"github.com/openziti/edge-api/rest_model"
"github.com/openziti/ziti/ziti/cmd/api"
"github.com/openziti/ziti/ziti/cmd/common"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
+2 -2
View File
@@ -19,8 +19,8 @@ package edge
import (
"fmt"
"github.com/Jeffail/gabs"
"github.com/openziti/edge/rest_management_api_client/posture_checks"
"github.com/openziti/edge/rest_model"
"github.com/openziti/edge-api/rest_management_api_client/posture_checks"
"github.com/openziti/edge-api/rest_model"
"github.com/openziti/ziti/ziti/cmd/api"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
"github.com/openziti/ziti/ziti/util"
+2 -2
View File
@@ -34,8 +34,8 @@ import (
"strings"
"github.com/Jeffail/gabs"
"github.com/openziti/edge/rest_management_api_client/certificate_authority"
"github.com/openziti/edge/rest_model"
"github.com/openziti/edge-api/rest_management_api_client/certificate_authority"
"github.com/openziti/edge-api/rest_model"
"github.com/pkg/errors"
"github.com/spf13/cobra"
)
+1 -1
View File
@@ -21,7 +21,7 @@ import (
"errors"
"fmt"
"github.com/Jeffail/gabs"
"github.com/openziti/edge/rest_management_api_client/authenticator"
"github.com/openziti/edge-api/rest_management_api_client/authenticator"
"github.com/openziti/foundation/v2/term"
"github.com/openziti/ziti/ziti/cmd/api"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
+2 -2
View File
@@ -18,8 +18,8 @@ package edge
import (
"fmt"
"github.com/openziti/edge/rest_management_api_client/certificate_authority"
"github.com/openziti/edge/rest_model"
"github.com/openziti/edge-api/rest_management_api_client/certificate_authority"
"github.com/openziti/edge-api/rest_model"
"github.com/openziti/ziti/ziti/cmd/api"
"github.com/openziti/ziti/ziti/cmd/helpers"
"github.com/openziti/ziti/ziti/util"
+81
View File
@@ -0,0 +1,81 @@
package fabric
import (
"context"
"github.com/jedib0t/go-pretty/v6/table"
"github.com/openziti/fabric/rest_client/raft"
"github.com/openziti/ziti/ziti/cmd/api"
"github.com/openziti/ziti/ziti/cmd/common"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"
"github.com/openziti/ziti/ziti/util"
"github.com/spf13/cobra"
)
// newRaftCmd creates a command object for the "controller raft" command
func newRaftCmd(p common.OptionsProvider) *cobra.Command {
cmd := &cobra.Command{
Use: "raft",
Short: "Raft operations",
Run: func(cmd *cobra.Command, args []string) {
err := cmd.Help()
cmdhelper.CheckErr(err)
},
}
cmd.AddCommand(newRaftListMembersCmd(p))
return cmd
}
type raftListMembersOptions struct {
api.Options
}
func newRaftListMembersCmd(p common.OptionsProvider) *cobra.Command {
options := &raftListMembersOptions{
Options: api.Options{CommonOptions: p()},
}
cmd := &cobra.Command{
Use: "list-members",
Short: "list cluster members and their status",
Args: cobra.ExactArgs(0),
Run: func(cmd *cobra.Command, args []string) {
options.Cmd = cmd
options.Args = args
err := raftListMembers(options)
cmdhelper.CheckErr(err)
},
}
// allow interspersing positional args and flags
cmd.Flags().SetInterspersed(true)
options.AddCommonFlags(cmd)
return cmd
}
func raftListMembers(o *raftListMembersOptions) error {
client, err := util.NewFabricManagementClient(o)
if err != nil {
return err
}
members, err := client.Raft.RaftListMembers(&raft.RaftListMembersParams{
Context: context.Background(),
})
if err != nil {
return err
}
t := table.NewWriter()
t.SetStyle(table.StyleRounded)
t.AppendHeader(table.Row{"Id", "Address", "Voter", "Leader", "Version", "Connected"})
for _, m := range members.Payload.Values {
t.AppendRow(table.Row{*m.ID, *m.Address, *m.Voter, *m.Leader, *m.Version, *m.Connected})
}
api.RenderTable(&api.Options{
CommonOptions: o.CommonOptions,
}, t, nil)
return nil
}
+1
View File
@@ -35,6 +35,7 @@ func NewFabricCmd(p common.OptionsProvider) *cobra.Command {
fabricCmd.AddCommand(newInspectCmd(p))
fabricCmd.AddCommand(newDbCmd(p))
fabricCmd.AddCommand(newStreamCommand(p))
fabricCmd.AddCommand(newRaftCmd(p))
return fabricCmd
}
+2
View File
@@ -54,6 +54,7 @@ func NewControllerCmd() *cobra.Command {
cmd.PersistentFlags().BoolVarP(&verbose, "verbose", "v", false, "Enable verbose logging")
cmd.PersistentFlags().BoolVarP(&cliAgentEnabled, "cliagent", "a", true, "Enable/disabled CLI Agent (enabled by default)")
cmd.PersistentFlags().StringVar(&cliAgentAddr, "cli-agent-addr", "", "Specify where CLI Agent should list (ex: unix:/tmp/myfile.sock or tcp:127.0.0.1:10001)")
cmd.PersistentFlags().StringVar(&cliAgentAlias, "cli-agent-alias", "", "Alias which can be used by ziti agent commands to find this instance")
cmd.PersistentFlags().StringVar(&logFormatter, "log-formatter", "", "Specify log formatter [json|pfxlog|text]")
cmd.AddCommand(NewRunCmd())
@@ -68,6 +69,7 @@ func NewControllerCmd() *cobra.Command {
var verbose bool
var cliAgentEnabled bool
var cliAgentAddr string
var cliAgentAlias string
var logFormatter string
func Execute() {
+7 -2
View File
@@ -74,9 +74,14 @@ func run(cmd *cobra.Command, args []string) {
edgeController.Initialize()
if cliAgentEnabled {
options := agent.Options{Addr: cliAgentAddr}
options := agent.Options{
Addr: cliAgentAddr,
AppId: config.Id.Token,
AppType: "controller",
AppVersion: version.GetVersion(),
AppAlias: cliAgentAlias,
}
options.CustomOps = map[byte]func(conn net.Conn) error{
agent.CustomOp: fabricController.HandleCustomAgentOp,
agent.CustomOpAsync: fabricController.HandleCustomAgentAsyncOp,
}
if err := agent.Listen(options); err != nil {
+2
View File
@@ -53,6 +53,7 @@ func NewRouterCmd() *cobra.Command {
routerCmd.PersistentFlags().StringVar(&logFormatter, "log-formatter", "", "Specify log formatter [json|pfxlog|text]")
routerCmd.PersistentFlags().BoolVar(&cliAgentEnabled, "cli-agent", true, "Enable/disable CLI Agent (enabled by default)")
routerCmd.PersistentFlags().StringVar(&cliAgentAddr, "cli-agent-addr", "", "Specify where CLI Agent should list (ex: unix:/tmp/myfile.sock or tcp:127.0.0.1:10001)")
routerCmd.PersistentFlags().StringVar(&cliAgentAlias, "cli-agent-alias", "", "Alias which can be used by ziti agent commands to find this instance")
routerCmd.PersistentFlags().BoolVar(&enableDebugOps, "debug-ops", false, "Enable/disable debug agent operations (disabled by default)")
routerCmd.AddCommand(NewRunCmd())
@@ -67,6 +68,7 @@ var logFormatter string
var cliAgentEnabled bool
var enableDebugOps bool
var cliAgentAddr string
var cliAgentAlias string
func Execute() {
if err := NewRouterCmd().Execute(); err != nil {
+7 -2
View File
@@ -49,7 +49,6 @@ func NewRunCmd() *cobra.Command {
//flags are added to an internal map and read later on, see getFlags()
runCmd.Flags().BoolP("extend", "e", false, "force the router on startup to extend enrollment certificates")
return runCmd
}
@@ -94,7 +93,13 @@ func run(cmd *cobra.Command, args []string) {
}
if cliAgentEnabled {
options := agent.Options{Addr: cliAgentAddr}
options := agent.Options{
Addr: cliAgentAddr,
AppId: config.Id.Token,
AppType: "router",
AppVersion: version.GetVersion(),
AppAlias: cliAgentAlias,
}
if config.EnableDebugOps {
enableDebugOps = true
}
+2 -3
View File
@@ -33,9 +33,8 @@ func NewHostCmd() *cobra.Command {
}
func runHost(cmd *cobra.Command, args []string) error {
root := cmd.Root()
if !root.Flag(resolverCfgFlag).Changed {
_ = root.PersistentFlags().Set(resolverCfgFlag, "")
if flag := cmd.Flag(resolverCfgFlag); !flag.Changed {
_ = flag.Value.Set("")
}
interceptor = host.New()
return nil
+4 -5
View File
@@ -37,13 +37,12 @@ func NewProxyCmd() *cobra.Command {
}
func runProxy(cmd *cobra.Command, args []string) error {
root := cmd.Root()
// Fiddle with the poll rate and resolver settings if the user didn't wan't anything special.
if !root.Flag(svcPollRateFlag).Changed {
_ = root.PersistentFlags().Set(svcPollRateFlag, strconv.FormatUint(math.MaxUint32, 10))
if flag := cmd.Flag(svcPollRateFlag); !flag.Changed {
_ = flag.Value.Set(strconv.FormatUint(math.MaxUint32, 10))
}
if !root.Flag(resolverCfgFlag).Changed {
_ = root.PersistentFlags().Set(resolverCfgFlag, "")
if flag := cmd.Flag(resolverCfgFlag); !flag.Changed {
_ = flag.Value.Set("")
}
var err error
if interceptor, err = proxy.New(net.IPv4zero, args); err != nil {
+1 -1
View File
@@ -126,7 +126,7 @@ func rootPostRun(cmd *cobra.Command, _ []string) {
ziti.SetApplication("ziti-tunnel", version.GetVersion())
resolverConfig := cmd.Flag("resolver").Value.String()
resolverConfig := cmd.Flag(resolverCfgFlag).Value.String()
resolver := dns.NewResolver(resolverConfig)
serviceListenerGroup := intercept.NewServiceListenerGroup(interceptor, resolver)
+5 -1
View File
@@ -41,9 +41,13 @@ func NewTProxyCmd() *cobra.Command {
return runTProxyCmd
}
func runTProxy(cmd *cobra.Command, args []string) error {
func runTProxy(cmd *cobra.Command, _ []string) error {
var err error
lanIf, err := cmd.Flags().GetString("lanIf")
if err != nil {
return err
}
interceptor, err = tproxy.New(lanIf)
if err != nil {
return fmt.Errorf("failed to initialize tproxy interceptor: %v", err)
+1 -1
View File
@@ -6,7 +6,7 @@ import (
"encoding/json"
"fmt"
httptransport "github.com/go-openapi/runtime/client"
"github.com/openziti/edge/rest_management_api_client"
"github.com/openziti/edge-api/rest_management_api_client"
fabric_rest_client "github.com/openziti/fabric/rest_client"
"github.com/openziti/identity"
"github.com/openziti/sdk-golang/ziti/constants"
+2 -2
View File
@@ -27,8 +27,8 @@ import (
"github.com/blang/semver"
openApiRuntime "github.com/go-openapi/runtime"
"github.com/go-openapi/strfmt"
"github.com/openziti/edge/rest_management_api_client"
"github.com/openziti/edge/rest_model"
"github.com/openziti/edge-api/rest_management_api_client"
"github.com/openziti/edge-api/rest_model"
fabric_rest_client "github.com/openziti/fabric/rest_client"
"github.com/openziti/ziti/common/version"
cmdhelper "github.com/openziti/ziti/ziti/cmd/helpers"