diff --git a/.github/workflows/build_and_test.yml b/.github/workflows/build_and_test.yml index 55f74fc..d835831 100644 --- a/.github/workflows/build_and_test.yml +++ b/.github/workflows/build_and_test.yml @@ -14,8 +14,8 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 with: python-version: '3.12' diff --git a/.github/workflows/python-publish.yml b/.github/workflows/python-publish.yml index 1fc024f..1859535 100644 --- a/.github/workflows/python-publish.yml +++ b/.github/workflows/python-publish.yml @@ -13,9 +13,9 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: Set up Python - uses: actions/setup-python@v2 + uses: actions/setup-python@v5 with: python-version: '3.12' - name: Install dependencies diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 59d2105..ecc38eb 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,7 +1,7 @@ exclude: (^.idea/) repos: - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v3.2.0 + rev: v4.6.0 hooks: - id: end-of-file-fixer types: [ python ] diff --git a/pre-commit.Dockerfile b/pre-commit.Dockerfile index c22dc22..4467323 100644 --- a/pre-commit.Dockerfile +++ b/pre-commit.Dockerfile @@ -4,11 +4,10 @@ RUN apt-get update && \ apt-get install -y git && \ pip install pipenv -COPY ${project_root}/Pipfile* ./ +COPY Pipfile* ./ -RUN pipenv lock --dev && \ - pipenv sync --dev --system --verbose +RUN pipenv sync --dev --system --extra-pip-args="--prefer-binary" WORKDIR /sourcecode RUN git config --global --add safe.directory /sourcecode -CMD pre-commit run --all-files +CMD ["pre-commit", "run", "--all-files"] diff --git a/spark.Dockerfile b/spark.Dockerfile index cfc5a8d..f499b58 100644 --- a/spark.Dockerfile +++ b/spark.Dockerfile @@ -29,5 +29,10 @@ RUN mkdir -p /.local/share/virtualenvs && chmod 777 /.local/share/virtualenvs # USER 1001 # Run as non-root user +# Change ownership of the directory and its subdirectories +RUN chown -R 185:185 /sam + +# Set permissions to allow writing (read, write, execute for owner) +RUN chmod -R 755 /sam # https://spark.apache.org/docs/latest/running-on-kubernetes.html#user-identity USER 185