Commit bc1dd0a9 authored by Jonston Chan's avatar Jonston Chan

Quote cURL URLs in /doc/{install,migrate_ci_to_ce,topics,update,user}

Adds double quotes to cURL examples in install, migrate_ci_to_ce,
topics, update, and user docs to enforce standards.
parent b5aee638
......@@ -215,7 +215,7 @@ Download Ruby and compile it:
```shell
mkdir /tmp/ruby && cd /tmp/ruby
curl --remote-name --progress https://cache.ruby-lang.org/pub/ruby/2.7/ruby-2.7.2.tar.gz
curl --remote-name --progress "https://cache.ruby-lang.org/pub/ruby/2.7/ruby-2.7.2.tar.gz"
echo 'cb9731a17487e0ad84037490a6baf8bfa31a09e8 ruby-2.7.2.tar.gz' | shasum -c - && tar xzf ruby-2.7.2.tar.gz
cd ruby-2.7.2
......@@ -235,7 +235,7 @@ page](https://golang.org/dl).
# Remove former Go installation folder
sudo rm -rf /usr/local/go
curl --remote-name --progress https://dl.google.com/go/go1.13.5.linux-amd64.tar.gz
curl --remote-name --progress "https://dl.google.com/go/go1.13.5.linux-amd64.tar.gz"
echo '512103d7ad296467814a6e3f635631bd35574cab3369a97a323c9a585ccaa569 go1.13.5.linux-amd64.tar.gz' | shasum -a256 -c - && \
sudo tar -C /usr/local -xzf go1.13.5.linux-amd64.tar.gz
sudo ln -sf /usr/local/go/bin/{go,godoc,gofmt} /usr/local/bin/
......@@ -257,10 +257,10 @@ we need to install through the following commands:
```shell
# install node v12.x
curl --location https://deb.nodesource.com/setup_12.x | sudo bash -
curl --location "https://deb.nodesource.com/setup_12.x" | sudo bash -
sudo apt-get install -y nodejs
curl --silent --show-error https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
curl --silent --show-error "https://dl.yarnpkg.com/debian/pubkey.gpg" | sudo apt-key add -
echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list
sudo apt-get update
sudo apt-get install yarn
......
......@@ -324,8 +324,8 @@ properly forward the requests.**
You should also make sure that you can:
1. `curl https://YOUR_GITLAB_SERVER_FQDN/` from your previous GitLab CI server.
1. `curl https://YOUR_CI_SERVER_FQDN/` from your GitLab CE (or EE) server.
1. `curl "https://YOUR_GITLAB_SERVER_FQDN/"` from your previous GitLab CI server.
1. `curl "https://YOUR_CI_SERVER_FQDN/"` from your GitLab CE (or EE) server.
### 2. Check NGINX configuration
......
......@@ -662,5 +662,5 @@ The banner can be disabled for:
- Through the REST API with an admin access token:
```shell
curl --data "value=true" --header "PRIVATE-TOKEN: <personal_access_token>" https://gitlab.example.com/api/v4/features/auto_devops_banner_disabled
curl --data "value=true" --header "PRIVATE-TOKEN: <personal_access_token>" "https://gitlab.example.com/api/v4/features/auto_devops_banner_disabled"
```
......@@ -201,7 +201,7 @@ your cluster either using [Cloud Shell](https://cloud.google.com/shell/) or the
NAME HOSTS PORTS
production-auto-deploy fjdiaz-auto-devv-2.34.68.60.207.nip.io,le-16730183.34.68.60.207.nip.io 80, 443
$ curl --location --insecure fjdiaz-auto-devv-2.34.68.60.207.nip.io | grep 'Rails!' --after 2 --before 2
$ curl --location --insecure "fjdiaz-auto-devv-2.34.68.60.207.nip.io" | grep 'Rails!' --after 2 --before 2
<body>
<p>You're on Rails!</p>
</body>
......@@ -216,7 +216,7 @@ Now let's send a potentially malicious request, as if we were a scanner,
checking for vulnerabilities within our application and examine the ModSecurity logs:
```shell
$ curl --location --insecure fjdiaz-auto-devv-2.34.68.60.207.nip.io --header "User-Agent: absinthe" | grep 'Rails!' --after 2 --before 2
$ curl --location --insecure "fjdiaz-auto-devv-2.34.68.60.207.nip.io" --header "User-Agent: absinthe" | grep 'Rails!' --after 2 --before 2
<body>
<p>You're on Rails!</p>
</body>
......
......@@ -70,7 +70,7 @@ Download Ruby and compile it:
```shell
mkdir /tmp/ruby && cd /tmp/ruby
curl --remote-name --progress https://cache.ruby-lang.org/pub/ruby/2.7/ruby-2.7.2.tar.gz
curl --remote-name --progress "https://cache.ruby-lang.org/pub/ruby/2.7/ruby-2.7.2.tar.gz"
echo 'cb9731a17487e0ad84037490a6baf8bfa31a09e8 ruby-2.7.2.tar.gz' | shasum -c - && tar xzf ruby-2.7.2.tar.gz
cd ruby-2.7.2
......@@ -89,7 +89,7 @@ dependencies.
In Debian or Ubuntu:
```shell
curl --silent --show-error https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
curl --silent --show-error "https://dl.yarnpkg.com/debian/pubkey.gpg" | sudo apt-key add -
echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list
sudo apt-get update
sudo apt-get install yarn
......@@ -109,7 +109,7 @@ Download and install Go (for Linux, 64-bit):
# Remove former Go installation folder
sudo rm -rf /usr/local/go
curl --remote-name --progress https://dl.google.com/go/go1.13.5.linux-amd64.tar.gz
curl --remote-name --progress "https://dl.google.com/go/go1.13.5.linux-amd64.tar.gz"
echo '512103d7ad296467814a6e3f635631bd35574cab3369a97a323c9a585ccaa569 go1.13.5.linux-amd64.tar.gz' | shasum -a256 -c - && \
sudo tar -C /usr/local -xzf go1.13.5.linux-amd64.tar.gz
sudo ln -sf /usr/local/go/bin/{go,godoc,gofmt} /usr/local/bin/
......@@ -139,7 +139,7 @@ sudo apt-get remove git-core
sudo apt-get install -y libcurl4-openssl-dev libexpat1-dev gettext libz-dev libssl-dev build-essential
# Download and compile pcre2 from source
curl --silent --show-error --location https://ftp.pcre.org/pub/pcre/pcre2-10.33.tar.gz --output pcre2.tar.gz
curl --silent --show-error --location "https://ftp.pcre.org/pub/pcre/pcre2-10.33.tar.gz" --output pcre2.tar.gz
tar -xzf pcre2.tar.gz
cd pcre2-10.33
chmod +x configure
......@@ -149,7 +149,7 @@ make install
# Download and compile from source
cd /tmp
curl --remote-name --location --progress https://www.kernel.org/pub/software/scm/git/git-2.29.0.tar.gz
curl --remote-name --location --progress "https://www.kernel.org/pub/software/scm/git/git-2.29.0.tar.gz"
echo 'fa08dc8424ef80c0f9bf307877f9e2e49f1a6049e873530d6747c2be770742ff git-2.29.0.tar.gz' | shasum -a256 -c - && tar -xzf git-2.29.0.tar.gz
cd git-2.29.0/
./configure --with-libpcre
......
......@@ -55,7 +55,7 @@ GET /-/health
Example request:
```shell
curl 'https://gitlab.example.com/-/health'
curl "https://gitlab.example.com/-/health"
```
Example response:
......@@ -82,7 +82,7 @@ GET /-/readiness?all=1
Example request:
```shell
curl 'https://gitlab.example.com/-/readiness'
curl "https://gitlab.example.com/-/readiness"
```
Example response:
......@@ -121,7 +121,7 @@ GET /-/liveness
Example request:
```shell
curl 'https://gitlab.example.com/-/liveness'
curl "https://gitlab.example.com/-/liveness"
```
Example response:
......
......@@ -577,7 +577,7 @@ Examples:
- Select all tags, keep at least 1 tag per image, clean up any tag older than 14 days, run once a month, preserve any images with the name `master` and the policy is enabled:
```shell
curl --request PUT --header 'Content-Type: application/json;charset=UTF-8' --header "PRIVATE-TOKEN: <your_access_token>" --data-binary '{"container_expiration_policy_attributes":{"cadence":"1month","enabled":true,"keep_n":1,"older_than":"14d","name_regex":"","name_regex_delete":".*","name_regex_keep":".*-master"}}' 'https://gitlab.example.com/api/v4/projects/2'
curl --request PUT --header 'Content-Type: application/json;charset=UTF-8' --header "PRIVATE-TOKEN: <your_access_token>" --data-binary '{"container_expiration_policy_attributes":{"cadence":"1month","enabled":true,"keep_n":1,"older_than":"14d","name_regex":"","name_regex_delete":".*","name_regex_keep":".*-master"}}' "https://gitlab.example.com/api/v4/projects/2"
```
See the API documentation for further details: [Edit project](../../../api/projects.md#edit-project).
......
......@@ -49,7 +49,7 @@ Example request:
```shell
curl --header "PRIVATE-TOKEN: <your_access_token>" \
--upload-file path/to/file.txt \
https://gitlab.example.com/api/v4/projects/24/packages/generic/my_package/0.0.1/file.txt
"https://gitlab.example.com/api/v4/projects/24/packages/generic/my_package/0.0.1/file.txt"
```
Example response:
......@@ -85,7 +85,7 @@ Example request that uses a personal access token:
```shell
curl --header "PRIVATE-TOKEN: <your_access_token>" \
https://gitlab.example.com/api/v4/projects/24/packages/generic/my_package/0.0.1/file.txt
"https://gitlab.example.com/api/v4/projects/24/packages/generic/my_package/0.0.1/file.txt"
```
## Publish a generic package by using CI/CD
......@@ -105,7 +105,7 @@ stages:
upload:
stage: upload
script:
- 'curl --header "JOB-TOKEN: $CI_JOB_TOKEN" --upload-file path/to/file.txt ${CI_API_V4_URL}/projects/${CI_PROJECT_ID}/packages/generic/my_package/0.0.1/file.txt'
- 'curl --header "JOB-TOKEN: $CI_JOB_TOKEN" --upload-file path/to/file.txt "${CI_API_V4_URL}/projects/${CI_PROJECT_ID}/packages/generic/my_package/0.0.1/file.txt"'
download:
stage: download
......
......@@ -157,7 +157,7 @@ Running the following `curl` command should trigger your function.
Your URL should be the one retrieved from the GitLab deploy stage log:
```shell
curl https://u768nzby1j.execute-api.us-east-1.amazonaws.com/production/hello
curl "https://u768nzby1j.execute-api.us-east-1.amazonaws.com/production/hello"
```
That should output:
......@@ -200,7 +200,7 @@ The `serverless-offline` plugin allows to run your code locally. To run your cod
Running the following `curl` command should trigger your function.
```shell
curl http://localhost:3000/hello
curl "http://localhost:3000/hello"
```
It should output:
......@@ -444,7 +444,7 @@ To test the application you deployed, please go to the build log and follow the
1. Use curl to test the API. For example:
```shell
curl https://py4rg7qtlg.execute-api.us-east-1.amazonaws.com/Prod/hello/
curl "https://py4rg7qtlg.execute-api.us-east-1.amazonaws.com/Prod/hello/"
```
Output should be:
......@@ -496,7 +496,7 @@ listening on `localhost:3000`.
Call the `hello` API by running:
```shell
curl http://127.0.0.1:3000/hello
curl "http://127.0.0.1:3000/hello"
```
Output again should be:
......
......@@ -376,7 +376,7 @@ The sample function can now be triggered from any HTTP client using a simple `PO
--header "Content-Type: application/json" \
--request POST \
--data '{"GitLab":"FaaS"}' \
http://functions-echo.functions-1.functions.example.com/
"http://functions-echo.functions-1.functions.example.com/"
```
1. Using a web-based tool (such as Postman or Restlet)
......@@ -443,7 +443,7 @@ To run a function locally:
1. Invoke your function:
```shell
curl http://localhost:8080
curl "http://localhost:8080"
```
## Deploying Serverless applications
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment