WIP potentially to be dropped
This commit is contained in:
parent
10cce1376a
commit
880c0d5ec9
14 changed files with 208 additions and 77 deletions
73
.github/workflows/build.yaml
vendored
Normal file
73
.github/workflows/build.yaml
vendored
Normal file
|
|
@ -0,0 +1,73 @@
|
|||
name: build
|
||||
|
||||
on:
|
||||
push:
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-22.04
|
||||
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
submodules: recursive
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Load versions from .env.versions
|
||||
id: versions
|
||||
run: |
|
||||
set -a
|
||||
source .env.versions
|
||||
set +a
|
||||
|
||||
echo "node_version=${NODE_VERSION}" >> "$GITHUB_OUTPUT"
|
||||
echo "go_version=${GO_VERSION}" >> "$GITHUB_OUTPUT"
|
||||
echo "hugo_version=${HUGO_VERSION}" >> "$GITHUB_OUTPUT"
|
||||
|
||||
echo "Node: ${NODE_VERSION}"
|
||||
echo "Go: ${GO_VERSION}"
|
||||
echo "Hugo: ${HUGO_VERSION}"
|
||||
|
||||
- name: Repository meta
|
||||
id: repository
|
||||
run: |
|
||||
registry=${{ github.server_url }}
|
||||
registry=${registry##http*://}
|
||||
echo "registry=${registry}" >> "$GITHUB_OUTPUT"
|
||||
echo "registry=${registry}"
|
||||
repository="$(echo "${{ github.repository }}" | tr '[:upper:]' '[:lower:]')"
|
||||
echo "repository=${repository}" >> "$GITHUB_OUTPUT"
|
||||
echo "repository=${repository}"
|
||||
|
||||
- name: Docker meta
|
||||
uses: docker/metadata-action@v5
|
||||
id: docker
|
||||
with:
|
||||
images: ${{ steps.repository.outputs.registry }}/${{ steps.repository.outputs.repository }}
|
||||
tags: |
|
||||
type=sha,prefix=
|
||||
type=ref,event=tag
|
||||
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v3
|
||||
with:
|
||||
buildkitd-flags: '--allow-insecure-entitlement network.host'
|
||||
driver-opts: network=host
|
||||
|
||||
- name: Build and push
|
||||
uses: docker/build-push-action@v6
|
||||
with:
|
||||
context: .
|
||||
push: true
|
||||
allow: network.host
|
||||
network: host
|
||||
tags: ${{ steps.docker.outputs.tags }}
|
||||
labels: ${{ steps.docker.outputs.labels }}
|
||||
build-args: |
|
||||
NODE_VERSION=${{ steps.versions.outputs.node_version }}
|
||||
GO_VERSION=${{ steps.versions.outputs.go_version }}
|
||||
HUGO_VERSION=${{ steps.versions.outputs.hugo_version }}
|
||||
|
||||
5
.github/workflows/ci.yaml
vendored
5
.github/workflows/ci.yaml
vendored
|
|
@ -2,7 +2,6 @@ name: ci
|
|||
|
||||
on:
|
||||
push:
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
build:
|
||||
|
|
@ -22,11 +21,11 @@ jobs:
|
|||
set -a
|
||||
source .env.versions
|
||||
set +a
|
||||
|
||||
|
||||
echo "node_version=${NODE_VERSION}" >> "$GITHUB_OUTPUT"
|
||||
echo "go_version=${GO_VERSION}" >> "$GITHUB_OUTPUT"
|
||||
echo "hugo_version=${HUGO_VERSION}" >> "$GITHUB_OUTPUT"
|
||||
|
||||
|
||||
echo "Node: ${NODE_VERSION}"
|
||||
echo "Go: ${GO_VERSION}"
|
||||
echo "Hugo: ${HUGO_VERSION}"
|
||||
|
|
|
|||
22
.github/workflows/release.yaml
vendored
22
.github/workflows/release.yaml
vendored
|
|
@ -26,11 +26,11 @@ jobs:
|
|||
set -a
|
||||
source .env.versions
|
||||
set +a
|
||||
|
||||
|
||||
echo "node_version=${NODE_VERSION}" >> "$GITHUB_OUTPUT"
|
||||
echo "go_version=${GO_VERSION}" >> "$GITHUB_OUTPUT"
|
||||
echo "hugo_version=${HUGO_VERSION}" >> "$GITHUB_OUTPUT"
|
||||
|
||||
|
||||
echo "Node: ${NODE_VERSION}"
|
||||
echo "Go: ${GO_VERSION}"
|
||||
echo "Hugo: ${HUGO_VERSION}"
|
||||
|
|
@ -100,7 +100,7 @@ jobs:
|
|||
run: |
|
||||
# Finde vorheriges Tag
|
||||
PREVIOUS_TAG=$(git describe --abbrev=0 --tags ${GITHUB_REF}^ 2>/dev/null || echo "")
|
||||
|
||||
|
||||
if [ -z "$PREVIOUS_TAG" ]; then
|
||||
echo "Erster Release - Changelog von Anfang an"
|
||||
CHANGELOG=$(git log --pretty=format:"- %s (%h)" --no-merges)
|
||||
|
|
@ -108,7 +108,7 @@ jobs:
|
|||
echo "Changelog seit ${PREVIOUS_TAG}"
|
||||
CHANGELOG=$(git log ${PREVIOUS_TAG}..${GITHUB_REF} --pretty=format:"- %s (%h)" --no-merges)
|
||||
fi
|
||||
|
||||
|
||||
# Schreibe in Output-Datei (multiline)
|
||||
{
|
||||
echo 'changelog<<EOF'
|
||||
|
|
@ -128,22 +128,22 @@ jobs:
|
|||
token: ${{ secrets.GITHUB_TOKEN }}
|
||||
release-notes: |
|
||||
# Release ${{ steps.version.outputs.version }}
|
||||
|
||||
|
||||
## Docker Images
|
||||
|
||||
|
||||
Multi-platform images (linux/amd64, linux/arm64) sind verfügbar:
|
||||
|
||||
|
||||
```bash
|
||||
docker pull ${{ steps.repository.outputs.registry }}/${{ steps.repository.outputs.repository }}:${{ steps.version.outputs.version }}
|
||||
docker pull ${{ steps.repository.outputs.registry }}/${{ steps.repository.outputs.repository }}:latest
|
||||
```
|
||||
|
||||
|
||||
## Build Versions
|
||||
|
||||
|
||||
- Node.js: ${{ steps.versions.outputs.node_version }}
|
||||
- Go: ${{ steps.versions.outputs.go_version }}
|
||||
- Hugo: ${{ steps.versions.outputs.hugo_version }}
|
||||
|
||||
|
||||
## Changes
|
||||
|
||||
|
||||
${{ steps.changelog.outputs.changelog }}
|
||||
|
|
|
|||
|
|
@ -74,7 +74,7 @@ jobs:
|
|||
|
||||
### Verification
|
||||
|
||||
See the logs, there should appear a "Hello World!" in "Hello World" Step
|
||||
See the logs, there should appear a "Hello World!" in "Hello World" Step
|
||||
|
||||
## Usage Examples
|
||||
|
||||
|
|
@ -84,7 +84,7 @@ See [infra-deploy](https://edp.buildth.ing/DevFW/infra-deploy/src/branch/main/.g
|
|||
|
||||
### Use goreleaser to build, test, package and release a project
|
||||
|
||||
This pipeline is triggered when a tag with the prefix `v` is pushed to the repository.
|
||||
This pipeline is triggered when a tag with the prefix `v` is pushed to the repository.
|
||||
Then, it fetches the current repository with all tags and checks out the version for the current run.
|
||||
|
||||
After that the application is being built.
|
||||
|
|
@ -144,7 +144,3 @@ jobs:
|
|||
* [Link to external documentation]
|
||||
* [Link to community resources]
|
||||
* [Link to related components]
|
||||
|
||||
## Documentation Notes
|
||||
|
||||
[Instructions for team members filling in this documentation - remove this section once complete]
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
---
|
||||
title: "Runner Orchestration"
|
||||
linkTitle: "Runner Orchestration"
|
||||
title: Runner Orchestration
|
||||
linkTitle: Runner Orchestration
|
||||
weight: 30
|
||||
description: GARM
|
||||
description: Using GARM to manage short-lived Forgejo runners
|
||||
---
|
||||
|
||||
## Overview
|
||||
|
|
@ -52,25 +52,10 @@ A custom edge-connect provider was implemented for GARM to enable infrastructure
|
|||
- Get the GARM admin password: `kubectl get secret -n garm garm-credentials -o json | jq .data.GARM_ADMIN_PASSWORD -r | base64 -d`
|
||||
- Configure endpoints, credentials, repositories, and runner pools in GARM as described in [TODO](TODO)
|
||||
|
||||
|
||||
## Usage Examples
|
||||
|
||||
### [Use Case 1]
|
||||
|
||||
[Example with code/commands showing common use case]
|
||||
|
||||
```bash
|
||||
# Example commands
|
||||
```
|
||||
|
||||
### [Use Case 2]
|
||||
|
||||
[Another common scenario]
|
||||
|
||||
## Integration Points
|
||||
|
||||
* **[Forgejo]**: Picks up pending action jobs, listen in Forgejo
|
||||
* **[Edge Connect]**: Uses this infrastructure to deploy runners that can pick up open jobs in forgejo
|
||||
* **Forgejo**: Picks up pending action jobs, listen in Forgejo
|
||||
* **Edge Connect**: Uses this infrastructure to deploy runners that can pick up open jobs in forgejo
|
||||
|
||||
## Architecture
|
||||
|
||||
|
|
@ -108,6 +93,8 @@ The diagram below shows how a trigger of an action results in deployment of a ru
|
|||
|
||||
### Deployment Architecture
|
||||
|
||||
{{<likec4-view view="forgejoGarmArchitecture" browser="false" dynamic-variant="sequence" project="architecture" title="Architecture of Forgejo, Garm and Edge Connect">}}
|
||||
|
||||
[Add infrastructure and deployment diagrams showing how the component is deployed]
|
||||
|
||||
TODO c4
|
||||
|
|
@ -217,9 +204,7 @@ Now, connect to the WebUI, use `GARM_ADMIN_USERNAME` and `GARM_ADMIN_PASSWORD` a
|
|||
|
||||
## Additional Resources
|
||||
|
||||
* [Using garm](https://github.com/cloudbase/garm/blob/main/doc/using_garm.md)
|
||||
* [Link to community resources]
|
||||
* [Link to related components]
|
||||
* [Using GARM](https://github.com/cloudbase/garm/blob/main/doc/using_garm.md)
|
||||
|
||||
## Documentation Notes
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
---
|
||||
title: "Deployments"
|
||||
linkTitle: "Deployments"
|
||||
title: Environments
|
||||
linkTitle: Environments
|
||||
weight: 40
|
||||
description: >
|
||||
Deployment targets and edge connectivity solutions.
|
||||
|
|
@ -1,6 +1,6 @@
|
|||
---
|
||||
title: "EdgeConnect Client"
|
||||
linkTitle: "EdgeConnect Client"
|
||||
title: "Client"
|
||||
linkTitle: "Client"
|
||||
weight: 30
|
||||
description: >
|
||||
Client software for establishing EdgeConnect connections
|
||||
|
|
@ -1,6 +1,6 @@
|
|||
---
|
||||
title: EdgeConnect SDK
|
||||
linkTitle: EdgeConnect SDK
|
||||
title: SDK
|
||||
linkTitle: SDK
|
||||
weight: 10
|
||||
description: >
|
||||
Software Development Kit for interacting with EdgeConnect
|
||||
|
|
@ -1,6 +1,6 @@
|
|||
---
|
||||
title: "Infrastructure Orchestration"
|
||||
linkTitle: "Infrastructure Orchestration"
|
||||
title: Orchestration tools
|
||||
linkTitle: Orchestration tools
|
||||
weight: 10
|
||||
description: >
|
||||
Infrastructure deployment and catalog management (infra-deploy, infra-catalogue)
|
||||
|
|
@ -15,6 +15,7 @@ description: >
|
|||
* **Last Updated**: YYYY-MM-DD
|
||||
* **TODO**:
|
||||
* [ ] Add detailed component description
|
||||
* [ ] Add info on deploying infra-deploy / infra-catalogue, and how versioning works
|
||||
* [ ] Include usage examples and code samples
|
||||
* [ ] Add architecture diagrams
|
||||
* [ ] Review and finalize content
|
||||
|
|
|
|||
|
|
@ -15,13 +15,13 @@ This section covers operational aspects of the Edge Developer Platform. In gener
|
|||
|
||||
### EDP
|
||||
|
||||
EDP is running on two OTC clusters (remember: this just means that we twice run the [infra-deploy pipeline](https://edp.buildth.ing/DevFW/infra-deploy/actions?workflow=deploy.yaml&actor=0&status=0) as eyerything is code!)
|
||||
EDP is running on two OTC clusters (remember: this just means that we twice run the [infra-deploy pipeline](https://edp.buildth.ing/DevFW/infra-deploy/actions?workflow=deploy.yaml&actor=0&status=0) as eyerything is code!)
|
||||
|
||||

|
||||
|
||||
#### Further references for infrastructural informations
|
||||
|
||||
* OTC:
|
||||
* OTC:
|
||||
* [IPCEI-CIS Confluence](https://confluence.telekom-mms.com/spaces/IPCEICIS/pages/1000105031/OTC)
|
||||
|
||||
### Edge Connect
|
||||
|
|
@ -44,9 +44,16 @@ But we also got access on the cluster level for operations issues, see picture a
|
|||
|
||||
## Monitoring & Observability
|
||||
|
||||
On EDP the observability cluster is meant to monitor the platform stacks, e.g. by [Grafana](https://grafana.observability.buildth.ing).
|
||||
On EDP the observability cluster is meant to monitor the platform stacks, e.g. by [Grafana](https://grafana.observability.buildth.ing).
|
||||
But there is no operational monitoring lifecycle in place. we didn't define metrics or alerts as there is no operational mode yet.
|
||||
|
||||
Most monitoring and observability is done through grafana, deployed through the observability stack.
|
||||
|
||||
Login is found in the `grafana-admin-credentials` secret.
|
||||
|
||||
|
||||
NOTE document that default deployed stacks are different depending on is_observability flag
|
||||
|
||||

|
||||
|
||||
## Maintenance
|
||||
|
|
|
|||
70
resources/edp-likec4/views/dynamic/cicd/garm-arch.c4
Normal file
70
resources/edp-likec4/views/dynamic/cicd/garm-arch.c4
Normal file
|
|
@ -0,0 +1,70 @@
|
|||
deployment {
|
||||
environment otcKubernetes 'OTC Kubernetes' {
|
||||
description 'OTC Container Cluster Engine hosting EDP platform'
|
||||
technology 'Kubernetes'
|
||||
icon tech:kubernetes
|
||||
|
||||
cluster edpCluster 'EDP Cluster' {
|
||||
description 'EDP platform cluster'
|
||||
|
||||
instanceOf edp.forgejo {
|
||||
description 'Forgejo - Git platform with Actions'
|
||||
}
|
||||
|
||||
instanceOf edp.forgejoActions {
|
||||
description 'CI/CD orchestration for Forgejo'
|
||||
}
|
||||
|
||||
instanceOf edp.garm {
|
||||
description 'GARM container with runner orchestration'
|
||||
}
|
||||
|
||||
instanceOf edp.garm.garm {
|
||||
description 'GARM - Runner lifecycle manager'
|
||||
}
|
||||
|
||||
instanceOf edp.garm.providerEdgeConnect {
|
||||
description 'GARM Provider for Edge Connect'
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
environment edgeConnectEnv 'Edge Connect' {
|
||||
description 'Edge infrastructure for ephemeral runner deployment'
|
||||
technology 'Edge Connect Platform'
|
||||
icon tech:docker
|
||||
|
||||
computeressource runnerInfrastructure 'Runner Infrastructure' {
|
||||
description 'Dynamically provisioned runner instances'
|
||||
|
||||
instanceOf forgejoRunner {
|
||||
description 'Ephemeral Forgejo Actions runner'
|
||||
-> otcKubernetes.edpCluster.forgejo 'registers with and picks up jobs'
|
||||
-> otcKubernetes.edpCluster.garm 'retrieves bootstrap information'
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
views {
|
||||
deployment view forgejoGarmArchitecture {
|
||||
title 'Architecture of Forgejo, Garm and Edge Connect'
|
||||
description 'Deployment architecture showing GARM orchestrating ephemeral runners on Edge Connect for Forgejo Actions'
|
||||
|
||||
include
|
||||
otcKubernetes,
|
||||
otcKubernetes.*,
|
||||
otcKubernetes.**,
|
||||
edgeConnectEnv,
|
||||
edgeConnectEnv.*,
|
||||
edgeConnectEnv.**
|
||||
|
||||
style otcKubernetes {
|
||||
color blue
|
||||
}
|
||||
|
||||
style edgeConnectEnv {
|
||||
color green
|
||||
}
|
||||
}
|
||||
}
|
||||
File diff suppressed because one or more lines are too long
Loading…
Add table
Add a link
Reference in a new issue