Skip to content

Commit 02950c5

Browse files
authored
Merge branch 'main' into dependabot/npm_and_yarn/src/Elastic.Documentation.Site/uuid-13.0.0
2 parents 40bde41 + 4eb28f6 commit 02950c5

File tree

186 files changed

+2754
-2881
lines changed

Some content is hidden

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

186 files changed

+2754
-2881
lines changed

.github/copilot-instructions.md

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,7 @@
33
**ALWAYS reference these instructions first and fallback to search or bash commands only when you encounter unexpected information that does not match the info here.**
44

55
Elastic's distributed documentation tooling system built on .NET 9, consisting of:
6-
- **docs-builder**: CLI tool for building single documentation sets
7-
- **docs-assembler**: CLI tool for assembling multiple doc sets
6+
- **docs-builder**: CLI tool for building single documentation sets or assembling or assembling multiple documentation sets
87
- Written in C# and F# with extensive Markdown processing capabilities
98

109
## Working Effectively
@@ -77,10 +76,10 @@ dotnet run --project src/tooling/docs-builder -- serve
7776
dotnet run --project src/tooling/docs-builder -- --help
7877

7978
# Get help for docs-assembler
80-
dotnet run --project src/tooling/docs-assembler -- --help
79+
dotnet run --project src/tooling/docs-builder -- assemble --help
8180

8281
# Validate assembler configuration - takes 15 seconds
83-
dotnet run --project src/tooling/docs-assembler -c release -- navigation validate
82+
dotnet run --project src/tooling/docs-builder -c release -- assembler navigation validate
8483
```
8584

8685
### Local Development Orchestration
@@ -126,7 +125,6 @@ src/
126125
├── Elastic.Markdown/ # Core Markdown processing engine
127126
├── tooling/
128127
│ ├── docs-builder/ # Main CLI application
129-
│ └── docs-assembler/ # Assembly tool
130128
├── Elastic.Documentation.Site/ # Web rendering components (TypeScript/CSS)
131129
└── Elastic.Documentation.Configuration/ # Configuration handling
132130
@@ -142,7 +140,7 @@ config/ # YAML configuration files
142140

143141
### Adding New Features
144142
- **Markdown Extensions**: Add to `src/Elastic.Markdown/Myst/`
145-
- **CLI Commands**: Extend `src/tooling/docs-builder/Cli/` or `docs-assembler/Cli/`
143+
- **CLI Commands**: Extend `src/tooling/docs-builder/Commands/`
146144
- **Web Components**: Add to `src/Elastic.Documentation.Site/`
147145
- **Configuration**: Modify `src/Elastic.Documentation.Configuration/`
148146

.github/updatecli/updatecli.d/versions.yml

Lines changed: 67 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ scms:
88
user: '{{ requiredEnv "GITHUB_ACTOR" }}'
99
username: '{{ requiredEnv "GITHUB_ACTOR" }}'
1010
owner: '{{ .scm.owner }}'
11-
repository: '{{ .scm.repository }}'
11+
repository: docs-builder
1212
token: '{{ requiredEnv "GITHUB_TOKEN" }}'
1313
commitusingapi: true
1414
branch: '{{ .scm.branch }}'
@@ -47,6 +47,45 @@ sources:
4747
versionfilter:
4848
kind: latest
4949

50+
latest-edot-cf-aws-version:
51+
name: Get latest release version for the edot-cf-aws
52+
kind: githubrelease
53+
transformers:
54+
- trimprefix: v
55+
spec:
56+
owner: elastic
57+
repository: edot-cloud-forwarder-aws
58+
token: '{{ requiredEnv "GITHUB_TOKEN" }}'
59+
username: '{{ requiredEnv "GITHUB_ACTOR" }}'
60+
versionfilter:
61+
kind: latest
62+
63+
latest-edot-cf-azure-version:
64+
name: Get latest release version for the edot-cf-azure
65+
kind: githubrelease
66+
transformers:
67+
- trimprefix: v
68+
spec:
69+
owner: elastic
70+
repository: edot-cloud-forwarder-azure
71+
token: '{{ requiredEnv "GITHUB_TOKEN" }}'
72+
username: '{{ requiredEnv "GITHUB_ACTOR" }}'
73+
versionfilter:
74+
kind: latest
75+
76+
# latest-edot-cf-gcp-version:
77+
# name: Get latest release version for the edot-cf-gcp
78+
# kind: githubrelease
79+
# transformers:
80+
# - trimprefix: v
81+
# spec:
82+
# owner: elastic
83+
# repository: edot-cloud-forwarder-gcp
84+
# token: '{{ requiredEnv "GITHUB_TOKEN" }}'
85+
# username: '{{ requiredEnv "GITHUB_ACTOR" }}'
86+
# versionfilter:
87+
# kind: latest
88+
5089
latest-edot-collector-version:
5190
name: Get latest major release version for the elastic-agent
5291
kind: githubrelease
@@ -305,6 +344,33 @@ targets:
305344
file: config/versions.yml
306345
key: versioning_systems.edot-android.current
307346

347+
update-docs-docset-cf-aws:
348+
name: 'Update config/versions.yml edot-cf-aws {{ source "latest-edot-cf-aws-version" }}'
349+
scmid: githubConfig
350+
sourceid: latest-edot-cf-aws-version
351+
kind: yaml
352+
spec:
353+
file: config/versions.yml
354+
key: versioning_systems.edot-cf-aws.current
355+
356+
update-docs-docset-cf-azure:
357+
name: 'Update config/versions.yml edot-cf-azure {{ source "latest-edot-cf-azure-version" }}'
358+
scmid: githubConfig
359+
sourceid: latest-edot-cf-azure-version
360+
kind: yaml
361+
spec:
362+
file: config/versions.yml
363+
key: versioning_systems.edot-cf-azure.current
364+
365+
# update-docs-docset-cf-gcp:
366+
# name: 'Update config/versions.yml edot-cf-gcp {{ source "latest-edot-cf-gcp-version" }}'
367+
# scmid: githubConfig
368+
# sourceid: latest-edot-cf-gcp-version
369+
# kind: yaml
370+
# spec:
371+
# file: config/versions.yml
372+
# key: versioning_systems.edot-cf-gcp.current
373+
308374
update-docs-docset-collector:
309375
name: 'Update config/versions.yml edot-collector {{ source "latest-edot-collector-version" }}'
310376
scmid: githubConfig

.github/updatecli/values.d/scm.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
scm:
22
enabled: true
33
owner: elastic
4-
repository: docs-builder
4+
repositories: |
5+
docs-builder
6+
edot-cloud-forwarder-aws
7+
edot-cloud-forwarder-azure
8+
edot-cloud-forwarder-gcp
59
branch: main

.github/workflows/ci.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,10 @@ jobs:
2727
uses: ./.github/actions/bootstrap
2828

2929
- name: Validate Navigation
30-
run: dotnet run --project src/tooling/docs-assembler -c release -- navigation validate
30+
run: dotnet run --project src/tooling/docs-builder -c release -- assembler navigation validate
3131

3232
- name: Validate Content Sources
33-
run: dotnet run --project src/tooling/docs-assembler -c release -- content-source validate
33+
run: dotnet run --project src/tooling/docs-builder -c release -- assembler content-source validate
3434

3535
build-link-index-updater-lambda:
3636
uses: ./.github/workflows/build-link-index-updater-lambda.yml

.github/workflows/deploy-api-lambda.yml

Lines changed: 50 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -50,19 +50,60 @@ jobs:
5050
role-to-assume: arn:aws:iam::197730964718:role/elastic-docs-v3-api-deployer-${{ inputs.environment }}
5151
aws-region: us-east-1
5252

53-
- name: Upload Lambda function
53+
- name: Upload to S3 and Deploy Lambda Functions
5454
run: |
55-
NEW_VERSION=$(aws lambda update-function-code \
56-
--function-name "elastic-docs-v3-${ENVIRONMENT}-api" \
57-
--zip-file "fileb://${ZIP_FILE}" \
58-
--publish \
55+
# Upload once to S3 with git SHA for traceability
56+
S3_KEY="${ENVIRONMENT}/${GITHUB_SHA}/api-lambda.zip"
57+
aws s3 cp "${ZIP_FILE}" "s3://${S3_BUCKET}/${S3_KEY}"
58+
59+
# Deploy to streaming-optimized Lambda
60+
aws lambda update-function-code \
61+
--function-name "${LAMBDA_STREAM_FUNCTION}" \
62+
--s3-bucket "${S3_BUCKET}" \
63+
--s3-key "${S3_KEY}"
64+
65+
# Deploy to API Gateway-optimized Lambda
66+
aws lambda update-function-code \
67+
--function-name "${LAMBDA_API_GW_FUNCTION}" \
68+
--s3-bucket "${S3_BUCKET}" \
69+
--s3-key "${S3_KEY}"
70+
71+
# Wait for the function update to complete before publishing
72+
aws lambda wait function-updated \
73+
--function-name "${LAMBDA_STREAM_FUNCTION}"
74+
75+
# Wait for the function update to complete before publishing
76+
aws lambda wait function-updated \
77+
--function-name "${LAMBDA_API_GW_FUNCTION}"
78+
79+
STREAM_VERSION=$(aws lambda publish-version \
80+
--function-name "${LAMBDA_STREAM_FUNCTION}" \
81+
--description "Deployed from ${GITHUB_SHA}" \
5982
--query 'Version' \
6083
--output text)
61-
84+
6285
aws lambda update-alias \
63-
--function-name "elastic-docs-v3-${ENVIRONMENT}-api" \
64-
--name live \
65-
--function-version $NEW_VERSION
86+
--function-name "${LAMBDA_STREAM_FUNCTION}" \
87+
--name live \
88+
--function-version $STREAM_VERSION
89+
90+
API_GW_VERSION=$(aws lambda publish-version \
91+
--function-name "${LAMBDA_API_GW_FUNCTION}" \
92+
--description "Deployed from ${GITHUB_SHA}" \
93+
--query 'Version' \
94+
--output text)
95+
96+
aws lambda update-alias \
97+
--function-name "${LAMBDA_API_GW_FUNCTION}" \
98+
--name live \
99+
--function-version $API_GW_VERSION
100+
101+
echo "✅ Deployed to both Lambda functions from S3: ${S3_KEY}"
102+
echo " ${LAMBDA_STREAM_FUNCTION}: version $STREAM_VERSION (${GITHUB_SHA})"
103+
echo " ${LAMBDA_API_GW_FUNCTION}: version $API_GW_VERSION (${GITHUB_SHA})"
66104
67105
env:
68106
ENVIRONMENT: ${{ inputs.environment }}
107+
S3_BUCKET: elastic-docs-v3-api-lambda-artifacts
108+
LAMBDA_STREAM_FUNCTION: elastic-docs-v3-${{ inputs.environment }}-lambda-stream-optimized
109+
LAMBDA_API_GW_FUNCTION: elastic-docs-v3-${{ inputs.environment }}-lambda-api-gateway-optimized

.github/workflows/preview-build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -456,7 +456,7 @@ jobs:
456456
)
457457
)
458458
run: |
459-
dotnet run --project src/tooling/docs-assembler -- navigation validate-link-reference
459+
dotnet run --project src/tooling/docs-builder -- assembler navigation validate-link-reference
460460
461461
- uses: elastic/docs-builder/.github/actions/aws-auth@main
462462
if: >

.github/workflows/release.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -167,14 +167,12 @@ jobs:
167167
with:
168168
subject-path: |
169169
.artifacts/publish/docs-builder/release/*.zip
170-
.artifacts/publish/docs-assembler/release/*.zip
171170
172171
- name: Attach Distribution to release
173172
env:
174173
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
175174
run: |
176175
gh release upload ${{ needs.release-drafter.outputs.tag_name }} .artifacts/publish/docs-builder/release/*.zip
177-
gh release upload ${{ needs.release-drafter.outputs.tag_name }} .artifacts/publish/docs-assembler/release/*.zip
178176
shell: bash
179177

180178
publish-release:

.github/workflows/updatecli.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,8 @@ jobs:
2828
permission-pull-requests: write
2929
repositories: |
3030
docs-builder
31+
edot-cloud-forwarder-aws
32+
edot-cloud-forwarder-azure
3133
3234
- uses: elastic/oblt-actions/updatecli/run@v1
3335
with:

AGENTS.md

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,7 @@ This file contains instructions and guidance for AIs when working with the docs-
66

77
This is Elastic's distributed documentation tooling system built on .NET 9, consisting of:
88

9-
- **docs-builder**: CLI tool for building single documentation sets
10-
- **docs-assembler**: CLI tool for assembling multiple doc sets
9+
- **docs-builder**: CLI tool for building documentation sets (either individual or assembled)
1110
- Written in C# and F# with extensive Markdown processing capabilities
1211

1312
## Essential commands
@@ -50,7 +49,6 @@ dotnet test --logger "console;verbosity=detailed"
5049

5150
- `src/Elastic.Markdown/` - Core Markdown processing engine
5251
- `src/tooling/docs-builder/` - Main CLI application
53-
- `src/tooling/docs-assembler/` - Assembly tool
5452
- `src/Elastic.Documentation.Site/` - Web rendering components
5553

5654
### Testing Structure
@@ -70,7 +68,7 @@ dotnet test --logger "console;verbosity=detailed"
7068
### Adding New Features
7169

7270
1. **Markdown Extensions**: Add to `src/Elastic.Markdown/Myst/`
73-
2. **CLI Commands**: Extend `src/tooling/docs-builder/Cli/` or `docs-assembler/Cli/`
71+
2. **CLI Commands**: Extend `src/tooling/docs-builder/Commands/`
7472
3. **Web Components**: Add to `src/Elastic.Documentation.Site/`
7573
4. **Configuration**: Modify `src/Elastic.Documentation.Configuration/`
7674

@@ -99,7 +97,7 @@ You MUST update the documentation when there are changes in the markdown syntax
9997

10098
## Useful file locations
10199

102-
- Entry points: `src/tooling/docs-builder/Program.cs`, `src/tooling/docs-assembler/Program.cs`
100+
- Entry points: `src/tooling/docs-builder/Program.cs`
103101
- Markdown processing: `src/Elastic.Markdown/Myst/`
104102
- Web assets: `src/Elastic.Documentation.Site/Assets/`
105103
- Configuration schemas: `src/Elastic.Documentation.Configuration/`

Directory.Packages.props

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
</ItemGroup>
1313
<!-- AWS -->
1414
<ItemGroup>
15+
<PackageVersion Include="Amazon.Lambda.APIGatewayEvents" Version="2.7.1" />
1516
<PackageVersion Include="Amazon.Lambda.AspNetCoreServer.Hosting" Version="1.9.0" />
1617
<PackageVersion Include="Amazon.Lambda.RuntimeSupport" Version="1.13.4" />
1718
<PackageVersion Include="Amazon.Lambda.Core" Version="2.7.1" />
@@ -20,8 +21,8 @@
2021
<PackageVersion Include="Amazon.Lambda.SQSEvents" Version="2.2.0" />
2122
<PackageVersion Include="Aspire.Hosting" Version="9.5.2" />
2223
<PackageVersion Include="Aspire.Hosting.Testing" Version="9.4.2" />
23-
<PackageVersion Include="AWSSDK.Core" Version="4.0.1.2" />
24-
<PackageVersion Include="AWSSDK.SQS" Version="4.0.0.1" />
24+
<PackageVersion Include="AWSSDK.Core" Version="4.0.1.3" />
25+
<PackageVersion Include="AWSSDK.SQS" Version="4.0.2" />
2526
<PackageVersion Include="AWSSDK.S3" Version="4.0.7.14" />
2627
<PackageVersion Include="Elastic.OpenTelemetry" Version="1.1.0" />
2728
<PackageVersion Include="OpenTelemetry.Instrumentation.AspNetCore" Version="1.12.0" />
@@ -41,14 +42,14 @@
4142
<!-- Build -->
4243
<ItemGroup>
4344
<PackageVersion Include="Argu" Version="6.2.5" />
44-
<PackageVersion Include="Bullseye" Version="5.0.0" />
45+
<PackageVersion Include="Bullseye" Version="6.0.0" />
4546
<PackageVersion Include="Proc.Fs" Version="0.9.1" />
4647
<PackageVersion Include="Fake.Tools.Git" Version="6.1.3" />
4748
<PackageVersion Include="Fake.IO.Zip" Version="6.1.3" />
4849
<PackageVersion Include="FSharp.Core" Version="9.0.202" />
4950
</ItemGroup>
5051
<ItemGroup>
51-
<PackageVersion Include="ConsoleAppFramework" Version="5.4.1" PrivateAssets="all" IncludeAssets="runtime; build; native; contentfiles; analyzers; buildtransitive" />
52+
<PackageVersion Include="ConsoleAppFramework" Version="5.6.2" PrivateAssets="all" IncludeAssets="runtime; build; native; contentfiles; analyzers; buildtransitive" />
5253
<PackageVersion Include="ConsoleAppFramework.Abstractions" Version="5.4.1" />
5354
<PackageVersion Include="Crayon" Version="2.0.69" />
5455
<PackageVersion Include="DotNet.Glob" Version="3.1.3" />

0 commit comments

Comments
 (0)