Skip to main content

Stop services from starting

Project description

Some Debian package installs automatically launch a daemon, and sometimes you don’t want that to happen immediately. stopstartup, when activated, will stop any service started via invoke-rc.d from starting. It does this by hijacking /usr/sbin/policy-rc.d, which invoke-rc.d calls for every service. Normally the file should determine if your currently active “policy” (whatever that means) should allow the service to startup. The policy enforcer installed by stopstartup is much less nice, and simply rejects any request.

The policy is installed at usr/sbin/, so if you don’t have proper permissions there you’ll be unable to run stopstartup. If that happens, try using sudo.

Installing

stopstartup can be installed in these ways:

# Install right from Github
pip install git+https://github.com/wemash/stopstartup

# Install from a local copy of the repo
# This is super handy if you want to work on stopstartup
git clone https://github.com/wemash/stopstartup
cd stopstartup
pip install --editable .

# RECOMMENDED: Install through pip
pip install stopstartup

Ensuring that this actually works

A full test suite exists in tests. The tests rely on pytest and pytest-pythonpath. Install those first, then just run py.test. The tests should never create, move, or delete any tests on your real filesystem; if you write new tests, please use in_isolation_do to ensure that your tests are run in a temporary part of the FS that will be automatically removed at the completion of the test.

Contributing

Fork this repo and send me a pull request. It’s all rather informal.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

stopstartup-1.0.2.tar.gz (3.6 kB view details)

Uploaded Source

File details

Details for the file stopstartup-1.0.2.tar.gz.

File metadata

  • Download URL: stopstartup-1.0.2.tar.gz
  • Upload date:
  • Size: 3.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for stopstartup-1.0.2.tar.gz
Algorithm Hash digest
SHA256 128049e108127c5c24bc438d5f6f6479d58d0deed66714ed5ea44fcb54514bc8
MD5 463c2a56fb28753cc66dfbbe399eee6b
BLAKE2b-256 10436d6cd26d86f59082c2ef39763922629574b2274a7b4de6cd11004f103dd4

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page