Merge pull request #3175 from yanc0/fix-server-snippet-annotation-doc
Fix yaml indentation in annotations server-snippet doc
This commit is contained in:
commit
43b47304e3
1 changed files with 9 additions and 9 deletions
|
@ -295,15 +295,15 @@ kind: Ingress
|
|||
metadata:
|
||||
annotations:
|
||||
nginx.ingress.kubernetes.io/server-snippet: |
|
||||
set $agentflag 0;
|
||||
|
||||
if ($http_user_agent ~* "(Mobile)" ){
|
||||
set $agentflag 1;
|
||||
}
|
||||
|
||||
if ( $agentflag = 1 ) {
|
||||
return 301 https://m.example.com;
|
||||
}
|
||||
set $agentflag 0;
|
||||
|
||||
if ($http_user_agent ~* "(Mobile)" ){
|
||||
set $agentflag 1;
|
||||
}
|
||||
|
||||
if ( $agentflag = 1 ) {
|
||||
return 301 https://m.example.com;
|
||||
}
|
||||
```
|
||||
|
||||
!!! attention
|
||||
|
|
Loading…
Reference in a new issue