Skip to content

Commit

Permalink
Merge pull request #109 from bluelotus03/bugfix/dependabot-changes
Browse files Browse the repository at this point in the history
Bugfix/dependabot changes
  • Loading branch information
kshull1 authored Sep 15, 2024
2 parents f554c20 + 4c2b9bf commit 1c6d654
Show file tree
Hide file tree
Showing 6 changed files with 871 additions and 609 deletions.
2 changes: 1 addition & 1 deletion .github/repo_ci-cd/container/Containerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM docker.io/python:3-slim
FROM docker.io/python:3.11-slim
COPY .github/repo_ci-cd/deployment/ /app_deployment
WORKDIR /app_deployment
RUN pip install pipenv && pipenv sync --system
2 changes: 1 addition & 1 deletion .github/repo_ci-cd/deployment/Pipfile
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ black = "*"
pylint = "*"

[requires]
python_version = "3"
python_version = "3.11"
1,392 changes: 827 additions & 565 deletions .github/repo_ci-cd/deployment/Pipfile.lock

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions .github/repo_ci-cd/deployment/csv_to_json.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,10 @@ def main():
'Photo ID': 'object',
}
# csv_df = dd.read_csv(args.csv_input,dtype = data_types).compute()
csv_df = dd.read_csv(urlpath=file_url,dtype = data_types).compute()
csv_df = dd.read_csv(path=file_url,dtype = data_types).compute()
# https://stackoverflow.com/a/49551419
# strips out leading and trailing whitespace for strings
csv_df = csv_df.applymap(lambda x: x.strip() if isinstance(x, str) else x)
csv_df = csv_df.map(lambda x: x.strip() if isinstance(x, str) else x)
print(csv_df.to_json(orient='records', indent=2,))

if __name__ == "__main__":
Expand Down
78 changes: 39 additions & 39 deletions .github/workflows/cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
name: Actions creating the Archive data file (archive_data.json)
runs-on: ubuntu-latest
container:
image: docker.io/python:3-slim
image: docker.io/python:3.11-slim

steps:
- name: Checkout Code
Expand All @@ -27,7 +27,7 @@ jobs:

- uses: actions/setup-python@v3
with:
python-version: "3.x"
python-version: "3.11"
cache: "pipenv"

- name: installing pipenv packages
Expand All @@ -47,7 +47,7 @@ jobs:
runs-on: ubuntu-latest
needs: prod_prep
container:
image: registry.gitlab.com/pages/hugo/hugo_extended:latest
image: registry.gitlab.com/pages/hugo/hugo_extended:0.113.0

steps:
- name: Prep env
Expand Down Expand Up @@ -88,39 +88,39 @@ jobs:
name: algolia-data
path: /tmp/gh-pages/algolia.json

auto_actions:
name: Actions to update Algolia after site's been deployed
runs-on: ubuntu-latest
needs: prod
# https://docs.github.com/en/actions/deployment/targeting-different-environments/using-environments-for-deployment#using-an-environment
environment: production
container:
image: docker.io/python:3-slim

steps:
- name: Checkout Code
uses: actions/checkout@v2

- name: Install pipenv
run: pip install pipenv

- uses: actions/setup-python@v3
with:
python-version: "3.x"
cache: "pipenv"

- name: installing pipenv packages
run: cd .github/repo_ci-cd/deployment/ && pipenv sync

- name: downloading algolia data
uses: actions/download-artifact@v3
with:
name: algolia-data

- name: Update Algolia index
run: cd .github/repo_ci-cd/deployment/ && pipenv run ./algolia.py
# https://docs.github.com/en/actions/security-guides/encrypted-secrets#using-encrypted-secrets-in-a-workflow
env:
ALGOLIA_API_KEY: ${{ secrets.ALGOLIA_API_KEY }}
ALGOLIA_APP_ID: ${{ secrets.ALGOLIA_APP_ID }}
ALGOLIA_INDEX_NAME: ${{ secrets.ALGOLIA_INDEX_NAME }}
# auto_actions:
# name: Actions to update Algolia after site's been deployed
# runs-on: ubuntu-latest
# needs: prod
# # https://docs.github.com/en/actions/deployment/targeting-different-environments/using-environments-for-deployment#using-an-environment
# environment: production
# container:
# image: docker.io/python:3.11-slim

# steps:
# - name: Checkout Code
# uses: actions/checkout@v2

# - name: Install pipenv
# run: pip install pipenv

# - uses: actions/setup-python@v3
# with:
# python-version: "3.11"
# cache: "pipenv"

# - name: installing pipenv packages
# run: cd .github/repo_ci-cd/deployment/ && pipenv sync

# - name: downloading algolia data
# uses: actions/download-artifact@v3
# with:
# name: algolia-data

# - name: Update Algolia index
# run: cd .github/repo_ci-cd/deployment/ && pipenv run ./algolia.py
# # https://docs.github.com/en/actions/security-guides/encrypted-secrets#using-encrypted-secrets-in-a-workflow
# env:
# ALGOLIA_API_KEY: ${{ secrets.ALGOLIA_API_KEY }}
# ALGOLIA_APP_ID: ${{ secrets.ALGOLIA_APP_ID }}
# ALGOLIA_INDEX_NAME: ${{ secrets.ALGOLIA_INDEX_NAME }}
2 changes: 1 addition & 1 deletion layouts/partials/head.html
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@

{{ $options = merge $options (dict "outputStyle" "compressed") }}
{{ $styles = $scss | toCSS $options }}
{{ $styles = slice $main_css $main_scss | resources.Concat "css/bundle.css" }}
{{ $styles = slice $main_css $styles | resources.Concat "css/bundle.css" }}
{{ $styles = slice $main_css $styles | resources.Concat "css/bundle.css" }}
{{ $styles = $styles | minify | fingerprint }}

Expand Down

0 comments on commit 1c6d654

Please sign in to comment.