Commit Graph

79 Commits

Author SHA1 Message Date
Patrik Oldsberg 754109ee61 v0.1.1-alpha.26 2020-10-27 12:00:01 +01:00
Patrik Oldsberg 24e5730200 techdocs-backend: remove duplicate log tagging 2020-10-27 10:14:47 +01:00
Mathias Åhsberg 834f602eaf Upgrade git-url-parse to v11.4.0 2020-10-24 16:19:54 +02:00
Patrik Oldsberg bc9f536545 Merge pull request #2994 from spotify/rugvip/conflagrate
config-loader: switch to using --config options to load in config
2020-10-22 18:01:21 +02:00
Sachin Tewari df94d7edda Fix GitHub OAuth format (#3036)
* Fix GitHub OAuth format

* Fix extraction of apiBaseUrl from config

* Add 'x-oauth-basic' as password
2020-10-22 16:44:53 +02:00
Patrik Oldsberg f495ba9c18 techdocs-backend: fix config loading in git-auth 2020-10-22 12:49:02 +02:00
blam 1bc1c3af06 Merge branch 'master' of github.com:spotify/backstage into migrate-to-msw
* 'master' of github.com:spotify/backstage:
  Read git auth token from backend config (#2992)
  chore(catalog-model): add the petstore into the default entities
  chore(deps-dev): bump @storybook/addon-actions from 6.0.21 to 6.0.26
  chore(deps): bump eslint-config-prettier from 6.10.0 to 6.14.0
  Add API docs link to About card
  adds a sample organization set of users and groups (#2963)
  Make sure hasCostsWithinTimeframe is a boolean
  fix(catalog-backend): fix codeowners processor to handle users
  feat(catalog): add simple client side paging
  default to last 30 days
  Removed default-branch library since it's no longer used (#3019)
  useRealTimers in  onCssReady test case
  move type dependecy
  remove unused import
  changeset
  simpler query params
2020-10-22 11:02:32 +02:00
Patrik Oldsberg 8c2b76e45f config-loader: switch to using --config options to load in config 2020-10-22 10:52:06 +02:00
Sachin Tewari 1d652bbb2f Read git auth token from backend config (#2992) 2020-10-22 09:31:32 +02:00
Sebastian Qvarfordt 08ced1df2e Removed default-branch library since it's no longer used (#3019) 2020-10-21 14:00:15 +02:00
blam 681c861d25 Merge remote-tracking branch 'origin' into migrate-to-msw
* origin:
  fix: ts
  fix: forwardRef to SidebarItem
  fix(cli): one more await in the test
  backend-common: make loadBackendConfig return config directly and log all resolved app-configs
2020-10-21 13:57:40 +02:00
Patrik Oldsberg acb48c1876 Merge pull request #2976 from spotify/rugvip/logconf
backend-common: make loadBackendConfig return config directly and log all resolved app-configs
2020-10-21 13:00:52 +02:00
blam 06f410cc93 Merge branch 'master' of github.com:spotify/backstage into migrate-to-msw
* 'master' of github.com:spotify/backstage: (34 commits)
  TechDocs Backend: Replace hardcoded github api by configuration value (#3004)
  fix: accordion details design for job stage failure  (#3014)
  fix: responsive of page example in storybook (#3005)
  fix: update the ItemCard component and it's story (#3007)
  rename stories folder to Chip (#3009)
  feat: Display the plugins InfoCards on EntityPage Overwiev suitable full height (#2826)
  fix(cost-insights): More exports to help custom alerting
  chore(scaffolder): bump rjsf
  remove unused CSS (#2999)
  feat: update github pull requests package version
  fix(github-actions): fix crash when viewing ongoing workflows
  fix(cli): removePlugin forgotten await
  catalog-backend: relations db review comments and more tests
  Feat/add aws lambda plugin (#2985)
  chore(deps): bump object-path from 0.11.4 to 0.11.5 (#2983)
  add changeset
  fix CodeSnippet test case warnings
  fix CopyTextButton test case warnings
  fix the warning by wrapping in act
  fix(catalog): fix link to techdocs
  ...
2020-10-21 11:27:18 +02:00
Emre Konar 22ff8fba5e TechDocs Backend: Replace hardcoded github api by configuration value (#3004)
* replace hardcoded  by configuration value

* use integrations configuration to read github apiBaseUrl

Co-authored-by: Emre Konar <emre.konar@zalando.de>
2020-10-21 11:03:05 +02:00
blam 0f76b11669 chore: fixing typescript issues with using the new fetch 2020-10-20 10:17:31 +02:00
Patrik Oldsberg 7bbeb049fe backend-common: make loadBackendConfig return config directly and log all resolved app-configs 2020-10-20 00:10:28 +02:00
blam 101978963d Merge branch 'master' of github.com:spotify/backstage into migrate-to-msw
* 'master' of github.com:spotify/backstage: (139 commits)
  Cleanup
  Update PinButton.test.tsx
  feat: update github insights plugin version (#2973)
  Ignore IntelliJ *.iml files (#2971)
  chore(deps): bump rollup-plugin-dts from 1.4.11 to 1.4.13
  fix the plugin card on plugins page
  align 'Add to Marketplace' button on plugins page
  fix the PluginGrid on mobiles sizes
  use getBy query instead of queryBy when asserting for elements present in document (#2951)
  Update PinButton.tsx
  Add test case for Progress component (#2953)
  fix the styling of footer copy on mobile
  add changeset
  handle the case where no entities are available to show
  core-api: work around issue with ApiRef export const declarations
  core-api: move utility api system implementation into apis/system
  Update docs regarding npm config ignore-scripts flag
  Another try
  Fix Core Features configuration id (#2948)
  Fix test?
  ...
2020-10-19 23:57:40 +02:00
Sebastian Qvarfordt b041aab8ad [TechDocs] Remove all git preparers and use a commonGit preparer instead (#2856)
* Remove all git preparers and use a commonGit preparer instead

* Added more tests

* Updated default-app template
2020-10-13 09:07:14 +02:00
blam e44cb85b22 Merge branch 'master' of github.com:spotify/backstage into migrate-to-msw
* 'master' of github.com:spotify/backstage: (66 commits)
  chore: fix lerna linting
  v0.1.1-alpha.25
  Add Code Insights plugin to sample app and marketplace (#2833)
  Improve main CI build status badge in README (#2866)
  Update roadmap: Design System 🚢 (#2858)
  github/codecov: switch to informational mode
  github/workflows: use the tip of master as the base for comparing PR code coverage
  make saml provider path from globalConfig (#2855)
  fix(catalog-backend): limit search value lengths
  Update project Copyright (#2852)
  fix(catalog-backend): actually use modified entity output (default namespace was broken)
  remove unnecessary center keyword
  Move card header bg to up contrast, fix #2558
  Update name of env authentication env vars
  Fix feedback from dtuite
  Remove chart testing workflow for now
  Only lint charts on Pull Requests
  Move the k8s deployment docs to its own helm deployment page
  Remove line in initdb script that creates backend db
  Use app-config.development.yaml to provide configuration instead of local
  ...
2020-10-13 03:56:13 +02:00
blam 46960a61ec v0.1.1-alpha.25 2020-10-12 22:42:54 +02:00
Patrik Oldsberg 468d4a2dae Merge pull request #2684 from themousepotato/lintrule-dirname-fix
Add a lint rule to avoid using __dirname
2020-10-09 21:03:13 +02:00
blam b33353dd39 Merge branch 'master' of github.com:spotify/backstage into migrate-to-msw
* 'master' of github.com:spotify/backstage: (110 commits)
  chore(catalog-backend): removing redudant classes and some functions
  chore(deps-dev): bump @types/webpack from 4.41.21 to 4.41.22 (#2765)
  move codecov.yml to .github
  feat(catalog-backend): add batch concurrency
  create-app: remove build step
  cli: simplify jest transform ignore regex
  feat(catalog-backend): introduce batching, speed up reading and writing of large datasets
  Techdocs: add Azure DevOps prepare support (#2748)
  feat(techdocs-header): Show breadcrumbs on docs page (#2786)
  changesets: add entry for create-app template location fix
  create-app: revert to github location type for example templates
  fix: make catalog filter work again
  Use new url scheme for techdocs
  feat: remove LocationProcessor.processEntity
  Add Dockerfile for helm chart
  feat: use the new UrlReader in the CodeOwnersProcessor
  feat: use new UrlReader in PlaceholderProcessor
  feat: remove the backstage.io/definition-at-location annotation
  Update loud-lamps-visit.md
  feat(proxy-backend): limit the forwarded http headers to a safe set
  ...
2020-10-09 14:48:32 +02:00
blam f36e1e9fe7 chore: remove node-fetch from the project 2020-10-09 14:14:53 +02:00
blam a0604474c1 chore: removing the last of the deps in the plugins 2020-10-09 13:49:10 +02:00
Navaneeth Suresh bbeaff9daf Add a lint rule to avoid using __dirname 2020-10-09 15:03:29 +05:30
Himanshu Mishra c852e7b09d Merge pull request #2812 from spotify/sebastianq/techdocs-new-component-url
[TechDocs] Use new url scheme for techdocs
2020-10-09 10:41:47 +02:00
Mattias Frinnström b46863b88b Techdocs: add Azure DevOps prepare support (#2748)
* Update to latest git-url-parse

* Add Azure DevOps preparer to techdocs

* Upgraded git-url-parse in backend-common

* Switch to AZURE_TOKEN

Co-authored-by: Mattias Frinnström <mattias.frinnstrom@husqvarnagroup.com>
2020-10-09 09:37:20 +02:00
Sebastian Qvarfordt ae499a55ff Use new url scheme for techdocs 2020-10-08 16:59:30 +02:00
Marvin9 f05e4b9608 re: make consistent environment variables
GITHUB_PRIVATE_TOKEN & GITHUB_ACCESS_TOKEN => GITHUB_TOKEN
GITLAB_PRIVATE_TOKEN, GITLAB_ACCESS_TOKEN & SCAFFOLDER_GITLAB_PRIVATE_TOKEN => GITLAB_TOKEN
AZURE_PRIVATE_TOKEN => AZURE_TOKEN
GHE_PRIVATE_TOKEN => GHE_TOKEN
2020-10-08 10:34:06 +05:30
Patrik Oldsberg 46b71700ee v0.1.1-alpha.24 2020-10-05 15:45:33 +02:00
Sebastian Qvarfordt c16920db2b Always rebuild docs if stored locally (#2719) 2020-10-02 11:48:01 +02:00
Evgeny Vlasov e0dce26354 TechDocs: add gitlab preparer & rewrite default-branch package (#2469)
* add gitlab preparer & rewrite default-branch package

* feat(techdocs-backend): rewrite default-branch module
2020-10-02 11:10:02 +02:00
Emma Indal 497675538c TechDocs: browse metadata (#2682)
* feat(techdocs): TechDocsPageWrapper to take in labels prop and use TechDocsHeader component

* feat(techdocs): new TechDocsHeader component as wrapper around Header from core

* feat(techdocs): TechDocsPage metadata

* feat(techdocs): TechDocsMetadata class responsible for reading metadata from generated techdocs metadata json file

* fix(techdocs): delete TechDocsPageWrapper component

* fix(app-config): delete /docs from request url

* feat(techdocs): TechDocsHeader with labels to browse metadata

* fix(techdocs): move metadata to backend plugin

* feat(techdocs-backend): introduce two new metadata routes

* feat(techdocs): new techdocs api to be responsible to request metadata from backend

* feat(techdocs): register new api for plugin

* fix(techdocs): reader to take in onReady prop

* fix(techdocs): TechDocsHome component to use its own header

* fix(techdocs): TechDocsPage responsible to get metadata and pass it down to the TechDocsHeader

* fix(techdocs): component tests for both TechDocsHeader and TechDocsPage

* fix(techdocs): adjust api to use /docs in url since it was taken away in requestURL

* fix(tests): move assertion into act

* fix(techdocs): rename TechDocsHeader to TechDocsPageHeader

* fix(techdocs): rename TechDocsHeader to TechDocsPageHeader

* fix(techdocs-backend): add some logs

* Update plugins/techdocs/src/reader/components/TechDocsPage.test.tsx

* delete unused import
2020-10-01 10:12:24 +02:00
Patrik Oldsberg 2a443ce68d techdocs-backend: use endpoint discovery to look up catalog url 2020-09-25 10:50:33 +02:00
Emma Indal b41ffc8c0f add /api to catalog endpoint (#2595) 2020-09-24 17:26:34 +02:00
Patrik Oldsberg 9c5a0e836b Merge pull request #2562 from spotify/rugvip/api
backend: change the default backend plugin mount point to /api
2020-09-24 15:58:12 +02:00
blam 6c55d38348 v0.1.1-alpha.23 2020-09-23 16:40:49 +02:00
Patrik Oldsberg 521728348d backend: change the default backend plugin mount point to /api 2020-09-23 09:39:47 +02:00
Sebastian Qvarfordt b80a833323 comment to explain option 2020-09-21 16:51:46 +02:00
Sebastian Qvarfordt 525aabeb47 Added toggled option for allowing longpath in windows through nodegit 2020-09-21 15:33:53 +02:00
Raghunandan 72235dd51e v0.1.1-alpha.22 2020-09-18 15:14:38 +02:00
Sebastian Qvarfordt f097c32b59 TechDocs: Use a flag to determine if we should use a local mkdocs or techdocs-container (#2503)
* Use a flag to determine wether to use techdocs-container or local install of mkdocs

* Updated techdocs generator to look at app-config string instead of argument to decide how to run the generator

* Removed console log...

* Reverted scaffolder file that was accidentally committed.

* Fixed lint issues

* Added config to create-app template
2020-09-18 14:02:35 +02:00
Perry Manuk 21a366077a Techdocs without docker-in-docker (#2438)
We're deploying backstage to GKE and have had issues getting techdocs
volume mount logic to work because of mixing paths between the host and
the container running the backend. So we added a condition where if
mkdocs is found in the backend container it will use that to generate
the docs rather than spinning it up in a docker container.
2020-09-17 15:26:39 +02:00
Iain Billett 2331e79897 Test for docker before attempting to run a container (#2497)
Test for docker using ping() before attempting any docker
operations. If this fails we know docker is unavailable
and we can fail with an more descriptive error.
2020-09-17 15:18:13 +02:00
Björn Marschollek 55542797a9 Add GitLab integration for scaffolder
This adds a GitLab integration for the scaffolder backend.

We're introduceing a preparer and a publisher for GitLab so that we can
read templates from GitLab and publish them to a configured GitLab
instance. The two instances don't need to be the same. For instance,
templates could be public on gitlab.com, but the created repos will live
in a hosted GitLab somewhere else.

The publisher gets its own config object in `app-config.yaml` where the
target instance and token can be specified.

The service catalogue defines both `gitlab` and `gitlab/api` as
processors. They are both handled by the same preparer.

Closes #2372
2020-09-17 12:39:05 +02:00
Sebastian Qvarfordt 398d7eb91e TechDocs: Fix building if you already have a corrupt git tmp folder (#2457)
* Fix building if you already have a corrupt git tmp folder

* Logging the error we get before trying to recover
2020-09-14 16:57:37 +02:00
Patrik Oldsberg 3cf20cbad7 remove mock-data scripts 2020-09-12 15:27:27 +02:00
Sebastian Qvarfordt d865f88344 [TechDocs] Rebuild docs if the github source is newer than last docs build (#2353)
* Added age check for documentation in github to make sure it's up to date

* Updated failing tests

* Updated docs to explain requestUrl and storageUrl

* Updated failing tests

* Update packages/create-app/templates/default-app/app-config.yaml.hbs

* Update docs/features/techdocs/getting-started.md

Co-authored-by: Emma Indal <emmai@spotify.com>
2020-09-09 16:05:28 +02:00
Patrik Oldsberg 566f1f890e techdocs-backend: make tests work on windows 2020-09-06 14:38:24 +02:00
Jacob Valdemar 01f4563c92 TechDocs & Catalog: Private Github repository support (#2247)
* Add private repo functionality to GhReaderProcesor

* Add github helper for private github repo

* Edit test

* lint

* Remove debugging console.log()

* Less specific if statement

* shorten get private token

* Actual shortening

* Change how current branch name is retrieved
2020-09-04 09:59:14 +02:00