Skip to content

Commit 83a17d7

Browse files
authored
Merge branch 'finos:main' into main
2 parents 4e01fa1 + 9f7a2ea commit 83a17d7

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

56 files changed

+14550
-2119
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ jobs:
4747
npm run test-coverage-ci --workspaces --if-present
4848
4949
- name: Upload test coverage report
50-
uses: codecov/codecov-action@v4.6.0
50+
uses: codecov/codecov-action@v5.1.2
5151
with:
5252
files: ./coverage/lcov.info
5353
token: ${{ secrets.CODECOV_TOKEN }}
Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
name: CI - experimental - inventory
2+
3+
on:
4+
push:
5+
branches: [main]
6+
paths:
7+
- experimental/license-inventory/**
8+
pull_request:
9+
branches: [main]
10+
paths:
11+
- experimental/license-inventory/**
12+
13+
permissions:
14+
pull-requests: write
15+
16+
jobs:
17+
build:
18+
runs-on: ubuntu-latest
19+
20+
strategy:
21+
matrix:
22+
node-version: [18.x]
23+
mongodb-version: [4.4]
24+
25+
steps:
26+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
27+
with:
28+
fetch-depth: 0
29+
30+
- name: Use Node.js ${{ matrix.node-version }}
31+
uses: actions/setup-node@v4
32+
with:
33+
node-version: ${{ matrix.node-version }}
34+
35+
- name: Start MongoDB
36+
uses: supercharge/[email protected]
37+
with:
38+
mongodb-version: ${{ matrix.mongodb-version }}
39+
40+
- name: Install dependencies
41+
working-directory: ./experimental/license-inventory
42+
run: npm ci
43+
44+
- name: Test
45+
working-directory: ./experimental/license-inventory
46+
run: |
47+
MONGO_URI="mongodb://localhost:27017/inventory" npm run test
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: experimental-inventory - Publish to NPM
2+
on:
3+
push:
4+
tags:
5+
- 'license-inventory-*'
6+
jobs:
7+
build:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
11+
12+
# Setup .npmrc file to publish to npm
13+
- uses: actions/setup-node@v4
14+
with:
15+
node-version: '18.x'
16+
registry-url: 'https://registry.npmjs.org'
17+
18+
- run: npm ci
19+
working-directory: ./experimental/license-inventory
20+
21+
- run: npm run build
22+
working-directory: ./experimental/license-inventory
23+
24+
- run: npm publish --access=public
25+
working-directory: ./experimental/license-inventory
26+
env:
27+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
name: Publish samples to NPM
2+
3+
on:
4+
push:
5+
tags:
6+
- 'sample-*'
7+
8+
jobs:
9+
build:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
13+
# Setup .npmrc file to publish to npm
14+
- uses: actions/setup-node@v4
15+
with:
16+
node-version: '18.x'
17+
registry-url: 'https://registry.npmjs.org'
18+
- name: publish sample package
19+
run: npm install --include peer && npm publish --access=public
20+
working-directory: plugins/git-proxy-plugin-samples
21+
env:
22+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

.github/workflows/scorecard.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ jobs:
3232

3333
steps:
3434
- name: Harden Runner
35-
uses: step-security/harden-runner@91182cccc01eb5e619899d80e4e971d6181294a7 # v2.10.1
35+
uses: step-security/harden-runner@c95a14d0e5bab51a9f56296a4eb0e416910cd350 # v2.10.3
3636
with:
3737
egress-policy: audit
3838

@@ -64,14 +64,14 @@ jobs:
6464
# Upload the results as artifacts (optional). Commenting out will disable uploads of run results in SARIF
6565
# format to the repository Actions tab.
6666
- name: "Upload artifact"
67-
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
67+
uses: actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0
6868
with:
6969
name: SARIF file
7070
path: results.sarif
7171
retention-days: 5
7272

7373
# Upload the results to GitHub's code scanning dashboard.
7474
- name: "Upload to code-scanning"
75-
uses: github/codeql-action/upload-sarif@e2b3eafc8d227b0241d48be5f425d47c2d750a13 # v3.26.10
75+
uses: github/codeql-action/upload-sarif@aa578102511db1f4524ed59b8cc2bae4f6e88195 # v3.27.6
7676
with:
7777
sarif_file: results.sarif
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
node_modules
2+
dist
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
<br />
2+
<div align="center">
3+
<a href="https://github.com/finos/git-proxy">
4+
<img src="../../docs/img/logo.png" alt="Logo" height="95">
5+
</a>
6+
7+
<br />
8+
<strong>git-proxy: license-inventory</strong>
9+
<br />
10+
11+
<p align="center">
12+
<strong>experimental</strong> project to provide license data and attach said license data to projects for fueling policy evaluation.
13+
<br />
14+
</p>
15+
16+
<br />
17+
18+
[![FINOS - Incubating](https://cdn.jsdelivr.net/gh/finos/contrib-toolbox@master/images/badge-incubating.svg)](https://community.finos.org/docs/governance/Software-Projects/stages/incubating)
19+
[![NPM](https://img.shields.io/npm/v/@finos/git-proxy-license-inventory?colorA=00C586&colorB=000000)](https://www.npmjs.com/package/@finos/git-proxy-license-inventory)
20+
[![Build](https://img.shields.io/github/actions/workflow/status/finos/git-proxy/experimental-inventory-ci.yml?branch=main&label=CI&logo=github&colorA=00C586&colorB=000000)](https://github.com/finos/git-proxy/actions/workflows/experimental-inventory-ci.yml)
21+
[![git-proxy](https://api.securityscorecards.dev/projects/github.com/finos/git-proxy/badge)](https://api.securityscorecards.dev/projects/github.com/finos/git-proxy)
22+
<br />
23+
[![License](https://img.shields.io/github/license/finos/git-proxy?colorA=00C586&colorB=000000)](https://github.com/finos/git-proxy/blob/main/LICENSE)
24+
[![Slack](https://img.shields.io/badge/_-Chat_on_Slack-000000.svg?logo=slack&colorA=00C586)](https://app.slack.com/client/T01E7QRQH97/C06LXNW0W76)
25+
26+
</div>
27+
<br />
28+
29+
This is an **experimental** project to provide license data and attach said license data to projects for fueling policy evaluation.
30+
31+
Please consider all REST API paths, inputs, and outputs in flux during `v0`. Additionally do not rely import paths to be stable.
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
apiVersion: 1
2+
3+
datasources:
4+
- name: Loki
5+
type: loki
6+
uid: loki
7+
access: proxy
8+
url: http://loki:3100
9+
basicAuth: false
10+
version: 1
11+
editable: false
12+
isDefault: true
13+
14+
- name: Prometheus
15+
type: prometheus
16+
uid: prometheus
17+
access: proxy
18+
orgId: 1
19+
url: http://prometheus:9090
20+
basicAuth: false
21+
isDefault: false
22+
version: 1
23+
editable: false
24+
jsonData:
25+
httpMethod: GET
26+
27+
- name: Tempo
28+
type: tempo
29+
uid: tempo
30+
access: proxy
31+
orgId: 1
32+
url: http://tempo:3200
33+
basicAuth: false
34+
isDefault: false
35+
version: 1
36+
editable: false
37+
jsonData:
38+
tracesToLogsV2:
39+
datasourceUid: loki
40+
filterByTraceID: true
41+
filterBySpanID: true
42+
tracesToMetrics:
43+
datasourceUid: prometheus
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
auth_enabled: false
2+
3+
server:
4+
http_listen_port: 3100
5+
grpc_listen_port: 9096
6+
7+
common:
8+
instance_addr: 127.0.0.1
9+
path_prefix: /tmp/loki
10+
storage:
11+
filesystem:
12+
chunks_directory: /tmp/loki/chunks
13+
rules_directory: /tmp/loki/rules
14+
replication_factor: 1
15+
ring:
16+
kvstore:
17+
store: inmemory
18+
19+
frontend:
20+
max_outstanding_per_tenant: 2048
21+
22+
pattern_ingester:
23+
enabled: true
24+
25+
limits_config:
26+
max_global_streams_per_user: 0
27+
ingestion_rate_mb: 50000
28+
ingestion_burst_size_mb: 50000
29+
volume_enabled: true
30+
31+
query_range:
32+
results_cache:
33+
cache:
34+
embedded_cache:
35+
enabled: true
36+
max_size_mb: 100
37+
38+
schema_config:
39+
configs:
40+
- from: 2020-10-24
41+
store: tsdb
42+
object_store: filesystem
43+
schema: v13
44+
index:
45+
prefix: index_
46+
period: 24h
47+
48+
analytics:
49+
reporting_enabled: false
Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
extensions:
2+
health_check:
3+
pprof:
4+
endpoint: 127.0.0.1:1777
5+
zpages:
6+
endpoint: 127.0.0.1:55679
7+
8+
receivers:
9+
otlp:
10+
protocols:
11+
http:
12+
endpoint: 0.0.0.0:4318
13+
14+
# collect own metrics
15+
prometheus:
16+
config:
17+
scrape_configs:
18+
- job_name: otel-collector
19+
scrape_interval: 10s
20+
static_configs:
21+
- targets:
22+
- 127.0.0.1:8888
23+
24+
exporters:
25+
loki:
26+
endpoint: http://loki:3100/loki/api/v1/push
27+
prometheus:
28+
endpoint: 127.0.0.1:8889
29+
namespace: otel-collector
30+
send_timestamps: true
31+
metric_expiration: 180m
32+
enable_open_metrics: true
33+
add_metric_suffixes: false
34+
resource_to_telemetry_conversion:
35+
enabled: true
36+
otlphttp:
37+
endpoint: http://tempo:4318
38+
39+
processors:
40+
batch:
41+
42+
service:
43+
pipelines:
44+
traces:
45+
receivers: [otlp]
46+
exporters: [otlphttp]
47+
metrics:
48+
receivers: [otlp]
49+
exporters: [prometheus]
50+
logs:
51+
receivers: [otlp]
52+
exporters: [loki]

0 commit comments

Comments
 (0)