Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Add build arg for skipping identity wrapper #624

Merged
merged 1 commit into from
Aug 17, 2020

Conversation

kleimkuhler
Copy link
Contributor

Motivation

The proxy identity-initializing wrapper is responsible for generating a CSR and
key for the proxy upon startup. These files (located in end-entity/) are used
by the proxy for establishing identity.

When mocking identity, we'd like to be able to provide a pre-generated CSR and
key so that we can expect certain certificates in the Signed certificate
request.

Therefore, when building a proxy to be used with mock identity there should be a
way to remove this wrapper so that the identity files are not overwritten.

Solution

Introduce a new SKIP_IDENTITY_WRAPPER build-arg that when set, removes the
proxy identity-initializing script that is run at starup.

The use of it below will build a proxy with the mock-orig-dst feature and skip
identity generation.

:; docker buildx build . --build-arg PROXY_FEATURES=mock-orig-dst --build-arg SKIP_IDENTITY_WRAPPER=1 --load --tag=kevinlbuoyant/l2-proxy:proxy-identity-v1

I have confirmed this works with the changes in olix0r/l2-proxy-harness#2.

Signed-off-by: Kevin Leimkuhler kevin@kleimkuhler.com

Signed-off-by: Kevin Leimkuhler <kevin@kleimkuhler.com>
@kleimkuhler kleimkuhler requested a review from a team August 13, 2020 18:54
Copy link
Member

@olix0r olix0r left a comment

Choose a reason for hiding this comment

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

sweet ;)

@kleimkuhler kleimkuhler requested a review from hawkw August 17, 2020 21:07
@kleimkuhler kleimkuhler merged commit 8a085d5 into main Aug 17, 2020
@kleimkuhler kleimkuhler deleted the kleimkuhler/proxy-identity-wrapper branch August 17, 2020 22:41
olix0r pushed a commit to olix0r/l2-proxy-harness that referenced this pull request Aug 18, 2020
Identity can now be enabled in bechmarks using the CSR, key, and signed
certificate generated by `gen-certs.sh`.

By default, this creates the
`foo.ns1.serviceaccount.identity.linkerd.cluster.local` identity and it's files
are located in `identity/`.

This must be run with with a proxy built from the changes introduced by
linkerd/linkerd2-proxy#624. You can use
`kevinlbuoyant/l2-proxy:proxy-identity-v1` until that merges in `main`.

With identity being enabled by default, running the high concurrency tests is
done with:

```
env PROXY_IMAGE=kevinlbuoyant/l2-proxy:proxy-identity-v1 ./high-concurrency
```

Identity can be disabled by setting the `PROXY_IDENTITY_DISABLED` env variable:

```
env PROXY_IMAGE=kevinlbuoyant/l2-proxy:proxy-identity-v1 PROXY_IDENTITY_DISABLED=1 ./high-concurrency
```

If you make changes to the identity created by `gen-certs.sh`, you can specify
the identity that the single proxy for use with the `PROXY_IDENTITY_LOCAL_NAME`
env variable.

Signed-off-by: Kevin Leimkuhler <kevin@kleimkuhler.com>
olix0r added a commit to linkerd/linkerd2 that referenced this pull request Aug 26, 2020
This release includes internal changes to the service discovery system,
especially when discovering control plane components (like the
destination and identity controllers). Now, the proxy attempts to
balance requests across all pods in each control plane service. This
requires control plane changes to use "headless" services so that SRV
records are exposed. When the control plane services have a `clusterIP`
set, the proxy falls back to using normal A-record lookups.

---

* tracing: add richer verbose spans to http clients (linkerd/linkerd2-proxy#622)
* trace: update tracing dependencies (linkerd/linkerd2-proxy#623)
* Remove `Resolution` trait (linkerd/linkerd2-proxy#606)
* Update proxy-identity to edge-20.8.2 (linkerd/linkerd2-proxy#627)
* Add build arg for skipping identity wrapper (linkerd/linkerd2-proxy#624)
* Wait for proxy thread to terminate in integration tests (linkerd/linkerd2-proxy#625)
* Remove scrubbing for unused headers (linkerd/linkerd2-proxy#628)
* Split orig-proto tests out of discovery tests (linkerd/linkerd2-proxy#629)
* Re-enable outbound timeout test (linkerd/linkerd2-proxy#630)
* profiles: perform profile resolution for IP addresses (linkerd/linkerd2-proxy#626)
* Move resolve api to async-stream (linkerd/linkerd2-proxy#599)
* Decouple discovery buffering from endpoint conversion (linkerd/linkerd2-proxy#631)
* resolve: Add a Reset state (linkerd/linkerd2-proxy#633)
* resolve: Eagerly fail resolutions (linkerd/linkerd2-proxy#634)
* test: replace `net2` dependency with `socket2` (linkerd/linkerd2-proxy#635)
* dns: Run DNS resolutions on the main runtime (linkerd/linkerd2-proxy#637)
* Load balance requests to the control plane (linkerd/linkerd2-proxy#594)
* Unify control plane client construction (linkerd/linkerd2-proxy#638)
olix0r added a commit to linkerd/linkerd2 that referenced this pull request Aug 26, 2020
This release includes internal changes to the service discovery system,
especially when discovering control plane components (like the
destination and identity controllers). Now, the proxy attempts to
balance requests across all pods in each control plane service. This
requires control plane changes to use "headless" services so that SRV
records are exposed. When the control plane services have a `clusterIP`
set, the proxy falls back to using normal A-record lookups.

---

* tracing: add richer verbose spans to http clients (linkerd/linkerd2-proxy#622)
* trace: update tracing dependencies (linkerd/linkerd2-proxy#623)
* Remove `Resolution` trait (linkerd/linkerd2-proxy#606)
* Update proxy-identity to edge-20.8.2 (linkerd/linkerd2-proxy#627)
* Add build arg for skipping identity wrapper (linkerd/linkerd2-proxy#624)
* Wait for proxy thread to terminate in integration tests (linkerd/linkerd2-proxy#625)
* Remove scrubbing for unused headers (linkerd/linkerd2-proxy#628)
* Split orig-proto tests out of discovery tests (linkerd/linkerd2-proxy#629)
* Re-enable outbound timeout test (linkerd/linkerd2-proxy#630)
* profiles: perform profile resolution for IP addresses (linkerd/linkerd2-proxy#626)
* Move resolve api to async-stream (linkerd/linkerd2-proxy#599)
* Decouple discovery buffering from endpoint conversion (linkerd/linkerd2-proxy#631)
* resolve: Add a Reset state (linkerd/linkerd2-proxy#633)
* resolve: Eagerly fail resolutions (linkerd/linkerd2-proxy#634)
* test: replace `net2` dependency with `socket2` (linkerd/linkerd2-proxy#635)
* dns: Run DNS resolutions on the main runtime (linkerd/linkerd2-proxy#637)
* Load balance requests to the control plane (linkerd/linkerd2-proxy#594)
* Unify control plane client construction (linkerd/linkerd2-proxy#638)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants