From 1a7f253767a142b4c73d6ce124f1b2eaec77a8f5 Mon Sep 17 00:00:00 2001 From: Stefan Prodan Date: Mon, 14 Dec 2020 16:58:41 +0200 Subject: [PATCH] Fix Azure DevOps SSH URL in docs Signed-off-by: Stefan Prodan --- docs/guides/installation.md | 33 ++++++++++++++++++--------------- mkdocs.yml | 1 + 2 files changed, 19 insertions(+), 15 deletions(-) diff --git a/docs/guides/installation.md b/docs/guides/installation.md index 416894cb..79a26ecd 100644 --- a/docs/guides/installation.md +++ b/docs/guides/installation.md @@ -292,13 +292,16 @@ Create a `GitRepository` object on your cluster by specifying the SSH address of ```sh flux create source git flux-system \ - --url= ssh:////my-repository \ + --url=ssh://git@// \ --ssh-key-algorithm=ecdsa \ --ssh-ecdsa-curve=p521 \ --branch=master \ --interval=1m ``` +You will be prompted to add a deploy key to your repository. +If you don't specify the SSH algorithm, then `flux` will generate an RSA 2048 bits key. + !!! hint "Azure DevOps" Azure DevOps requires a non-default Git implementation (`libgit2`) to be enabled, so that the Git v2 protocol is supported. Note that this implementation does not support shallow cloning, and it is therefore advised to only resort to this option if a @@ -306,20 +309,20 @@ flux create source git flux-system \ Additionally, the current implementation of image automation does not support Azure DevOps as has no Git implementation with this protocol. This limitation will likely change in the future. -If you are using Azure DevOps you need to specify a different git implementation than the default: - -```sh -flux create source git flux-system \ - --url= ssh:////my-repository \ - --ssh-key-algorithm=ecdsa \ - --ssh-ecdsa-curve=p521 \ - --branch=master \ - --interval=1m \ - --git-implementation=libgit2 -``` - -You will be prompted to add a deploy key to your repository. -If you don't specify the SSH algorithm, then `flux` will generate an RSA 2048 bits key. + If you are using Azure DevOps you need to specify a different Git implementation than the default: + + ```sh + flux create source git flux-system \ + --git-implementation=libgit2 \ + --url=git@ssh.dev.azure.com/v3/org/project/repository \ + --branch=master \ + --interval=1m + ``` + + Note that unlike `git`, Flux does not support the + ["shorter" scp-like syntax for the SSH protocol](https://git-scm.com/book/en/v2/Git-on-the-Server-The-Protocols#_the_ssh_protocol) + (e.g. `ssh.dev.azure.com:v3`). + Use the [RFC 3986 compatible syntax](https://tools.ietf.org/html/rfc3986#section-3) instead: `ssh.dev.azure.com/v3`. If your Git server supports basic auth, you can set the URL to HTTPS and specify the credentials with: diff --git a/mkdocs.yml b/mkdocs.yml index f9b443cf..8fc0566d 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -37,6 +37,7 @@ markdown_extensions: - pymdownx.tilde - pymdownx.progressbar - pymdownx.tasklist + - pymdownx.superfences - pymdownx.emoji: emoji_index: !!python/name:materialx.emoji.twemoji emoji_generator: !!python/name:materialx.emoji.to_svg