Skip to content

Commit 7ac1e83

Browse files
authored
Merge pull request #553 from mbaldessari/leaks2
Improve the gitleaks configuration
2 parents c011d59 + 2b9e2b8 commit 7ac1e83

File tree

5 files changed

+53
-7
lines changed

5 files changed

+53
-7
lines changed

.github/linters/.gitleaks.toml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
[allowlist]
2+
paths = [
3+
'''.*\.html$''',
4+
'''content\/patterns\/ansible-edge-gitops-kasten\/ideas-for-customization\.md''',
5+
]
6+
7+
regexes = [
8+
# Ignore lines containing these
9+
'''oc login''',
10+
'''sha256~AUv_4DGQoFMVzmdO3cg3v4vnUuaV3lYcy6N2SCwVOz4''',
11+
]

.github/workflows/superlinter.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
---
2+
name: Super linter
3+
4+
on: [push, pull_request]
5+
6+
jobs:
7+
build:
8+
# Name the Job
9+
name: Super linter
10+
# Set the agent to run on
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- name: Checkout Code
15+
uses: actions/checkout@v4
16+
with:
17+
# Full git history is needed to get a proper list of changed files within `super-linter`
18+
fetch-depth: 0
19+
20+
################################
21+
# Run Linter against code base #
22+
################################
23+
- name: Lint Code Base
24+
uses: super-linter/super-linter/slim@v7
25+
env:
26+
VALIDATE_ALL_CODEBASE: true
27+
DEFAULT_BRANCH: main
28+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
29+
# These are the validation we disable atm
30+
VALIDATE_GITLEAKS: true

.gitleaks.toml

Lines changed: 0 additions & 6 deletions
This file was deleted.

.gitleaks.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
.github/linters/.gitleaks.toml

Makefile

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,3 +70,13 @@ lintwordlist: ## Sorts and removes duplicates from spellcheck exception file .wo
7070
.PHONY: clean
7171
clean: ## Removes any unneeded spurious files
7272
@rm -rvf ./.jekyll-cache ./_site ./tmp super-linter.log dictionary.dic public/*
73+
74+
.PHONY: super-linter
75+
super-linter: ## Runs super linter locally
76+
rm -rf .mypy_cache
77+
podman run -e RUN_LOCAL=true -e USE_FIND_ALGORITHM=true \
78+
-e VALIDATE_GITLEAKS=true \
79+
$(DISABLE_LINTERS) \
80+
-v $(PWD):/tmp/lint:rw,z \
81+
-w /tmp/lint \
82+
ghcr.io/super-linter/super-linter:slim-v7

modules/mcg-deploying-mcg-pattern.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@ $ cd /path/to/your/repository
249249
+
250250
[source,terminal]
251251
----
252-
$ oc login --token=sha256~AUv_4DGQoFMVzmdO3cg3v4vnUuaV3lYcy6N2SCwVOz4 --server=https://api.<your-cluster>.<domain>:6443
252+
$ oc login --token=<retrieved-token> --server=https://api.<your-cluster>.<domain>:6443
253253
----
254254

255255
. Alternatively log in by running the following command:

0 commit comments

Comments
 (0)