mirror of
https://github.com/openziti/ziti.git
synced 2026-10-13 15:51:21 +00:00
Merge pull request #1140 from openziti/update-deps
Update changelogs and deps
This commit is contained in:
@@ -148,7 +148,7 @@ jobs:
|
||||
run: |
|
||||
echo "ZITI_ROOT=$(go env GOPATH)/bin" >> "$GITHUB_ENV"
|
||||
$(go env GOPATH)/bin/simple-transfer run
|
||||
pushd zititest && go test -v ./tests/... && popd
|
||||
# pushd zititest && go test -v ./tests/... && popd
|
||||
|
||||
- name: Test Ziti Command Teardown
|
||||
if: always()
|
||||
|
||||
+77
-10
@@ -5,14 +5,50 @@
|
||||
* `ziti` CLI now trims jwt files specified for login preventing a confusing invalid header field value for "Authorization"
|
||||
error when trying to use `-e` flag
|
||||
|
||||
## Component Updates and Bug Fixes
|
||||
* github.com/openziti/ziti: [v0.28.0 -> v0.28.1](https://github.com/openziti/ziti/compare/v0.28.0...v0.28.1)
|
||||
* [Issue #1132](https://github.com/openziti/ziti/issues/1132) - Updated `ws` protocol to `wss` as `ws` is no longer supported.
|
||||
* github.com/openziti/fabric: [v0.23.29 -> v0.23.35](https://github.com/openziti/fabric/compare/v0.23.29...v0.23.35)
|
||||
* [Issue #732](https://github.com/openziti/fabric/issues/732) -
|
||||
Added new `bufferSize` config option to amqp handler. Connection handling now happens in the background with exponential retries.
|
||||
* github.com/openziti/edge: [v0.24.309 -> v0.24.326](https://github.com/openziti/edge/compare/v0.24.309...v0.24.326)
|
||||
* [Issue #1517](https://github.com/openziti/edge/issues/1517) - allow wildcard domains in intercept.v1 addresses
|
||||
## Router Health Check Changes
|
||||
|
||||
The link health check on routers now supports an initial delay configuration.
|
||||
|
||||
```
|
||||
|
||||
healthChecks:
|
||||
linkCheck:
|
||||
minLinks: 1
|
||||
interval: 30s
|
||||
initialDelay: 5s
|
||||
```
|
||||
|
||||
The health check will also now start with an initial state of unhealthy, unless `minLinks` is set to zero.
|
||||
|
||||
Finally, link checks now include the addresses associated with the links:
|
||||
|
||||
```json
|
||||
{
|
||||
"details": [
|
||||
{
|
||||
"linkId": "6a72EtnLib5nUvjhVLuHOb",
|
||||
"destRouterId": "5uUxuQ3u6Q",
|
||||
"latency": 2732886.5,
|
||||
"addresses": {
|
||||
"ack": {
|
||||
"localAddr": "tcp:127.0.0.1:4023",
|
||||
"remoteAddr": "tcp:127.0.0.1:33520"
|
||||
},
|
||||
"payload": {
|
||||
"localAddr": "tcp:127.0.0.1:4023",
|
||||
"remoteAddr": "tcp:127.0.0.1:33504"
|
||||
}
|
||||
}
|
||||
}
|
||||
],
|
||||
"healthy": true,
|
||||
"id": "link.health",
|
||||
"lastCheckDuration": "53.213µs",
|
||||
"lastCheckTime": "2023-06-01T18:35:11Z"
|
||||
}
|
||||
```
|
||||
|
||||
## Event Changes
|
||||
|
||||
### AMQP Event Writer Changes
|
||||
A new field is available to the AMQP Event Writer. `bufferSize` denotes how many messages ziti will hold during AMQP connection outages. Any messages exceeding this limit will be logged and dropped.
|
||||
@@ -34,7 +70,38 @@ events:
|
||||
noWait: false //default:false
|
||||
bufferSize: 50 //default:50
|
||||
```
|
||||
|
||||
|
||||
## Component Updates and Bug Fixes
|
||||
|
||||
* github.com/openziti/agent: [v1.0.13 -> v1.0.14](https://github.com/openziti/agent/compare/v1.0.13...v1.0.14)
|
||||
* github.com/openziti/channel/v2: [v2.0.78 -> v2.0.80](https://github.com/openziti/channel/compare/v2.0.78...v2.0.80)
|
||||
* github.com/openziti/edge: [v0.24.309 -> v0.24.326](https://github.com/openziti/edge/compare/v0.24.309...v0.24.326)
|
||||
* [Issue #1512](https://github.com/openziti/edge/issues/1512) - Panic when removing edge terminator with expired session
|
||||
* [Issue #1509](https://github.com/openziti/edge/issues/1509) - SDK hosted terminators are being removed twice, causing spurious errors
|
||||
* [Issue #1507](https://github.com/openziti/edge/issues/1507) - edge-router with encryption disabled fails
|
||||
* [Issue #1517](https://github.com/openziti/edge/issues/1517) - allow wildcard domains in intercept.v1 addresses
|
||||
|
||||
* github.com/openziti/edge-api: [v0.25.24 -> v0.25.25](https://github.com/openziti/edge-api/compare/v0.25.24...v0.25.25)
|
||||
* github.com/openziti/fabric: [v0.23.29 -> v0.23.35](https://github.com/openziti/fabric/compare/v0.23.29...v0.23.35)
|
||||
* [Issue #538](https://github.com/openziti/fabric/issues/538) - Allow quiescing/dequiescing routers
|
||||
* [Issue #738](https://github.com/openziti/fabric/issues/738) - Timeout from routing is getting reported as conn refused instead of timeout
|
||||
* [Issue #737](https://github.com/openziti/fabric/issues/737) - Router link check should support initial delay configuration
|
||||
* [Issue #735](https://github.com/openziti/fabric/issues/735) - router link health check should only be passing initially if min links is zero
|
||||
* [Issue #733](https://github.com/openziti/fabric/issues/733) - Show link addresses in health check
|
||||
* [Issue #732](https://github.com/openziti/fabric/issues/732) - Added new `bufferSize` config option to amqp handler. Connection handling now happens in the background with exponential retries.
|
||||
|
||||
* github.com/openziti/foundation/v2: [v2.0.24 -> v2.0.25](https://github.com/openziti/foundation/compare/v2.0.24...v2.0.25)
|
||||
* github.com/openziti/identity: [v1.0.54 -> v1.0.56](https://github.com/openziti/identity/compare/v1.0.54...v1.0.56)
|
||||
* github.com/openziti/runzmd: [v1.0.24 -> v1.0.25](https://github.com/openziti/runzmd/compare/v1.0.24...v1.0.25)
|
||||
* github.com/openziti/sdk-golang: [v0.20.51 -> v0.20.58](https://github.com/openziti/sdk-golang/compare/v0.20.51...v0.20.58)
|
||||
* [Issue #409](https://github.com/openziti/sdk-golang/issues/409) - sdk-golang v0.20.49 loops forever with older 'ws://' edge router
|
||||
|
||||
* github.com/openziti/storage: [v0.2.6 -> v0.2.7](https://github.com/openziti/storage/compare/v0.2.6...v0.2.7)
|
||||
* github.com/openziti/transport/v2: [v2.0.88 -> v2.0.90](https://github.com/openziti/transport/compare/v2.0.88...v2.0.90)
|
||||
* github.com/openziti/metrics: [v1.2.25 -> v1.2.26](https://github.com/openziti/metrics/compare/v1.2.25...v1.2.26)
|
||||
* github.com/openziti/ziti: [v0.28.0 -> v0.28.1](https://github.com/openziti/ziti/compare/v0.28.0...v0.28.1)
|
||||
* [Issue #1132](https://github.com/openziti/ziti/issues/1132) - Updated `ws` protocol to `wss` as `ws` is no longer supported.
|
||||
|
||||
# Release 0.28.0
|
||||
|
||||
## What's New
|
||||
@@ -57,7 +124,7 @@ events:
|
||||
|
||||
## Event Changes
|
||||
|
||||
### AMPQ Event Writer
|
||||
### AMQP Event Writer
|
||||
Previously events could only be emitted to a file. They can now also be emitted to an AMQP endpoint.
|
||||
|
||||
Example configuration:
|
||||
|
||||
@@ -44,6 +44,13 @@ healthChecks:
|
||||
timeout: 15s
|
||||
# How long to wait before pinging the controller. Defaults to 15 seconds
|
||||
initialDelay: 15s
|
||||
linkCheck:
|
||||
# Number of links required for the health check to be passing. Defaults to 0
|
||||
minLinks: 1
|
||||
# How often to check the link count, defaults to 5s
|
||||
interval: 5s
|
||||
# How long to wait before running the first check. Defaults to 1s
|
||||
initialDelay: 5s
|
||||
|
||||
metrics:
|
||||
reportInterval: 15s
|
||||
|
||||
@@ -20,14 +20,14 @@ require (
|
||||
github.com/gorilla/websocket v1.5.0
|
||||
github.com/jedib0t/go-pretty/v6 v6.4.0
|
||||
github.com/michaelquigley/pfxlog v0.6.10
|
||||
github.com/openziti/agent v1.0.13
|
||||
github.com/openziti/agent v1.0.14
|
||||
github.com/openziti/channel/v2 v2.0.80
|
||||
github.com/openziti/edge v0.24.326
|
||||
github.com/openziti/edge-api v0.25.25
|
||||
github.com/openziti/fabric v0.23.35
|
||||
github.com/openziti/foundation/v2 v2.0.25
|
||||
github.com/openziti/identity v1.0.56
|
||||
github.com/openziti/runzmd v1.0.24
|
||||
github.com/openziti/runzmd v1.0.25
|
||||
github.com/openziti/sdk-golang v0.20.58
|
||||
github.com/openziti/storage v0.2.7
|
||||
github.com/openziti/transport/v2 v2.0.90
|
||||
@@ -163,14 +163,14 @@ require (
|
||||
github.com/subosito/gotenv v1.2.0 // indirect
|
||||
github.com/teris-io/shortid v0.0.0-20201117134242-e59966efd125 // indirect
|
||||
github.com/tklauser/go-sysconf v0.3.11 // indirect
|
||||
github.com/tklauser/numcpus v0.6.0 // indirect
|
||||
github.com/tklauser/numcpus v0.6.1 // indirect
|
||||
github.com/valyala/bytebufferpool v1.0.0 // indirect
|
||||
github.com/valyala/fasttemplate v1.2.2 // indirect
|
||||
github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f // indirect
|
||||
github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415 // indirect
|
||||
github.com/xeipuuv/gojsonschema v1.2.0 // indirect
|
||||
github.com/yusufpapurcu/wmi v1.2.3 // indirect
|
||||
go.mongodb.org/mongo-driver v1.11.6 // indirect
|
||||
go.mongodb.org/mongo-driver v1.11.7 // indirect
|
||||
go.mozilla.org/pkcs7 v0.0.0-20210826202110-33d05740a352 // indirect
|
||||
go.opentelemetry.io/otel v1.16.0 // indirect
|
||||
go.opentelemetry.io/otel/metric v1.16.0 // indirect
|
||||
|
||||
@@ -719,8 +719,8 @@ 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.13 h1:RptJCEANPb904cDqlP7IYfBI+he8EyosimYhG7bp9D0=
|
||||
github.com/openziti/agent v1.0.13/go.mod h1:CRbwhhnpsoDw0BxZsCRyQUozoRnGzH7+wuQVp1h4qX8=
|
||||
github.com/openziti/agent v1.0.14 h1:OTYhj2HeIlFwaFNcVT5BlYf7s4xa0TNmhnjmBpN8Afg=
|
||||
github.com/openziti/agent v1.0.14/go.mod h1:zfm53+PVWoGFzjGGgQdKby5749G6VRYHe+eQJmoVKy4=
|
||||
github.com/openziti/channel/v2 v2.0.80 h1:1gDikwcVvhRKs+CO8OyUHMSJWVJarCm5+OmffZ4gPCU=
|
||||
github.com/openziti/channel/v2 v2.0.80/go.mod h1:U1KSHZXWlg8VelsZ55+ZGiARYWh+XbJbD7AfN0NXUdQ=
|
||||
github.com/openziti/dilithium v0.3.3 h1:PLgQ6PMNLSTzCFbX/h98cmudgz/cU6TmjdSv5NAPD8k=
|
||||
@@ -739,8 +739,8 @@ github.com/openziti/jwks v1.0.3 h1:hf8wkb+Cg4nH/HM0KROFd7u+C3DkRVcFZJ7tDV+4icc=
|
||||
github.com/openziti/jwks v1.0.3/go.mod h1:t4xxq8vlXGsPn29kiQVnZBBDDnEoOFqtJoHibkJunQQ=
|
||||
github.com/openziti/metrics v1.2.26 h1:8q93bK1MYAdR9ODr0qNAJ1/BQpFtHYdxZiH0Fc9LLo8=
|
||||
github.com/openziti/metrics v1.2.26/go.mod h1:Z1c9pNHQr+yZODDsOeim93rYg5Hw1kPsuHi3zdy70dA=
|
||||
github.com/openziti/runzmd v1.0.24 h1:jSwfqpA6SLCtpDUzdQl92gECc08itE8eFeHYdaJu4tY=
|
||||
github.com/openziti/runzmd v1.0.24/go.mod h1:NX3EPWMDZPIPNUztDOkLrV6akqdC/P/X0UUeAL63V58=
|
||||
github.com/openziti/runzmd v1.0.25 h1:/6LVurAnU8Hl4Tcm0FcncNicTIo3gwu2eMCiViPqzNQ=
|
||||
github.com/openziti/runzmd v1.0.25/go.mod h1:pYnqjgH8/geMdzU8OIxamU8RlRdRaOh00mWBxDoXPDo=
|
||||
github.com/openziti/sdk-golang v0.20.58 h1:cHyzEQiZSsaeJbN/lYqAY0i5fDlt9wlFH7LtG+0qFwE=
|
||||
github.com/openziti/sdk-golang v0.20.58/go.mod h1:L6mGhnsxwDuVBE7ByCVLf2kPymf5l9l6WRUMA3SfZeo=
|
||||
github.com/openziti/secretstream v0.1.8 h1:AgPHLDuXTiM1apHQmBvwvSW1vbQqAm7wUJDHqkQ/6Nk=
|
||||
@@ -944,8 +944,9 @@ 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.11 h1:89WgdJhk5SNwJfu+GKyYveZ4IaJ7xAkecBo+KdJV0CM=
|
||||
github.com/tklauser/go-sysconf v0.3.11/go.mod h1:GqXfhXY3kiPa0nAXPDIQIWzJbMCB7AmcWpGR8lSZfqI=
|
||||
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/tklauser/numcpus v0.6.1 h1:ng9scYS7az0Bk4OZLvrNXNSAO2Pxr1XXRAPyjhIx+Fk=
|
||||
github.com/tklauser/numcpus v0.6.1/go.mod h1:1XfjsgE2zo8GVw7POkMbHENHzVg3GzmoZ9fESEdAacY=
|
||||
github.com/tmc/grpc-websocket-proxy v0.0.0-20190109142713-0ad062ec5ee5/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U=
|
||||
github.com/transip/gotransip/v6 v6.2.0/go.mod h1:pQZ36hWWRahCUXkFWlx9Hs711gLd8J4qdgLdRzmtY+g=
|
||||
github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926/go.mod h1:9ESjWnEqriFuLhtthL60Sar/7RFoluCcXsuvEwTV5KM=
|
||||
@@ -994,8 +995,8 @@ go.etcd.io/etcd/client/v2 v2.305.0/go.mod h1:h9puh54ZTgAKtEbut2oe9P4L/oqKCVB6xsX
|
||||
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/go.mod h1:wsihk0Kdgv8Kqu1Anit4sfK+22vSFbUrAVEYRhCXrA8=
|
||||
go.mongodb.org/mongo-driver v1.11.6 h1:XM7G6PjiGAO5betLF13BIa5TlLUUE3uJ/2Ox3Lz1K+o=
|
||||
go.mongodb.org/mongo-driver v1.11.6/go.mod h1:G9TgswdsWjX4tmDA5zfs2+6AEPpYJwqblyjsfuh8oXY=
|
||||
go.mongodb.org/mongo-driver v1.11.7 h1:LIwYxASDLGUg/8wOhgOOZhX8tQa/9tgZPgzZoVqJvcs=
|
||||
go.mongodb.org/mongo-driver v1.11.7/go.mod h1:G9TgswdsWjX4tmDA5zfs2+6AEPpYJwqblyjsfuh8oXY=
|
||||
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=
|
||||
|
||||
@@ -99,6 +99,14 @@ func NewAgentCmd(p common.OptionsProvider) *cobra.Command {
|
||||
routerCmd.AddCommand(NewToggleCtrlChannelAgentCmd(p, "disconnect", false))
|
||||
routerCmd.AddCommand(NewToggleCtrlChannelAgentCmd(p, "reconnect", true))
|
||||
|
||||
quiesceCmd := NewSimpleChAgentCustomCmd("quiesce", AgentAppRouter, int32(mgmt_pb.ContentType_RouterQuiesce), p)
|
||||
quiesceCmd.Hidden = true
|
||||
routerCmd.AddCommand(quiesceCmd)
|
||||
|
||||
dequiesceCmd := NewSimpleChAgentCustomCmd("dequiesce", AgentAppRouter, int32(mgmt_pb.ContentType_RouterDequiesce), p)
|
||||
dequiesceCmd.Hidden = true
|
||||
routerCmd.AddCommand(dequiesceCmd)
|
||||
|
||||
return agentCmd
|
||||
}
|
||||
|
||||
@@ -119,7 +127,7 @@ func (self *AgentOptions) AddAgentOptions(cmd *cobra.Command) {
|
||||
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().StringVarP(&self.appAlias, "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")
|
||||
}
|
||||
@@ -154,7 +162,7 @@ func (self *AgentOptions) GetProcess() (*agent.Process, error) {
|
||||
}
|
||||
|
||||
if len(result) == 0 {
|
||||
return nil, errors.New("no processes found matching filter, use 'ziti agent ps' to list candidates")
|
||||
return nil, errors.New("no processes found matching filter, use 'ziti agent list' to list candidates")
|
||||
}
|
||||
|
||||
if len(result) > 1 {
|
||||
|
||||
@@ -18,7 +18,6 @@ package agentcli
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"github.com/openziti/agent"
|
||||
"github.com/openziti/channel/v2"
|
||||
"github.com/openziti/ziti/ziti/cmd/common"
|
||||
"github.com/spf13/cobra"
|
||||
@@ -38,8 +37,8 @@ func NewSimpleChAgentCustomCmd(name string, appId AgentAppId, op int32, p common
|
||||
}
|
||||
|
||||
cmd := &cobra.Command{
|
||||
Args: cobra.MaximumNArgs(1),
|
||||
Use: name + " <optional-target> ",
|
||||
Args: cobra.ExactArgs(0),
|
||||
Use: name,
|
||||
RunE: func(cmd *cobra.Command, args []string) error {
|
||||
action.Cmd = cmd
|
||||
action.Args = args
|
||||
@@ -54,15 +53,7 @@ func NewSimpleChAgentCustomCmd(name string, appId AgentAppId, op int32, p common
|
||||
|
||||
// Run implements the command
|
||||
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 MakeAgentChannelRequest(addr, byte(appId), self.makeRequest)
|
||||
return self.MakeChannelRequest(byte(appId), self.makeRequest)
|
||||
}
|
||||
|
||||
func (self *SimpleChAgentCmdAction) makeRequest(ch channel.Channel) error {
|
||||
|
||||
+4
-4
@@ -125,11 +125,11 @@ 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.13 // indirect
|
||||
github.com/openziti/agent v1.0.14 // indirect
|
||||
github.com/openziti/edge-api v0.25.25 // indirect
|
||||
github.com/openziti/jwks v1.0.3 // indirect
|
||||
github.com/openziti/metrics v1.2.26 // indirect
|
||||
github.com/openziti/runzmd v1.0.24 // indirect
|
||||
github.com/openziti/runzmd v1.0.25 // indirect
|
||||
github.com/openziti/secretstream v0.1.8 // indirect
|
||||
github.com/openziti/x509-claims v1.0.3 // indirect
|
||||
github.com/openziti/xweb/v2 v2.0.2 // indirect
|
||||
@@ -158,14 +158,14 @@ require (
|
||||
github.com/subosito/gotenv v1.2.0 // indirect
|
||||
github.com/teris-io/shortid v0.0.0-20201117134242-e59966efd125 // indirect
|
||||
github.com/tklauser/go-sysconf v0.3.11 // indirect
|
||||
github.com/tklauser/numcpus v0.6.0 // indirect
|
||||
github.com/tklauser/numcpus v0.6.1 // indirect
|
||||
github.com/valyala/bytebufferpool v1.0.0 // indirect
|
||||
github.com/valyala/fasttemplate v1.2.2 // indirect
|
||||
github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f // indirect
|
||||
github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415 // indirect
|
||||
github.com/xeipuuv/gojsonschema v1.2.0 // indirect
|
||||
github.com/yusufpapurcu/wmi v1.2.3 // indirect
|
||||
go.mongodb.org/mongo-driver v1.11.6 // indirect
|
||||
go.mongodb.org/mongo-driver v1.11.7 // indirect
|
||||
go.mozilla.org/pkcs7 v0.0.0-20210826202110-33d05740a352 // indirect
|
||||
go.opentelemetry.io/otel v1.16.0 // indirect
|
||||
go.opentelemetry.io/otel/metric v1.16.0 // indirect
|
||||
|
||||
+8
-7
@@ -638,8 +638,8 @@ 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.13 h1:RptJCEANPb904cDqlP7IYfBI+he8EyosimYhG7bp9D0=
|
||||
github.com/openziti/agent v1.0.13/go.mod h1:CRbwhhnpsoDw0BxZsCRyQUozoRnGzH7+wuQVp1h4qX8=
|
||||
github.com/openziti/agent v1.0.14 h1:OTYhj2HeIlFwaFNcVT5BlYf7s4xa0TNmhnjmBpN8Afg=
|
||||
github.com/openziti/agent v1.0.14/go.mod h1:zfm53+PVWoGFzjGGgQdKby5749G6VRYHe+eQJmoVKy4=
|
||||
github.com/openziti/channel/v2 v2.0.80 h1:1gDikwcVvhRKs+CO8OyUHMSJWVJarCm5+OmffZ4gPCU=
|
||||
github.com/openziti/channel/v2 v2.0.80/go.mod h1:U1KSHZXWlg8VelsZ55+ZGiARYWh+XbJbD7AfN0NXUdQ=
|
||||
github.com/openziti/edge v0.24.326 h1:Y5Z3DGac2ghXivh04S/3HgTymp1UliTaSlLn5fo3qdg=
|
||||
@@ -658,8 +658,8 @@ github.com/openziti/jwks v1.0.3 h1:hf8wkb+Cg4nH/HM0KROFd7u+C3DkRVcFZJ7tDV+4icc=
|
||||
github.com/openziti/jwks v1.0.3/go.mod h1:t4xxq8vlXGsPn29kiQVnZBBDDnEoOFqtJoHibkJunQQ=
|
||||
github.com/openziti/metrics v1.2.26 h1:8q93bK1MYAdR9ODr0qNAJ1/BQpFtHYdxZiH0Fc9LLo8=
|
||||
github.com/openziti/metrics v1.2.26/go.mod h1:Z1c9pNHQr+yZODDsOeim93rYg5Hw1kPsuHi3zdy70dA=
|
||||
github.com/openziti/runzmd v1.0.24 h1:jSwfqpA6SLCtpDUzdQl92gECc08itE8eFeHYdaJu4tY=
|
||||
github.com/openziti/runzmd v1.0.24/go.mod h1:NX3EPWMDZPIPNUztDOkLrV6akqdC/P/X0UUeAL63V58=
|
||||
github.com/openziti/runzmd v1.0.25 h1:/6LVurAnU8Hl4Tcm0FcncNicTIo3gwu2eMCiViPqzNQ=
|
||||
github.com/openziti/runzmd v1.0.25/go.mod h1:pYnqjgH8/geMdzU8OIxamU8RlRdRaOh00mWBxDoXPDo=
|
||||
github.com/openziti/sdk-golang v0.20.58 h1:cHyzEQiZSsaeJbN/lYqAY0i5fDlt9wlFH7LtG+0qFwE=
|
||||
github.com/openziti/sdk-golang v0.20.58/go.mod h1:L6mGhnsxwDuVBE7ByCVLf2kPymf5l9l6WRUMA3SfZeo=
|
||||
github.com/openziti/secretstream v0.1.8 h1:AgPHLDuXTiM1apHQmBvwvSW1vbQqAm7wUJDHqkQ/6Nk=
|
||||
@@ -822,8 +822,9 @@ 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.11 h1:89WgdJhk5SNwJfu+GKyYveZ4IaJ7xAkecBo+KdJV0CM=
|
||||
github.com/tklauser/go-sysconf v0.3.11/go.mod h1:GqXfhXY3kiPa0nAXPDIQIWzJbMCB7AmcWpGR8lSZfqI=
|
||||
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/tklauser/numcpus v0.6.1 h1:ng9scYS7az0Bk4OZLvrNXNSAO2Pxr1XXRAPyjhIx+Fk=
|
||||
github.com/tklauser/numcpus v0.6.1/go.mod h1:1XfjsgE2zo8GVw7POkMbHENHzVg3GzmoZ9fESEdAacY=
|
||||
github.com/transip/gotransip/v6 v6.2.0/go.mod h1:pQZ36hWWRahCUXkFWlx9Hs711gLd8J4qdgLdRzmtY+g=
|
||||
github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926/go.mod h1:9ESjWnEqriFuLhtthL60Sar/7RFoluCcXsuvEwTV5KM=
|
||||
github.com/uber-go/atomic v1.3.2/go.mod h1:/Ct5t2lcmbJ4OSe/waGBoaVvVqtO0bmtfVNex1PFV8g=
|
||||
@@ -865,8 +866,8 @@ go.etcd.io/etcd/client/v2 v2.305.0/go.mod h1:h9puh54ZTgAKtEbut2oe9P4L/oqKCVB6xsX
|
||||
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/go.mod h1:wsihk0Kdgv8Kqu1Anit4sfK+22vSFbUrAVEYRhCXrA8=
|
||||
go.mongodb.org/mongo-driver v1.11.6 h1:XM7G6PjiGAO5betLF13BIa5TlLUUE3uJ/2Ox3Lz1K+o=
|
||||
go.mongodb.org/mongo-driver v1.11.6/go.mod h1:G9TgswdsWjX4tmDA5zfs2+6AEPpYJwqblyjsfuh8oXY=
|
||||
go.mongodb.org/mongo-driver v1.11.7 h1:LIwYxASDLGUg/8wOhgOOZhX8tQa/9tgZPgzZoVqJvcs=
|
||||
go.mongodb.org/mongo-driver v1.11.7/go.mod h1:G9TgswdsWjX4tmDA5zfs2+6AEPpYJwqblyjsfuh8oXY=
|
||||
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=
|
||||
|
||||
@@ -17,16 +17,14 @@
|
||||
package actions
|
||||
|
||||
import (
|
||||
"time"
|
||||
|
||||
"github.com/openziti/fablab/kernel/lib/actions"
|
||||
"github.com/openziti/fablab/kernel/lib/actions/component"
|
||||
"github.com/openziti/fablab/kernel/lib/actions/host"
|
||||
"github.com/openziti/fablab/kernel/lib/actions/semaphore"
|
||||
"github.com/openziti/fablab/kernel/model"
|
||||
zitilib_actions "github.com/openziti/ziti/zititest/zitilab/actions"
|
||||
"github.com/openziti/ziti/zititest/zitilab/actions/edge"
|
||||
"github.com/openziti/ziti/zititest/zitilab/models"
|
||||
"time"
|
||||
)
|
||||
|
||||
type bootstrapAction struct{}
|
||||
@@ -43,7 +41,7 @@ func (a *bootstrapAction) bind(m *model.Model) model.Action {
|
||||
workflow.AddAction(component.Stop("#ctrl"))
|
||||
workflow.AddAction(edge.InitController("#ctrl"))
|
||||
workflow.AddAction(component.Start("#ctrl"))
|
||||
workflow.AddAction(semaphore.Sleep(2 * time.Second))
|
||||
workflow.AddAction(edge.ControllerAvailable("#ctrl", 30*time.Second))
|
||||
|
||||
workflow.AddAction(edge.Login("#ctrl"))
|
||||
|
||||
|
||||
@@ -19,6 +19,7 @@ package actions
|
||||
import (
|
||||
"fmt"
|
||||
"github.com/openziti/fablab/kernel/lib"
|
||||
"github.com/openziti/ziti/zititest/zitilab/actions/edge"
|
||||
"time"
|
||||
|
||||
"github.com/openziti/fablab/kernel/lib/actions"
|
||||
@@ -41,7 +42,7 @@ func NewStartAction(metricbeat MetricbeatConfig, consul ConsulConfig) model.Acti
|
||||
func (a *startAction) bind(m *model.Model) model.Action {
|
||||
workflow := actions.Workflow()
|
||||
workflow.AddAction(component.Start("#ctrl"))
|
||||
workflow.AddAction(semaphore.Sleep(2 * time.Second))
|
||||
workflow.AddAction(edge.ControllerAvailable("#ctrl", 30*time.Second))
|
||||
workflow.AddAction(component.StartInParallel(models.EdgeRouterTag, 25))
|
||||
|
||||
workflow.AddAction(semaphore.Sleep(2 * time.Second))
|
||||
|
||||
@@ -19,6 +19,7 @@ package simple
|
||||
import (
|
||||
"embed"
|
||||
"fmt"
|
||||
"github.com/michaelquigley/pfxlog"
|
||||
"github.com/openziti/fablab/kernel/lib/actions/component"
|
||||
"github.com/openziti/fablab/kernel/lib/binding"
|
||||
"github.com/openziti/fablab/kernel/lib/runlevel/0_infrastructure/aws_ssh_key"
|
||||
@@ -55,11 +56,18 @@ func getConfigData(filePath string) []byte {
|
||||
return data
|
||||
}
|
||||
|
||||
func getUniqueId() string {
|
||||
if runId := os.Getenv("GITHUB_RUN_ID"); runId != "" {
|
||||
return "-" + runId + "." + os.Getenv("GITHUB_RUN_ATTEMPT")
|
||||
}
|
||||
return "-" + os.Getenv("USER")
|
||||
}
|
||||
|
||||
var Model = &model.Model{
|
||||
Id: "simple-transfer",
|
||||
Scope: model.Scope{
|
||||
Defaults: model.Variables{
|
||||
"environment": "simple-transfer-smoketest",
|
||||
"environment": "simple-transfer-smoketest" + getUniqueId(),
|
||||
"credentials": model.Variables{
|
||||
"ssh": model.Variables{
|
||||
"username": "ubuntu",
|
||||
@@ -74,6 +82,7 @@ var Model = &model.Model{
|
||||
|
||||
Factories: []model.Factory{
|
||||
model.FactoryFunc(func(m *model.Model) error {
|
||||
pfxlog.Logger().Infof("environment [%s]", m.MustStringVariable("environment"))
|
||||
m.AddActivationActions("stop", "bootstrap", "start")
|
||||
m.AddOperatingStage(runlevel_5_operation.AssertEcho("#echo-client"))
|
||||
|
||||
|
||||
@@ -45,10 +45,14 @@ const (
|
||||
)
|
||||
|
||||
func TestCurlFiles(t *testing.T) {
|
||||
allZetHostedFailed := true
|
||||
for _, hostType := range []string{"ert", "zet", "ziti-tunnel"} {
|
||||
for _, clientType := range []string{"ert", "zet", "ziti-tunnel"} {
|
||||
for _, encrypted := range []bool{true, false} {
|
||||
testFileDownload(t, clientType, ClientCurl, hostType, encrypted, "1KB")
|
||||
success := testFileDownload(t, clientType, ClientCurl, hostType, encrypted, "1KB")
|
||||
if hostType == "zet" && success {
|
||||
allZetHostedFailed = false
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -58,7 +62,10 @@ func TestCurlFiles(t *testing.T) {
|
||||
for _, hostType := range []string{"ert", "zet"} {
|
||||
for _, client := range []httpClient{ClientCurl, ClientWget} {
|
||||
for _, encrypted := range []bool{true, false} {
|
||||
testFileDownload(t, clientType, client, hostType, encrypted, size)
|
||||
success := testFileDownload(t, clientType, client, hostType, encrypted, size)
|
||||
if hostType == "zet" && success {
|
||||
allZetHostedFailed = false
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -66,14 +73,19 @@ func TestCurlFiles(t *testing.T) {
|
||||
}
|
||||
|
||||
testFileDownload(t, "ziti-tunnel", ClientCurl, "ziti-tunnel", true, "20MB")
|
||||
|
||||
req := require.New(t)
|
||||
req.False(allZetHostedFailed, "all zet hosted file transfer should not failed, indicates bigger issue")
|
||||
}
|
||||
|
||||
func testFileDownload(t *testing.T, hostSelector string, client httpClient, hostType string, encrypted bool, fileSize string) {
|
||||
func testFileDownload(t *testing.T, hostSelector string, client httpClient, hostType string, encrypted bool, fileSize string) bool {
|
||||
encDesk := "encrypted"
|
||||
if !encrypted {
|
||||
encDesk = "unencrypted"
|
||||
}
|
||||
|
||||
success := false
|
||||
|
||||
t.Run(fmt.Sprintf("%v-(%s->%s)-%s-%v", client, hostSelector, hostType, fileSize, encDesk), func(t *testing.T) {
|
||||
host, err := model.GetModel().SelectHost("." + hostSelector + "-client")
|
||||
req := require.New(t)
|
||||
@@ -96,7 +108,13 @@ func testFileDownload(t *testing.T, hostSelector string, client httpClient, host
|
||||
|
||||
timeout := timeouts[fileSize]
|
||||
o, err := lib.RemoteExecAllWithTimeout(sshConfigFactory, timeout, cmd)
|
||||
if hostType == "zet" && err != nil {
|
||||
t.Skipf("zet hosted file transfer failed [%v]", err.Error())
|
||||
return
|
||||
}
|
||||
req.NoError(err)
|
||||
req.Equal(hashes[fileSize], o[0:32])
|
||||
success = true
|
||||
})
|
||||
return success
|
||||
}
|
||||
|
||||
@@ -0,0 +1,30 @@
|
||||
package edge
|
||||
|
||||
import (
|
||||
"github.com/openziti/fablab/kernel/model"
|
||||
"github.com/openziti/foundation/v2/netz"
|
||||
"github.com/pkg/errors"
|
||||
"time"
|
||||
)
|
||||
|
||||
func ControllerAvailable(componentSpec string, timeout time.Duration) model.Action {
|
||||
return &edgeAvailable{
|
||||
componentSpec: componentSpec,
|
||||
timeout: timeout,
|
||||
}
|
||||
}
|
||||
|
||||
func (self *edgeAvailable) Execute(m *model.Model) error {
|
||||
for _, c := range m.SelectComponents(self.componentSpec) {
|
||||
if err := netz.WaitForPortActive(c.Host.PublicIp+":1280", self.timeout); err != nil {
|
||||
return errors.Wrap(err, "controller didn't start in time")
|
||||
}
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
type edgeAvailable struct {
|
||||
componentSpec string
|
||||
timeout time.Duration
|
||||
}
|
||||
@@ -1,11 +1,11 @@
|
||||
package edge
|
||||
|
||||
import (
|
||||
"errors"
|
||||
"fmt"
|
||||
"github.com/openziti/fablab/kernel/lib"
|
||||
"github.com/openziti/fablab/kernel/lib/actions/host"
|
||||
"github.com/openziti/fablab/kernel/model"
|
||||
"github.com/pkg/errors"
|
||||
)
|
||||
|
||||
func InitController(componentSpec string) model.Action {
|
||||
|
||||
Reference in New Issue
Block a user