1
0
Fork 0
mirror of https://code.forgejo.org/forgejo/runner.git synced 2025-10-05 19:30:59 +00:00
forgejo-runner/act/runner
Earl Warren e1e7d0e85a
fix: remove LXC working directory when it completes (#1003)
The working directory was not cleaned up upon completion of a LXC job because rc.stopJobContainer() -> rc.cleanUpJobContainer() -> rc.JobContainer.Remove() was never called for LXC containers.

- stopContainer() and closeContainer() must not call
  rc.stopHostEnvironment(ctx) for LXC containers because
  - it will needlessly be called twice
  - it intercepts the call to
    - rc.stopJobContainer()
    - rc.JobContainer.Close()
- rc.stopHostEnvironment(ctx) must be called in rc.cleanUpJobContainer which is indirectly called by rc.stopJobContainer()
- since rc.JobContainer.Close() is a noop, not calling it for LXC containers had no consequence

Resolves forgejo/runner#442

<!--start release-notes-assistant-->
<!--URL:https://code.forgejo.org/forgejo/runner-->
- bug fixes
  - [PR](https://code.forgejo.org/forgejo/runner/pulls/1003): <!--number 1003 --><!--line 0 --><!--description Zml4OiByZW1vdmUgTFhDIHdvcmtpbmcgZGlyZWN0b3J5IHdoZW4gaXQgY29tcGxldGVz-->fix: remove LXC working directory when it completes<!--description-->
<!--end release-notes-assistant-->

Reviewed-on: https://code.forgejo.org/forgejo/runner/pulls/1003
Reviewed-by: Mathieu Fenniak <mfenniak@noreply.code.forgejo.org>
Co-authored-by: Earl Warren <contact@earl-warren.org>
Co-committed-by: Earl Warren <contact@earl-warren.org>
2025-09-16 19:42:04 +00:00
..
hashfiles [RDNF #11] fix: skipped jobs have no result & fix: favor command-line over files & chore: fix some comments (#143) 2025-06-09 10:25:43 +00:00
mocks fix: send job outputs & job result to Forgejo in sync with each other (#995) 2025-09-14 20:02:43 +00:00
res Add super-linter + fix lint issues (#650) 2021-05-03 09:52:03 -07:00
testdata fix: enforce job.<job-id>.timeout-minutes (#982) 2025-09-11 14:43:26 +00:00
action.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00
action_cache.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00
action_cache_offline_mode.go feat: offline mode for new action cache (#2173) 2025-04-12 14:03:12 +00:00
action_cache_test.go test: prevent data race detection in TestActionCache (#858) 2025-08-15 09:00:50 +00:00
action_composite.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00
action_test.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00
command.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00
command_test.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00
container_mock_test.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00
expression.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00
expression_test.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00
job_executor.go fix: send job outputs & job result to Forgejo in sync with each other (#995) 2025-09-14 20:02:43 +00:00
job_executor_test.go fix: send job outputs & job result to Forgejo in sync with each other (#995) 2025-09-14 20:02:43 +00:00
local_repository_cache.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00
logger.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00
lxc-helpers-lib.sh feat: add support for a trixie based Debian GNU/Linux backend (e.g. trixie-lxc:lxc://debian:trixie) (#997) 2025-09-15 07:26:56 +00:00
lxc-helpers.sh feat: add support for a trixie based Debian GNU/Linux backend (e.g. trixie-lxc:lxc://debian:trixie) (#997) 2025-09-15 07:26:56 +00:00
reusable_workflow.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00
run_context.go fix: remove LXC working directory when it completes (#1003) 2025-09-16 19:42:04 +00:00
run_context_test.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00
runner.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00
runner_test.go fix: enforce job.<job-id>.timeout-minutes (#982) 2025-09-11 14:43:26 +00:00
step.go fix: enforce job.<job-id>.timeout-minutes (#982) 2025-09-11 14:43:26 +00:00
step_action_local.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00
step_action_local_test.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00
step_action_remote.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00
step_action_remote_test.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00
step_docker.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00
step_docker_test.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00
step_factory.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00
step_factory_test.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00
step_run.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00
step_run_test.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00
step_test.go chore: bump version to v11 (#940) 2025-09-05 07:29:38 +00:00