feature(techdocs): added an example component in techdocs-backend containing a documentation reference

This commit is contained in:
Sebastian Qvarfordt
2020-07-22 16:44:14 +02:00
parent dfa34bdb3e
commit 9e2606a89a
5 changed files with 35 additions and 1 deletions
@@ -0,0 +1,3 @@
# example docs
This is a basic example of documentation.
@@ -0,0 +1,11 @@
apiVersion: backstage.io/v1alpha1
kind: Component
metadata:
name: documented-component
description: A Service with TechDocs documentation
annotations:
spotify.com/techdocs-ref: 'dir:./'
spec:
type: service
lifecycle: experimental
owner: documented@example.com
@@ -0,0 +1,7 @@
site_name: 'example-docs'
nav:
- Home: index.md
plugins:
- techdocs-core
+2 -1
View File
@@ -17,7 +17,8 @@
"test": "backstage-cli test",
"prepack": "backstage-cli prepack",
"postpack": "backstage-cli postpack",
"clean": "backstage-cli clean"
"clean": "backstage-cli clean",
"mock-data": "./scripts/mock-data.sh"
},
"dependencies": {
"@backstage/backend-common": "^0.1.1-alpha.15",
+12
View File
@@ -0,0 +1,12 @@
#!/usr/bin/env bash
for URL in \
'documented-component/documented-component.yaml' \
; do \
curl \
--location \
--request POST 'localhost:7000/catalog/locations' \
--header 'Content-Type: application/json' \
--data-raw "{\"type\": \"file\", \"target\": \"$(pwd)/examples/${URL}\"}"
echo
done