runner
runner copied to clipboard
Support for pre-services setup steps
The services capability is an elegant way to automate the setup and tear down of a service, but there are use-cases where preparation tasks need to occur in a hook before services are started.
Possible examples include:
- Adjusting system parameters (e.g. file descriptor limits, socket buffer sizes, etc)
- Creating filesystem resources shared/used by containers
- Configuring ACLs
- Configuring network adapters and ip filters
- Installing packages
See https://github.com/actions/virtual-environments/issues/348 for an example use case of a workaround (although note, it will be solved by other means)
One form this could take would be something like:
runs-on: ubuntu-latest
setup-steps:
- name: Stop Mysql
shell: bash
run: |
sudo service mysql stop || true
services:
# services
steps:
# post-services steps