Initial project structure
commit
42801e5c6d
|
@ -0,0 +1,6 @@
|
|||
FROM python:3-alpine
|
||||
RUN pip install --no-cache-dir --upgrade pip
|
||||
|
||||
WORKDIR /app
|
||||
COPY src/ ./
|
||||
CMD [ "python", "ddns_update.py" ]
|
|
@ -0,0 +1,8 @@
|
|||
version: "2"
|
||||
|
||||
services:
|
||||
strato-ddns:
|
||||
container_name: strato-ddns
|
||||
build:
|
||||
context: .
|
||||
restart: always
|
|
@ -0,0 +1,15 @@
|
|||
#!/usr/bin/python3
|
||||
|
||||
from time import sleep
|
||||
import logging
|
||||
|
||||
logging.basicConfig(level=logging.DEBUG)
|
||||
log = logging.getLogger("ddns updater")
|
||||
|
||||
if __name__ == "__main__":
|
||||
log.info("starting...")
|
||||
sequence = 1
|
||||
while True:
|
||||
log.debug(f"update sequence {sequence}")
|
||||
sequence += 1
|
||||
sleep(5)
|
Loading…
Reference in New Issue