This commit is contained in:
lpm0073 2022-05-14 12:59:11 -05:00
parent 49f878621b
commit 9499a70b2c
12 changed files with 77 additions and 7 deletions

21
.editorconfig Normal file
View File

@ -0,0 +1,21 @@
root = true
[*]
charset = utf-8
end_of_line = lf
indent_size = 2
indent_style = space
insert_final_newline = true
max_line_length = 80
trim_trailing_whitespace = true
[*.{tf,tfvars}]
indent_size = 2
indent_style = space
[*.md]
max_line_length = 0
trim_trailing_whitespace = false
[COMMIT_EDITMSG]
max_line_length = 0

1
.gitignore vendored
View File

@ -1,4 +1,5 @@
.vscode/
.DS_Store
.*.swp
!.gitignore

36
.pre-commit-config.yaml Normal file
View File

@ -0,0 +1,36 @@
default_language_version:
# default language version for each language
python: python3.8
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.1.0
hooks:
# See https://pre-commit.com/hooks.html for more hooks
#- id: check-added-large-files
- id: check-byte-order-marker
- id: check-case-conflict
- id: check-executables-have-shebangs
- id: check-json
- id: check-shebang-scripts-are-executable
- id: check-merge-conflict
- id: check-symlinks
- id: check-toml
- id: check-xml
- id: destroyed-symlinks
- id: detect-aws-credentials
- id: detect-private-key
- id: end-of-file-fixer
- id: trailing-whitespace
# - id: pretty-format-json
# - id: check-yaml
- repo: https://github.com/gruntwork-io/pre-commit
rev: v0.1.17 # Get the latest from: https://github.com/gruntwork-io/pre-commit/releases
hooks:
- id: terraform-fmt
- id: helmlint
# - id: terraform-validate
# - id: terragrunt-hclfmt
# - id: tflint
# - id: shellcheck
# - id: yapf
# - id: markdown-link-check

View File

@ -111,4 +111,4 @@ This plugin was developed and open sourced to the community thanks to the genero
License
-------
This software is licensed under the terms of the AGPLv3.
This software is licensed under the terms of the AGPLv3.

11
linter.sh Executable file
View File

@ -0,0 +1,11 @@
#!/bin/sh
#------------------------------------------------------------------------------
# written by: mcdaniel
# https://lawrencemcdaniel.com
#
# date: mar-2022
#
# usage: Runs terraform fmt -recursive
#------------------------------------------------------------------------------
pre-commit run --all-files

1
requirements.txt Normal file
View File

@ -0,0 +1 @@
pre-commit

View File

@ -22,4 +22,4 @@ spec:
volumes:
- name: settings
configMap:
name: credentials-settings
name: credentials-settings

View File

@ -1 +1 @@
- {{ CREDENTIALS_HOST }}
- {{ CREDENTIALS_HOST }}

View File

@ -12,4 +12,4 @@ credentials:
networks:
default:
aliases:
- "{{ CREDENTIALS_HOST }}"
- "{{ CREDENTIALS_HOST }}"

View File

@ -4,4 +4,4 @@ credentials-job:
DJANGO_SETTINGS_MODULE: credentials.settings.tutor.production
volumes:
- ../plugins/credentials/apps/credentials/settings:/openedx/credentials/credentials/settings/tutor:ro
depends_on: {{ [("mysql", RUN_MYSQL)]|list_if }}
depends_on: {{ [("mysql", RUN_MYSQL)]|list_if }}

View File

@ -1,2 +1,2 @@
CREDENTIALS_PUBLIC_URL_ROOT = "http://{{ CREDENTIALS_HOST }}:8150"
CREDENTIALS_API_URL = CREDENTIALS_PUBLIC_URL_ROOT + "/api/v2"
CREDENTIALS_API_URL = CREDENTIALS_PUBLIC_URL_ROOT + "/api/v2"

View File

@ -93,4 +93,4 @@ for logger in LOGGING["loggers"].values():
if "local" in logger["handlers"]:
logger["handlers"].remove("local")
{{ patch("credentials-settings-common") }}
{{ patch("credentials-settings-common") }}