Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
86 commits
Select commit Hold shift + click to select a range
cb4ff4c
Create README.md
helping-kaiser Jul 10, 2025
ee39fd2
First code poush tarraform to accss OTC
gogeekness Jul 10, 2025
0529cde
Adding more varables
gogeekness Jul 16, 2025
5b96daa
debugging
gogeekness Jul 16, 2025
1496a7c
more debugging, remove double vars
gogeekness Jul 16, 2025
8cb4330
debug providers
gogeekness Jul 16, 2025
597ff7b
Another big update, using older API provider for OTC, need better out…
gogeekness Jul 16, 2025
3f159f2
Anotehr major rebuild of code, v3.
gogeekness Jul 16, 2025
57f3349
Addiing a discovery script to find the needed settings.
gogeekness Jul 16, 2025
5fe5032
debugging version adn teh providers
gogeekness Jul 16, 2025
8d59b12
debugging OTC instances
gogeekness Jul 16, 2025
1383bc9
adding provider.tf
gogeekness Jul 16, 2025
5f73056
cleaning up provider
gogeekness Jul 16, 2025
1bdbd55
upload and remove files
gogeekness Jul 17, 2025
73fb187
update and fixing TF for OTC
gogeekness Jul 24, 2025
f535e16
Update main.tf fixing some definitions
gogeekness Jul 28, 2025
ee9989e
Revamp of scripts, added Python, and I am getting data from OTC
gogeekness Jul 28, 2025
b75196d
impimenting, and moving files into a new location
gogeekness Jul 29, 2025
0dff217
New files for Grafana and Loki
Aug 6, 2025
27a1fa2
updating proxy server settings
Aug 6, 2025
41ca11a
more chagnes for proxy
Aug 6, 2025
4b442f5
More files and a working alloy config
Aug 7, 2025
67b22ca
Move terraform code to it's onw directory.
Aug 11, 2025
860d21f
Working to access OTC by TF
Aug 12, 2025
28e1547
More update for TF info
Aug 12, 2025
9adcc8f
setup output of the inventory
Aug 12, 2025
fbf297e
basic testing to access OTC
Aug 12, 2025
cbebcdd
update for OTC pull inventory
Aug 12, 2025
ff232a0
update for VCP-IDs
Aug 12, 2025
b7c5faa
removing any AK auth from TF
Aug 12, 2025
09f0455
Using python to pull account information for Terraform
Aug 12, 2025
c5a4c81
Need env var filled to work.
Aug 13, 2025
827991d
update provider
Aug 13, 2025
3efa87f
update provider and secrets file and update gitignore
Aug 13, 2025
c0cb3ad
A susscessfull fetch
Aug 13, 2025
a512e91
update to output in yaml
Aug 13, 2025
45e045d
moved to ymal output
Aug 13, 2025
eae5971
Update working data. Building a hiarchy
Aug 13, 2025
f4476e3
Big changes with TF files, frying to get a proper hiachry
Aug 14, 2025
5a6c2db
more updates of TF
Aug 14, 2025
5722c62
Moved initory.tf to TF root dir.
Aug 14, 2025
0a6dbb4
Don't need cluster information.
Aug 14, 2025
7560be8
update for
Aug 18, 2025
c08cecc
RMS is set and working. Now to test.
Aug 18, 2025
20fbd92
update local for terraform
Aug 18, 2025
434d0df
Push for pre-try
Aug 18, 2025
21a75a8
New revamp for OTC pull.
Aug 18, 2025
f6a5b06
bUG FIS FOR load Banacers
Aug 18, 2025
6b08e3f
One last try to use RMS code, The plugin breaks on RMS
Aug 19, 2025
c272c1c
It work, mostly, the RMS is disabled as it crashes the plugin.
Aug 19, 2025
f2201cb
Recieved data, working with VPC main branches.
Aug 19, 2025
9babe82
Minor change for the output file.
Aug 19, 2025
c419fd3
minor fix for output file.
Aug 19, 2025
3b252d6
set to good, working file
Aug 19, 2025
c189a7e
Minor changes to test and observe.
Aug 20, 2025
e4aa0c2
Alloy config for the test-backend
Aug 25, 2025
6e1b92e
update terraform, adn gitignore
Aug 26, 2025
909c11f
update alloy
Aug 26, 2025
d3f0122
update to slow donw teh data sent to loki
Aug 26, 2025
58a83df
update on TF
Aug 28, 2025
c073cf4
Globals update
Sep 17, 2025
21ff274
update with additional new platform with promox
Sep 29, 2025
3cb8841
Adding scripts to proxmox
Sep 30, 2025
7e41478
update create3
Sep 30, 2025
7e294e0
typo
Sep 30, 2025
0e63363
typo 2
Sep 30, 2025
289b2d0
added qcow2 image
Sep 30, 2025
51e47c1
OVERHAUL for disk resize
Sep 30, 2025
890f1b4
Adding OVH openstack settings
Oct 7, 2025
629100b
a change on globals
Oct 7, 2025
ce6e942
more updates for golabals
Oct 7, 2025
0a12221
more changes for globals
Oct 8, 2025
579009f
update for netplan with ipv6 address
Oct 8, 2025
092c950
update globals with bridges
Oct 8, 2025
f648963
adding cinder config
Oct 10, 2025
7c5e2fe
update proxmox init code
Oct 11, 2025
423bd98
proofed setup script
Oct 11, 2025
b41b03a
added network script
Oct 13, 2025
7d4fe7d
ignored gitleaks report json
WisdomNwaiwu Oct 13, 2025
8265c58
gitleaks conf
WisdomNwaiwu Oct 13, 2025
ce51aa3
readme to explain gitleaks
WisdomNwaiwu Oct 13, 2025
a0bba11
script to set up gitleaks pre commit hook
WisdomNwaiwu Oct 13, 2025
62bafb2
pre commit file
WisdomNwaiwu Oct 13, 2025
22955f2
gitleaks workflow file
WisdomNwaiwu Oct 13, 2025
5cb7617
Merge pull request #4 from peer-network/wisdom/fix/gitleaks
gogeekness Oct 13, 2025
06f2fe4
Merge branch 'Dev' into dev-1
gogeekness Dec 22, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
48 changes: 48 additions & 0 deletions .githooks/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
#!/bin/sh
echo "Running Gitleaks pre-commit scan on staged changes (Server Settings)..."

mkdir -p .gitleaks_out
touch .gitleaks_out/gitleaks-precommit.json

# Prefer local gitleaks if available, fallback to Docker
if command -v gitleaks >/dev/null 2>&1; then
echo "⚡ Using local gitleaks binary"
SCAN_CMD="gitleaks detect \
--pipe \
--config=gitleaks.toml \
--report-format=json \
--report-path=.gitleaks_out/gitleaks-precommit.json \
--no-banner"
else
echo "Local gitleaks not found, using Docker fallback"
SCAN_CMD="docker run --rm -i -v \"$(pwd)\":/repo ghcr.io/gitleaks/gitleaks:v8.28.0 detect \
--pipe \
--config=/repo/gitleaks.toml \
--report-format=json \
--report-path=/repo/.gitleaks_out/gitleaks-precommit.json \
--no-banner"
fi

# Run scan on staged diff only
git diff --cached --unified=0 --no-color \
| grep '^+' \
| grep -v '^+++' \
| sh -c "$SCAN_CMD"
status=$?
if [ $status -ne 0 ]; then
echo "Possible secrets detected in staged changes!"
echo " See .gitleaks_out/gitleaks-precommit.json for details."
echo ""
echo "Commit aborted."
echo ""
echo "Reminder: Do NOT bypass with 'git commit --no-verify'."
echo "CI will still block your PR even if you bypass locally."
echo ""
echo "If this secret is actually required in the repo (false positive or approved usage),"
echo "you MUST meet with the CTO / Team Lead / DevOps to approve"
echo "and add it to the gitleaks ignore list."
exit 1
fi

echo "No secrets found. Commit allowed."
exit 0
18 changes: 18 additions & 0 deletions .github/workflows/security.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: Security Scan

on:
pull_request:
branches:
- Dev
- dev-1
push:
branches:
- Dev
- dev-1

jobs:
gitleaks:
name: Run Gitleaks Scan
uses: peer-network/peer_global_security/.github/workflows/gitleaks.yml@main
with:
config: gitleaks.toml
7 changes: 7 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
secrets.tfvars
secrets.auto.tfvars
clouds.yaml
*.tfstate
peer_network.yaml
terraform.tfstate*
.gitleaks_out/
55 changes: 55 additions & 0 deletions Loki-Grafana/alloy-config-monitor.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
server:
log_level: info

clients:
- url: http://80.158.41.189/loki/api/v1/push

positions:
filename: /tmp/positions.yaml

scrape_configs:
- job_name: system-logs
static_configs:
- targets: [localhost]
labels:
job: "syslog"
host: "monitoring-server"
__path__: /var/log/syslog

- job_name: auth-logs
static_configs:
- targets: [localhost]
labels:
job: "auth"
host: "monitoring-server"
__path__: /var/log/auth.log

- job_name: cron-monitor-logs
static_configs:
- targets: [localhost]
labels:
job: "auth"
host: "monitoring-server"
__path__: /var/log/postman_logs/cron.log

- job_name: crom-mintbot-var-logs
static_configs:
- targets: [localhost]
labels:
job: "auth"
host: "monitoring-server"
__path__: /var/log/mintlog/mint.log

- job_name: mintbot-logs
static_configs:
- targets: [localhost]
labels:
job: gem_monitor
component: stdout
__path__: /home/ubuntu/mintbot/logs/mint_*/*.txt

- targets: [localhost]
labels:
job: gem_monitor
component: nested_logs
__path__: /home/ubuntu/mintbot/logs/mint_*/**/*.log
27 changes: 27 additions & 0 deletions Loki-Grafana/config.alloy
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
// Sample config for Alloy.
//
// For a full configuration reference, see https://grafana.com/docs/alloy
logging {
level = "warn"
}

prometheus.exporter.unix "default" {
include_exporter_metrics = true
disable_collectors = ["mdadm"]
}

prometheus.scrape "default" {
targets = array.concat(
prometheus.exporter.unix.default.targets,
[{
// Self-collect metrics
job = "alloy",
__address__ = "127.0.0.1:12345",
}],
)

forward_to = [
// TODO: components to forward metrics to (like prometheus.remote_write or
// prometheus.relabel).
]
}
93 changes: 93 additions & 0 deletions Loki-Grafana/config.monitor.alloy
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
// Beta_Testing Monitor config file for Alloy (Grafana)
// Enable logging
logging {
level = "debug"
format = "logfmt"
}

// Loki client (Writer)
loki.write "default" {
endpoint {
url = "http://10.50.1.150:3100/loki/api/v1/push"
}
}

// System syslog file (simplified for testing)
loki.source.file "syslog" {
targets = [
{
"__path__" = "/var/log/syslog",
job = "syslog",
},
]
forward_to = [loki.write.default.receiver]
}

// Auth logs
loki.source.file "auth" {
targets = [
{
"__path__" = "/var/log/auth.log",
job = "auth",
host = "monitoring-server",
},
]
forward_to = [loki.write.default.receiver]
}

// JournalD logs
loki.source.journal "systemd" {
labels = {
job = "systemd",
host = "monitoring-server",
}
forward_to = [loki.write.default.receiver]
}

// Postman cron logs
loki.source.file "cron_monitor" {
targets = [
{
"__path__" = "/var/log/postman_logs/cron.log",
job = "cron-monitor",
host = "monitoring-server",
},
]
forward_to = [loki.write.default.receiver]
}

// Mintbot log in var log
loki.source.file "crom_mintbot_var_logs" {
targets = [
{
"__path__" = "/var/log/mintlog/mint.log",
job = "gem_mintbot",
host = "monitoring-server",
},
]
forward_to = [loki.write.default.receiver]
}

// Mintbot flat logs
loki.source.file "mintbot_txt" {
targets = [
{
"__path__" = "/home/ubuntu/mintbot/logs/mint_*/*.txt",
job = "gem_monitor",
component = "stdout",
},
]
forward_to = [loki.write.default.receiver]
}

// Mintbot nested logs
loki.source.file "mintbot_nested_logs" {
targets = [
{
"__path__" = "/home/ubuntu/mintbot/logs/mint_*/**/*.log",
job = "gem_monitor",
component = "nested_logs",
},
]
forward_to = [loki.write.default.receiver]
}
Loading
Loading