spiegel_podman/pkg/machine/e2e
Paul Holzinger f218f8430a
machine: implement http proxy logic for all providers
Copy all proxy envs into the VM on each start, this allows for updates
without having to recrate the VM. This is implemented via shell script
that is passed via ssh to the VM after it is started.

With that we now use the same logic for all providers the old fw_cfg
logic for qemu has been removed and the WSL code as well which keeps the
behavior the same.

There is a small risk now because we only update the env via ssh that
processes started before will have the old incorrect env but it should
really only effect core system processes which likely do not need them
anyway. The podman system service should not be started at this point
so it should be good enough.

It also fixes the broken behavior with SSL_CERT_FILE/SSL_CERT_DIR which
were updated on each start which is not correct as the files are only
copied with ignition so these should not be updated and just set
statically when the VM was created.

e2e test has been added to ensure the behavior works as expected.

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2024-02-22 11:23:45 +01:00
..
basic_test.go fix podman-remote exec regression with v4.8 2023-11-29 13:22:46 +01:00
config_basic_test.go enable linter for pkg/machine/e2e 2022-07-21 18:04:10 +02:00
config_darwin_test.go Enable machine e2e test for applehv 2023-09-25 15:45:26 -05:00
config_info_test.go enable linter for pkg/machine/e2e 2022-07-21 18:04:10 +02:00
config_init_test.go Fail if vm exists in hyperv already 2024-02-10 14:49:34 -06:00
config_inspect_test.go Fix machine inspect test config 2024-01-11 11:42:54 -05:00
config_linux_test.go Enable machine e2e test for applehv 2023-09-25 15:45:26 -05:00
config_list_test.go enable linter for pkg/machine/e2e 2022-07-21 18:04:10 +02:00
config_os_apply_test.go Introduce podman machine os apply 2023-02-15 14:48:12 -05:00
config_reset_test.go Codespell code 2024-02-19 15:23:56 -05:00
config_rm_test.go Use single persistent ssh key for all machines 2024-01-04 23:47:49 -05:00
config_set_test.go Update machine init/set tests 2023-08-25 11:28:07 -04:00
config_ssh_test.go Fix typos 2023-02-11 18:23:24 +01:00
config_start_test.go Add --quiet and --no-info flags to podman machine start 2022-11-11 16:14:20 -05:00
config_stop_test.go enable linter for pkg/machine/e2e 2022-07-21 18:04:10 +02:00
config_test.go Fix Lint on Windows and enable the job 2024-02-20 08:06:18 -05:00
config_unix_test.go Prune FCOS related code 2024-02-15 21:05:17 -06:00
config_windows_test.go podman machine 5 - hyperv 2024-02-07 09:18:51 -06:00
info_test.go Bump Go module to v5 2024-02-08 09:35:39 -05:00
init_test.go Merge pull request #21735 from jakecorrenti/inspect-conn-vals 2024-02-22 02:36:50 +00:00
init_windows_test.go Fix Lint on Windows and enable the job 2024-02-20 08:06:18 -05:00
inspect_test.go machine: Add ConnectionInfo to MachineConfig 2024-02-20 09:08:11 -05:00
list_test.go Bump Go module to v5 2024-02-08 09:35:39 -05:00
machine_test.go Merge pull request #21666 from n1hility/reenable-wsl-tests 2024-02-17 12:27:52 +00:00
os_test.go update to ginkgo v2 2023-05-02 11:27:35 +02:00
proxy_test.go machine: implement http proxy logic for all providers 2024-02-22 11:23:45 +01:00
pull_test.go Prune FCOS related code 2024-02-15 21:05:17 -06:00
README.md Podman Machine AppleHV CI fixes 2024-02-07 09:19:16 -06:00
reset_test.go Introduce Podman machine reset 2024-02-18 08:43:12 -06:00
rm_test.go Bump Go module to v5 2024-02-08 09:35:39 -05:00
set_test.go machine: machine set only when machine's stopped 2024-02-13 16:50:22 -05:00
ssh_test.go Bump Go module to v5 2024-02-08 09:35:39 -05:00
start_test.go Bump Go module to v5 2024-02-08 09:35:39 -05:00
stop_test.go Automatic code cleanups - JetBrains 2023-11-07 14:05:15 -06:00

Working README for running the machine tests

Note: you must not have any machines defined before running tests

Linux

QEMU

make localmachine

Microsoft Windows

HyperV

  1. Open a powershell as admin
  2. $env:CONTAINERS_MACHINE_PROVIDER="hyperv"
  3. ./winmake localmachine

Note: To run specific test files, add the test files to the end of the winmake command:

./winmake localmachine "basic_test.go start_test.go"

WSL

  1. Open a powershell as a regular user
  2. Build and copy win-sshproxy into bin/
  3. ./winmake localmachine

Note: To run specific test files, add the test files to the end of the winmake command:

./winmake localmachine "basic_test.go start_test.go"

MacOS

Apple Hypervisor

  1. make podman-remote
  2. make localmachine (Add FOCUS_FILE=basic_test.go to only run basic test)