Add instructions for running Healthcheck script to README
This commit is contained in:
parent
da82798565
commit
e8f843ac79
34
README.md
34
README.md
@ -11,4 +11,38 @@ The containers are responsible for hosting the tunnels associated with the follo
|
|||||||
* [Moshferatu.Dev](https://moshferatu.dev/) (this site)
|
* [Moshferatu.Dev](https://moshferatu.dev/) (this site)
|
||||||
* [Moshington](https://moshington.com/)
|
* [Moshington](https://moshington.com/)
|
||||||
|
|
||||||
|
## Running the Healthcheck Script
|
||||||
|
|
||||||
|
Prior to running the script, you must set the following environment variables (example values provided):
|
||||||
|
|
||||||
|
```shell
|
||||||
|
CHECK_INTERVAL=60
|
||||||
|
MOSHFERATU_DEV_URL=https://moshferatu.dev
|
||||||
|
MOSHFERATU_DEV_CONTAINER=moshferatu-dev-tunnel
|
||||||
|
MOSHINGTON_URL=https://moshington.com
|
||||||
|
MOSHINGTON_CONTAINER=moshington-tunnel
|
||||||
|
```
|
||||||
|
|
||||||
|
The healthcheck depends on ```python-dotenv```, so you can create a ```.env``` file and place the variables in there.
|
||||||
|
|
||||||
|
### Docker Container
|
||||||
|
|
||||||
|
The script can be run in a Docker container of its own.
|
||||||
|
|
||||||
|
The necessary [Dockerfile](./Dockerfile) is provided here.
|
||||||
|
|
||||||
|
Just build and run the container like any other, while making sure to set the necessary environment variables as mentioned above.
|
||||||
|
|
||||||
|
### Standalone Script
|
||||||
|
|
||||||
|
Make sure you have the dependencies listed in [requirements.txt](./requirements.txt) installed in addition to Docker.
|
||||||
|
|
||||||
|
Then, run the following command:
|
||||||
|
|
||||||
|
```shell
|
||||||
|
python ./healthcheck.py
|
||||||
|
```
|
||||||
|
|
||||||
|
Again, make sure to set the necessary environment variables before running the script.
|
||||||
|
|
||||||
---
|
---
|
Loading…
Reference in New Issue
Block a user