nixbot

builds

succeeded container-test-run-github-agent-authd checks.x86_64-linux.nixosTests.github-agent-authd.x86_64-linux · build #155 · raw

1[0.00s] Machine state will be reset. To keep it, pass --keep-machine-state2[0.00s] start all VLans3[0.01s] (finished: start all VLans, in 0.00 seconds)4Initializing machine ID from random generator.5[0.08s] Test will time out and terminate in 300.0 seconds6[0.08s] run the VM test script7additionally exposed symbols:8 machine,9 vlan1,10 start_all, test_script, machines, machines_qemu, machines_nspawn, vlans, driver, log, os, create_machine, subtest, run_tests, join_all, retry, serial_stdout_off, serial_stdout_on, polling_condition, BaseMachine, QemuMachine, NspawnMachine, t, debug, dump_machine_ssh11[0.08s] machine: systemd-nspawn running (pid 50)12[0.08s] machine: Waiting for journal at /build/vm-state-machine/var/log/journal...13[0.08s] machine: waiting for unit multi-user.target14nixos-nspawn(machine): TAP vde-tap1 not found; container will be isolated from VDE15nixos-nspawn(machine): A common reason for this is that /dev/net is not available in the Nix sandbox. Try adding /dev/net to extra-sandbox-paths.16Note: in a future version of systemd-nspawn the default set of permitted socket address families will be restricted to AF_INET, AF_INET6 and AF_UNIX. Use --restrict-address-families= to configure the set of permitted socket address families, or set RestrictAddressFamilies= in a .nspawn file.17░ Spawning container machine on /build/vm-state-machine.18machine # No journal files were found.19machine # No journal boot entry found for the specified boot (+0).20machine # [769868.902399] machine systemd-journald[58]: Journal started21machine # [769868.902477] machine systemd-journald[58]: Runtime Journal (/run/log/journal/edb98268ce6444268f63bb8b799ff874) is 8M, max 1.2G, 1.2G free.22machine # [769868.933688] machine systemd[1]: Listening on Journal Log Access Socket.23machine # [769868.934174] machine systemd[1]: Finished Apply Kernel Variables.24machine # [769868.962273] machine systemd[1]: Finished Create Static Device Nodes in /dev gracefully.25machine # [769868.988638] machine systemd[1]: Starting Flush Journal to Persistent Storage...26machine # [769869.001207] machine systemd[1]: Starting Create Static Device Nodes in /dev...27machine # [769869.010095] machine systemd-journald[58]: Time spent on flushing to /var/log/journal/edb98268ce6444268f63bb8b799ff874 is 5.205ms for 7 entries.28machine # [769869.010095] machine systemd-journald[58]: System Journal (/var/log/journal/edb98268ce6444268f63bb8b799ff874) is 8M, max 4G, 3.9G free.29machine # [769869.038245] machine systemd[1]: Finished Flush Journal to Persistent Storage.30machine # [769869.038761] machine systemd[1]: Finished Create Static Device Nodes in /dev.31machine # [769869.039980] machine systemd[1]: Reached target Preparation for Local File Systems.32machine # [769869.040499] machine systemd[1]: Rule-based Manager for Device Events and Files skipped, unmet condition check ConditionPathIsReadWrite=/sys33machine # [769869.180451] machine systemd[1]: Finished Firewall.34machine # [769869.903297] machine systemd[1]: Mounting /run/wrappers...35machine # [769869.944540] machine systemd[1]: Mounted /run/wrappers.36machine # [769869.945285] machine systemd[1]: Reached target Local File Systems.37machine # [769869.946333] machine systemd[1]: Listening on Boot Loader Control Service Socket.38machine # [769869.954604] machine systemd[1]: Starting Create SUID/SGID Wrappers...39machine # [769869.954749] machine systemd[1]: Update Boot Loader Random Seed skipped, unmet condition check ConditionVirtualization=!container40machine # [769869.957429] machine systemd[1]: Starting Save Transient machine-id to Disk...41machine # [769869.959146] machine systemd[1]: Starting Create System Files and Directories...42machine # [769869.987591] machine systemd-tmpfiles[164]: Cannot set file attributes for '/var/empty', value=0x00000010, mask=0x00000010, ignoring: Operation not permitted43machine # [769869.987861] machine systemd-tmpfiles[164]: fchmod() of /var/log/journal failed: Operation not permitted44machine # [769869.988043] machine systemd-tmpfiles[164]: fchmod() of /var/log/journal/edb98268ce6444268f63bb8b799ff874 failed: Operation not permitted45machine # [769869.988354] machine systemd-tmpfiles[164]: fchmod() of /run/log/journal failed: Operation not permitted46machine # [769869.997287] machine systemd[1]: Finished Create System Files and Directories.47machine # [769870.005797] machine suid-sgid-wrappers-start[171]: chmod: changing permissions of '/run/wrappers/wrappers.jrQhh9Zh6k/chsh': Operation not permitted48machine # [769870.027964] machine systemd[1]: suid-sgid-wrappers.service: Main process exited, code=exited, status=1/FAILURE49machine # [769870.028166] machine systemd[1]: suid-sgid-wrappers.service: Failed to read pids.max for control group /system.slice/suid-sgid-wrappers.service, ignoring: No data available50machine # [769870.028311] machine systemd[1]: suid-sgid-wrappers.service: Failed to read pids.max for control group /system.slice/suid-sgid-wrappers.service, ignoring: No data available51machine # [769870.028417] machine systemd[1]: suid-sgid-wrappers.service: Failed with result 'exit-code'.52machine # [769870.028687] machine systemd[1]: Failed to start Create SUID/SGID Wrappers.53machine # [769870.032141] machine systemd[1]: Starting Rebuild Journal Catalog...54machine # [769870.034497] machine systemd[1]: Starting Record System Boot/Shutdown in UTMP...55machine # [769870.073708] machine systemd[1]: Finished Record System Boot/Shutdown in UTMP.56machine # [769870.085044] machine systemd[1]: Finished Rebuild Journal Catalog.57machine # [769870.088476] machine systemd[1]: Starting Update is Completed...58machine # [769870.111331] machine systemd[1]: Finished Update is Completed.59machine # [769870.111672] machine systemd[1]: Reached target System Initialization.60machine # [769870.111836] machine systemd[1]: Discard unused filesystem blocks once a week skipped, unmet condition check ConditionVirtualization=!container61machine # [769870.111926] machine systemd[1]: Started Daily Cleanup of Temporary Directories.62machine # [769870.111999] machine systemd[1]: Reached target Timer Units.63machine # [769870.115320] machine systemd[1]: Listening on D-Bus System Message Bus Socket.64machine # [769870.116518] machine systemd[1]: Starting GitHub agent auth broker socket...65machine # [769870.116827] machine systemd[1]: Listening on Nix Daemon Socket.66machine # [769870.119251] machine systemd[1]: Listening on OpenSSH Server Socket (systemd-ssh-generator, AF_UNIX Export).67machine # [769870.120365] machine systemd[1]: Listening on OpenSSH Server Socket (systemd-ssh-generator, AF_UNIX Local).68machine # [769870.121792] machine systemd[1]: Listening on SSH Socket.69machine # [769870.122127] machine systemd[1]: Listening on Virtual Machine and Container Registration Service Socket.70machine # [769870.128161] machine systemd[1]: Listening on GitHub agent auth broker socket.71machine # [769870.128253] machine systemd[1]: Reached target Socket Units.72machine # [769870.128318] machine systemd[1]: Reached target Basic System.73machine # [769870.131622] machine systemd[1]: Starting Import lastlog data into lastlog2 database...74machine # [769870.136559] machine systemd[1]: Starting Name Service Cache Daemon (nsncd)...75machine # [769870.140062] machine systemd[1]: Starting resolvconf update...76machine # [769870.140228] machine systemd[1]: SSH Host Keys Generation skipped, no trigger condition checks were met.77machine # [769870.177075] machine systemd[1]: Finished Import lastlog data into lastlog2 database.78machine # [769870.256567] machine systemd[1]: nscd.service: Failed to read pids.max for control group /system.slice/nscd.service, ignoring: No data available79machine # [769870.256743] machine systemd[1]: nscd.service: Deactivated successfully.80machine # [769870.264960] machine systemd[1]: Stopped Name Service Cache Daemon (nsncd).81machine # [769870.272486] machine systemd[1]: Starting Name Service Cache Daemon (nsncd)...82machine # [769870.276353] machine resolvconf-start[238]: setfacl: /run/resolvconf: Operation not supported83machine # [769870.281435] machine systemd[1]: resolvconf.service: Main process exited, code=exited, status=1/FAILURE84machine # [769870.281509] machine systemd[1]: resolvconf.service: Failed to read pids.max for control group /system.slice/resolvconf.service, ignoring: No data available85machine # [769870.281582] machine systemd[1]: resolvconf.service: Failed to read pids.max for control group /system.slice/resolvconf.service, ignoring: No data available86machine # [769870.281622] machine systemd[1]: resolvconf.service: Failed with result 'exit-code'.87machine # [769870.281805] machine systemd[1]: Failed to start resolvconf update.88machine # [769870.282448] machine systemd[1]: Reached target Preparation for Network.89machine # [769870.287429] machine systemd[1]: Starting Address configuration of eth1...90machine # [769870.294034] machine systemd[1]: Starting Extra networking commands....91machine # [769870.320832] machine network-addresses-eth1-start[241]: adding address 192.168.1.1/24... done92machine # [769870.330836] machine network-addresses-eth1-start[241]: adding address 2001:db8:1::1/64... done93machine # [769870.334657] machine systemd[1]: Finished Address configuration of eth1.94machine # [769870.402392] machine systemd[1]: Finished Extra networking commands..95machine # [769870.402552] machine systemd[1]: Reached target Network.96machine # [769870.404119] machine systemd[1]: Started Fake GitHub API for github-agent-authd test.97machine # [769870.559346] machine systemd[1]: Started Name Service Cache Daemon (nsncd).98machine # [769870.559429] machine systemd[1]: Reached target Host and Network Name Lookups.99machine # [769870.559495] machine systemd[1]: Reached target User and Group Name Lookups.100machine # [769870.560233] machine nsncd[237]: Nov 09 03:41:42.371 INFO started, config: Config { ignored_request_types: {}, worker_count: 8, handoff_timeout: 10s }, path: "/var/run/nscd/socket"101machine # [769870.562664] machine systemd[1]: Starting User Login Management...102machine # [769870.566301] machine systemd[1]: Starting Permit User Sessions...103machine # [769870.590165] machine systemd[1]: Finished Permit User Sessions.104machine # [769870.594558] machine systemd[1]: Started Console Getty.105machine # [769870.594617] machine systemd[1]: Getty on tty1 skipped, unmet condition check ConditionPathExists=/dev/tty0106machine # [769870.594640] machine systemd[1]: Reached target Login Prompts.107machine # [769871.441558] machine systemd[1]: etc-machine\x2did.mount: Deactivated successfully.108machine # [769871.443319] machine systemd[1]: Finished Save Transient machine-id to Disk.109machine # [769872.613435] machine systemd-logind[303]: New seat seat0.110machine # [769872.621280] machine systemd[1]: Starting D-Bus System Message Bus...111machine # [769872.622683] machine systemd[1]: Started User Login Management.112machine # [769872.624634] machine systemd[1]: Starting linger-users.service...113machine # [769872.646283] machine systemd[1]: linger-users.service: Failed to read pids.max for control group /system.slice/linger-users.service, ignoring: No data available114machine # [769872.646349] machine systemd[1]: linger-users.service: Failed to read pids.max for control group /system.slice/linger-users.service, ignoring: No data available115machine # [769872.646390] machine systemd[1]: linger-users.service: Deactivated successfully.116machine # [769872.646815] machine systemd[1]: Finished linger-users.service.117machine # [769872.647170] machine systemd[1]: Reached target Multi-User System.118[5.78s] machine: (finished: waiting for unit multi-user.target, in 5.70 seconds)119[5.78s] machine: waiting for unit fake-github-api.service120[5.82s] machine: (finished: waiting for unit fake-github-api.service, in 0.04 seconds)121[5.82s] machine: waiting for unit github-agent-authd.socket122[5.86s] machine: (finished: waiting for unit github-agent-authd.socket, in 0.04 seconds)123[5.86s] machine: waiting for file '/run/github-agent-authd/socket'124[5.87s] machine: (finished: waiting for file '/run/github-agent-authd/socket', in 0.01 seconds)125[5.87s] machine: must fail: systemctl is-active github-agent-authd.service126[5.89s] machine: (finished: must fail: systemctl is-active github-agent-authd.service, in 0.02 seconds)127Test 1: socket access denied for non-member user...128[5.89s] machine: must fail: runuser -u blocked -- curl --unix-socket /run/github-agent-authd/socket -fsS http://localhost/healthz129machine # [769873.301605] machine dbus-broker-launch[321]: Looking up NSS user entry for 'systemd-timesync'...130machine # [769873.306984] machine dbus-broker-launch[321]: NSS returned no entry for 'systemd-timesync'131machine # [769873.307173] machine dbus-broker-launch[321]: Invalid user-name in /nix/store/hsm2jhqrj2lkzr7dnjqqgbr4g850vjkr-system-path/share/dbus-1/system.d/org.freedesktop.timesync1.conf +16: user="systemd-timesync"132machine # [769873.310166] machine systemd[1]: Started D-Bus System Message Bus.133machine # [769873.310728] machine systemd[1]: Startup finished in 4.944s.134machine # [769873.332019] machine dbus-broker-launch[321]: Ready135machine # [769873.580724] machine runuser[331]: pam_unix(runuser:session): session opened for user blocked(uid=1000) by (uid=0)136curl: (7) Failed to connect to localhost:80 over unix:///run/github-agent-authd/socket after 0 ms: Could not connect to server137[5.93s] machine: (finished: must fail: runuser -u blocked -- curl --unix-socket /run/github-agent-authd/socket -fsS http://localhost/healthz, in 0.04 seconds)138✓ Test 1 passed139Test 2: health check via authorized user...140[5.93s] machine: must succeed: runuser -u testuser -- curl --unix-socket /run/github-agent-authd/socket -fsS http://localhost/healthz141machine # [769873.602751] machine runuser[331]: pam_unix(runuser:session): session closed for user blocked142machine # [769873.616037] machine runuser[333]: pam_unix(runuser:session): session opened for user testuser(uid=1001) by (uid=0)143machine # [769873.632849] machine systemd[1]: Reached target Network is Online.144machine # [769873.649347] machine systemd[1]: Starting GitHub agent auth broker...145[7.66s] machine: (finished: must succeed: runuser -u testuser -- curl --unix-socket /run/github-agent-authd/socket -fsS http://localhost/healthz, in 1.73 seconds)146[7.66s] machine: waiting for unit github-agent-authd.service147[7.68s] machine: (finished: waiting for unit github-agent-authd.service, in 0.02 seconds)148✓ Test 2 passed149Test 3: token retrieval and cache reuse...150[7.68s] machine: must succeed: runuser -u testuser -- github-agent-token --repo test/repo151[7.71s] machine: (finished: must succeed: runuser -u testuser -- github-agent-token --repo test/repo, in 0.04 seconds)152[7.71s] machine: must succeed: runuser -u testuser -- github-agent-token --repo test/repo153[7.75s] machine: (finished: must succeed: runuser -u testuser -- github-agent-token --repo test/repo, in 0.04 seconds)154[7.75s] machine: must succeed: cat /tmp/fake-gh-install-repo155[7.76s] machine: (finished: must succeed: cat /tmp/fake-gh-install-repo, in 0.01 seconds)156[7.76s] machine: must succeed: cat /tmp/fake-gh-token-mints157[7.77s] machine: (finished: must succeed: cat /tmp/fake-gh-token-mints, in 0.01 seconds)158✓ Test 3 passed159Test 4: git credential helper returns app credentials...160[7.77s] machine: must succeed: runuser -u testuser -- bash -lc "printf 'protocol=https\nhost=github.com\npath=test/repo.git\n\n' | github-agent-git-credential-helper get"161[7.82s] machine: (finished: must succeed: runuser -u testuser -- bash -lc "printf 'protocol=https\nhost=github.com\npath=test/repo.git\n\n' | github-agent-git-credential-helper get", in 0.05 seconds)162✓ Test 4 passed163Test 5: github-agent-gh injects token and execs gh...164[7.82s] machine: must succeed: runuser -u testuser -- bash -lc 'cd /tmp && mkdir gh-test && cd gh-test && git init -q && git remote add origin https://github.com/test/repo.git'165[7.85s] machine: (finished: must succeed: runuser -u testuser -- bash -lc 'cd /tmp && mkdir gh-test && cd gh-test && git init -q && git remote add origin https://github.com/test/repo.git', in 0.03 seconds)166[7.85s] machine: must succeed: runuser -u testuser -- bash -lc 'cd /tmp/gh-test && gh help >/dev/null'167machine # [769875.329581] machine systemd[1]: Started GitHub agent auth broker.168machine # [769875.332211] machine github-agent-authd[335]: github-agent-authd: ready idle_shutdown_timeout=30m0s169machine # [769875.333728] machine runuser[333]: pam_unix(runuser:session): session closed for user testuser170machine # [769875.365505] machine runuser[341]: pam_unix(runuser:session): session opened for user testuser(uid=1001) by (uid=0)171machine # [769875.385290] machine github-agent-authd[335]: repo=test/repo installation_id=101 cache_outcome=miss latency_ms=6172machine # [769875.391021] machine runuser[341]: pam_unix(runuser:session): session closed for user testuser173machine # [769875.400679] machine runuser[348]: pam_unix(runuser:session): session opened for user testuser(uid=1001) by (uid=0)174machine # [769875.417795] machine github-agent-authd[335]: repo=test/repo installation_id=101 cache_outcome=positive_hit latency_ms=0175machine # [769875.423966] machine runuser[348]: pam_unix(runuser:session): session closed for user testuser176machine # [769875.457576] machine runuser[355]: pam_unix(runuser:session): session opened for user testuser(uid=1001) by (uid=0)177machine # [769875.487017] machine github-agent-authd[335]: repo=test/repo installation_id=101 cache_outcome=positive_hit latency_ms=0178machine # [769875.492063] machine runuser[355]: pam_unix(runuser:session): session closed for user testuser179machine # [769875.507547] machine runuser[365]: pam_unix(runuser:session): session opened for user testuser(uid=1001) by (uid=0)180machine # [769875.522383] machine runuser[365]: pam_unix(runuser:session): session closed for user testuser181machine # [769875.529487] machine runuser[369]: pam_unix(runuser:session): session opened for user testuser(uid=1001) by (uid=0)182machine # [769875.560728] machine github-agent-authd[335]: repo=test/repo installation_id=101 cache_outcome=positive_hit latency_ms=0183[7.95s] machine: (finished: must succeed: runuser -u testuser -- bash -lc 'cd /tmp/gh-test && gh help >/dev/null', in 0.10 seconds)184[7.95s] machine: must succeed: cat /tmp/fake-gh-token-mints185[7.95s] machine: (finished: must succeed: cat /tmp/fake-gh-token-mints, in 0.01 seconds)186✓ Test 5 passed187Test 6: helper cleanly misses unknown repo for git fallback...188[7.95s] machine: must succeed: runuser -u testuser -- bash -lc "printf 'protocol=https\nhost=github.com\npath=test/missing.git\n\n' | github-agent-git-credential-helper get"189[8.00s] machine: (finished: must succeed: runuser -u testuser -- bash -lc "printf 'protocol=https\nhost=github.com\npath=test/missing.git\n\n' | github-agent-git-credential-helper get", in 0.04 seconds)190✓ Test 6 passed191Test 7: missing repo uses negative cache...192[8.00s] machine: must succeed: runuser -u testuser -- bash -lc "github-agent-token --repo test/missing >/dev/null 2>&1; echo \$?"193[8.03s] machine: (finished: must succeed: runuser -u testuser -- bash -lc "github-agent-token --repo test/missing >/dev/null 2>&1; echo \$?", in 0.04 seconds)194[8.03s] machine: must succeed: runuser -u testuser -- bash -lc "github-agent-token --repo test/missing >/dev/null 2>&1; echo \$?"195[8.07s] machine: (finished: must succeed: runuser -u testuser -- bash -lc "github-agent-token --repo test/missing >/dev/null 2>&1; echo \$?", in 0.04 seconds)196[8.07s] machine: must succeed: cat /tmp/fake-gh-install-missing197[8.08s] machine: (finished: must succeed: cat /tmp/fake-gh-install-missing, in 0.01 seconds)198✓ Test 7 passed199✅ All tests passed!200[8.08s] (finished: run the VM test script, in 8.00 seconds)201machine # [769875.621163] machine runuser[369]: pam_unix(runuser:session): session closed for user testuser202machine # [769875.638714] machine runuser[393]: pam_unix(runuser:session): session opened for user testuser(uid=1001) by (uid=0)203machine # [769875.662086] machine github-agent-authd[335]: repo=test/missing latency_ms=2 kind=unknown_installation err="unknown repo/installation: test/missing"204machine # [769875.672970] machine runuser[393]: pam_unix(runuser:session): session closed for user testuser205machine # [769875.682098] machine runuser[407]: pam_unix(runuser:session): session opened for user testuser(uid=1001) by (uid=0)206machine # [769875.700861] machine github-agent-authd[335]: repo=test/missing latency_ms=0 kind=unknown_installation err="unknown repo/installation: test/missing"207machine # [769875.710958] machine runuser[407]: pam_unix(runuser:session): session closed for user testuser208machine # [769875.719698] machine runuser[415]: pam_unix(runuser:session): session opened for user testuser(uid=1001) by (uid=0)209machine # [769875.737092] machine github-agent-authd[335]: repo=test/missing latency_ms=0 kind=unknown_installation err="unknown repo/installation: test/missing"210machine # [769875.747187] machine runuser[415]: pam_unix(runuser:session): session closed for user testuser211[8.99s] test script finished in 8.91s212[8.99s] cleanup213[8.99s] kill NspawnMachine (pid 50)214Container machine terminated by signal KILL.215[9.11s] (finished: cleanup, in 0.12 seconds)