Skip to content

Commit

Permalink
fixed linting pt.2
Browse files Browse the repository at this point in the history
  • Loading branch information
AntFMoJ committed Apr 16, 2024
1 parent 1ddf08c commit 1dbbe95
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
1 change: 1 addition & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
# checkov:skip=CKV_DOCKER_2:Healthcheck instructions have not been added to container images
# checkov:skip=CKV_DOCKER_3:"Ensure that a user for the container has been created"
# hadolint global ignore=DL3008

ARG r=4.3.2
Expand Down
12 changes: 9 additions & 3 deletions gather_env_vars.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
import os # pylint: disable=missing-module-docstring
"""Module for writing RENV files out."""

import os

R_ENV_FILE_NAME = "/srv/shiny-server/.Renviron"
R_ENV_FILE_NAME1 = "/home/shiny/.Renviron"
Expand All @@ -8,12 +10,16 @@ def gather_env_vars_to_renv_file():
"""
Writes RENV files out.
"""
with open(R_ENV_FILE_NAME, "a") as file_handler: # pylint: disable=unspecified-encoding
with open(
R_ENV_FILE_NAME, "a"
) as file_handler: # pylint: disable=unspecified-encoding
for name, value in os.environ.items():
file_handler.write(f'{name}="{value}"')
file_handler.write("\n")

with open(R_ENV_FILE_NAME1, "a") as file_handler: # pylint: disable=unspecified-encoding
with open(
R_ENV_FILE_NAME1, "a"
) as file_handler: # pylint: disable=unspecified-encoding
for name, value in os.environ.items():
file_handler.write(f'{name}="{value}"')
file_handler.write("\n")
Expand Down

0 comments on commit 1dbbe95

Please sign in to comment.