Fix linting
This commit is contained in:
parent
52802f754b
commit
a9bd241663
1
.github/dependabot.yml
vendored
1
.github/dependabot.yml
vendored
@ -1,3 +1,4 @@
|
|||||||
|
---
|
||||||
# To get started with Dependabot version updates, you'll need to specify which
|
# To get started with Dependabot version updates, you'll need to specify which
|
||||||
# package ecosystems to update and where the package manifests are located.
|
# package ecosystems to update and where the package manifests are located.
|
||||||
# Please see the documentation for all configuration options:
|
# Please see the documentation for all configuration options:
|
||||||
|
4
.github/workflows/docker.yml
vendored
4
.github/workflows/docker.yml
vendored
@ -1,3 +1,4 @@
|
|||||||
|
---
|
||||||
# This workflow uses actions that are not certified by GitHub.
|
# This workflow uses actions that are not certified by GitHub.
|
||||||
# They are provided by a third-party and are governed by
|
# They are provided by a third-party and are governed by
|
||||||
# separate terms of service, privacy policy, and support
|
# separate terms of service, privacy policy, and support
|
||||||
@ -5,7 +6,8 @@
|
|||||||
|
|
||||||
# GitHub recommends pinning actions to a commit SHA.
|
# GitHub recommends pinning actions to a commit SHA.
|
||||||
# To get a newer version, you will need to update the SHA.
|
# To get a newer version, you will need to update the SHA.
|
||||||
# You can also reference a tag or branch, but the action may change without warning.
|
# You can also reference a tag or branch,
|
||||||
|
# but the action may change without warning.
|
||||||
|
|
||||||
name: Create and publish a Docker image
|
name: Create and publish a Docker image
|
||||||
|
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
FROM python:3.8-alpine
|
FROM python:3.8-alpine
|
||||||
RUN mkdir /app
|
RUN mkdir -p /{app,config}
|
||||||
RUN mkdir /config
|
COPY . /app
|
||||||
ADD . /app
|
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
CMD ["python", "app.py"]
|
CMD ["python", "app.py"]
|
||||||
HEALTHCHECK CMD test -f /config/servers.json || exit 1
|
HEALTHCHECK CMD test -f /config/servers.json || exit 1
|
@ -4,7 +4,10 @@ import time
|
|||||||
|
|
||||||
with open('/config/servers.json', 'w') as f:
|
with open('/config/servers.json', 'w') as f:
|
||||||
print("created " + f.name)
|
print("created " + f.name)
|
||||||
template_string = '{"Servers": {"1": {"Name": "DavinciResolve", "Group": "Servers", "Port": 5432, "Username": "postgres", "Host": "postgres", "SSLMode": "prefer", "MaintenanceDB": "postgres"}}}'
|
template_string = ('{"Servers": {"1": {"Name": "DavinciResolve", '
|
||||||
|
'"Group": "Servers", "Port": 5432, "Username": ''
|
||||||
|
'"postgres", "Host": "postgres", "SSLMode": "prefer", "MaintenanceDB": "postgres"}}}'
|
||||||
|
)
|
||||||
data = json.loads(template_string)
|
data = json.loads(template_string)
|
||||||
data["Servers"]["1"]["Username"] = os.getenv("POSTGRES_USER")
|
data["Servers"]["1"]["Username"] = os.getenv("POSTGRES_USER")
|
||||||
print("printing json to file...")
|
print("printing json to file...")
|
||||||
@ -12,4 +15,3 @@ with open('/config/servers.json', 'w') as f:
|
|||||||
json.dump(data, f, indent=2)
|
json.dump(data, f, indent=2)
|
||||||
# sleep until GHA Healthchecks are complete
|
# sleep until GHA Healthchecks are complete
|
||||||
time.sleep(125)
|
time.sleep(125)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user