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

Proof of concept: iperf3 with access envelope #652

Open
stephen-soltesz opened this issue Feb 22, 2022 · 1 comment
Open

Proof of concept: iperf3 with access envelope #652

stephen-soltesz opened this issue Feb 22, 2022 · 1 comment

Comments

@stephen-soltesz
Copy link
Contributor

This change adds an experimental configuration for iperf3 server behind the access envelope.

See:

@stephen-soltesz
Copy link
Contributor Author

Example configuration from deleted branch.

k8s/daemonsets/experiments/iperf3.jsonnet:

local exp = import '../templates.jsonnet';
local expName = 'iperf3';

exp.Experiment(expName, 6, 'pusher-' + std.extVar('PROJECT_ID'), 'netblock', ['test']) + {
  spec+: {
    template+: {
      metadata+: {
        annotations+: {
          'secret.reloader.stakater.com/reload': 'measurement-lab-org-tls',
        },
      },
      spec+: {
        containers+: [
          {
            args: [
              '-envelope.key=/certs/tls.key',
              '-envelope.cert=/certs/tls.crt',
              '-envelope.listen-address=:443',
              '-envelope.device=net1',
              '-envelope.subject=iperf3',
              '-envelope.machine=$(MLAB_NODE_NAME)',
              '-envelope.verify-key=/verify/jwk_sig_EdDSA_locate_20200409.pub',
              // Maximum timeout for a client to hold the envelope open.
              '-timeout=2m',
            ],
            env: [
              {
                name: 'MLAB_NODE_NAME',
                valueFrom: {
                  fieldRef: {
                    fieldPath: 'spec.nodeName',
                  },
                },
              },
            ],
            image: 'soltesz/access:v0.4',
            name: 'access',
            securityContext: {
              capabilities: {
                add: [
                  'NET_ADMIN',
                ],
              },
            },
            volumeMounts: [
              {
                mountPath: '/certs',
                name: 'measurement-lab-org-tls',
                readOnly: true,
              },
              {
                mountPath: '/verify',
                name: 'locate-verify-keys',
                readOnly: true,
              },
            ],
          },
          {
            # Start the iperf3 server.
            args: [ '-s' ],
            image: 'soltesz/iperf3:v0.0',
            name: expName,
          },
        ],
        volumes+: [
          {
            name: 'measurement-lab-org-tls',
            secret: {
              secretName: 'measurement-lab-org-tls',
            },
          },
          {
            name: 'locate-verify-keys',
            secret: {
              secretName: 'locate-verify-keys',
            },
          },
        ],
      },
    },
  },
}

With a conditional import in system.jsonnet.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant