Fixed typos
This commit is contained in:
parent
b3b658a955
commit
4d22c45b76
7 changed files with 8 additions and 8 deletions
|
@ -76,7 +76,7 @@ You can access to a simple HTML frontend of Træfik.
|
||||||
|
|
||||||
## Plumbing
|
## Plumbing
|
||||||
|
|
||||||
- [Oxy](https://github.com/vulcand/oxy): an awsome proxy library made by Mailgun guys
|
- [Oxy](https://github.com/vulcand/oxy): an awesome proxy library made by Mailgun guys
|
||||||
- [Gorilla mux](https://github.com/gorilla/mux): famous request router
|
- [Gorilla mux](https://github.com/gorilla/mux): famous request router
|
||||||
- [Negroni](https://github.com/codegangsta/negroni): web middlewares made simple
|
- [Negroni](https://github.com/codegangsta/negroni): web middlewares made simple
|
||||||
- [Manners](https://github.com/mailgun/manners): graceful shutdown of http.Handler servers
|
- [Manners](https://github.com/mailgun/manners): graceful shutdown of http.Handler servers
|
||||||
|
|
|
@ -181,7 +181,7 @@ func (a *ACME) CreateConfig(tlsConfig *tls.Config, CheckOnDemandDomain func(doma
|
||||||
acme.Logger = fmtlog.New(ioutil.Discard, "", 0)
|
acme.Logger = fmtlog.New(ioutil.Discard, "", 0)
|
||||||
|
|
||||||
if len(a.StorageFile) == 0 {
|
if len(a.StorageFile) == 0 {
|
||||||
return errors.New("Empty StorageFile, please provide a filenmae for certs storage")
|
return errors.New("Empty StorageFile, please provide a filename for certs storage")
|
||||||
}
|
}
|
||||||
|
|
||||||
log.Debugf("Generating default certificate...")
|
log.Debugf("Generating default certificate...")
|
||||||
|
|
|
@ -19,7 +19,7 @@ Let's zoom on Træfɪk and have an overview of its internal architecture:
|
||||||
![Architecture](img/internal.png)
|
![Architecture](img/internal.png)
|
||||||
|
|
||||||
- Incoming requests end on [entrypoints](#entrypoints), as the name suggests, they are the network entry points into Træfɪk (listening port, SSL, traffic redirection...).
|
- Incoming requests end on [entrypoints](#entrypoints), as the name suggests, they are the network entry points into Træfɪk (listening port, SSL, traffic redirection...).
|
||||||
- Traffic is then forwared to a matching [frontend](#frontends). A frontend defines routes from [entrypoints](#entrypoints) to [backends](#backends).
|
- Traffic is then forwarded to a matching [frontend](#frontends). A frontend defines routes from [entrypoints](#entrypoints) to [backends](#backends).
|
||||||
Routes are created using requests fields (`Host`, `Path`, `Headers`...) and can match or not a request.
|
Routes are created using requests fields (`Host`, `Path`, `Headers`...) and can match or not a request.
|
||||||
- The [frontend](#frontends) will then send the request to a [backend](#backends). A backend can be composed by one or more [servers](#servers), and by a load-balancing strategy.
|
- The [frontend](#frontends) will then send the request to a [backend](#backends). A backend can be composed by one or more [servers](#servers), and by a load-balancing strategy.
|
||||||
- Finally, the [server](#servers) will forward the request to the corresponding microservice in the private network.
|
- Finally, the [server](#servers) will forward the request to the corresponding microservice in the private network.
|
||||||
|
@ -142,7 +142,7 @@ For example:
|
||||||
|
|
||||||
## Servers
|
## Servers
|
||||||
|
|
||||||
Servers are simply defined using a `URL`. You can also apply a custom `weight` to each server (this will be used by load-balacning).
|
Servers are simply defined using a `URL`. You can also apply a custom `weight` to each server (this will be used by load-balancing).
|
||||||
|
|
||||||
Here is an example of backends and servers definition:
|
Here is an example of backends and servers definition:
|
||||||
|
|
||||||
|
|
|
@ -258,7 +258,7 @@ defaultEntryPoints = ["http", "https"]
|
||||||
rule = "Path:/test"
|
rule = "Path:/test"
|
||||||
```
|
```
|
||||||
|
|
||||||
- or put your rules in a separate file, for example `rules.tml`:
|
- or put your rules in a separate file, for example `rules.toml`:
|
||||||
|
|
||||||
```toml
|
```toml
|
||||||
# traefik.toml
|
# traefik.toml
|
||||||
|
|
|
@ -25,7 +25,7 @@
|
||||||
],
|
],
|
||||||
"labels": {
|
"labels": {
|
||||||
"traefik.weight": "1",
|
"traefik.weight": "1",
|
||||||
"traefik.protocole": "http",
|
"traefik.protocol": "http",
|
||||||
"traefik.frontend.rule" : "Host:test.marathon.localhost"
|
"traefik.frontend.rule" : "Host:test.marathon.localhost"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
2
rules.go
2
rules.go
|
@ -116,7 +116,7 @@ func (r *Rules) Parse(expression string) (*mux.Route, error) {
|
||||||
}
|
}
|
||||||
parsedFunction, ok := functions[parsedFunctions[0]]
|
parsedFunction, ok := functions[parsedFunctions[0]]
|
||||||
if !ok {
|
if !ok {
|
||||||
return nil, errors.New("Error parsing rule: " + expression + ". Unknow function: " + parsedFunctions[0])
|
return nil, errors.New("Error parsing rule: " + expression + ". Unknown function: " + parsedFunctions[0])
|
||||||
}
|
}
|
||||||
parsedFunctions = append(parsedFunctions[:0], parsedFunctions[1:]...)
|
parsedFunctions = append(parsedFunctions[:0], parsedFunctions[1:]...)
|
||||||
fargs := func(c rune) bool {
|
fargs := func(c rune) bool {
|
||||||
|
|
|
@ -13,7 +13,7 @@ type Backend struct {
|
||||||
MaxConn *MaxConn `json:"maxConn,omitempty"`
|
MaxConn *MaxConn `json:"maxConn,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// MaxConn holds maximum connection configuraiton
|
// MaxConn holds maximum connection configuration
|
||||||
type MaxConn struct {
|
type MaxConn struct {
|
||||||
Amount int64 `json:"amount,omitempty"`
|
Amount int64 `json:"amount,omitempty"`
|
||||||
ExtractorFunc string `json:"extractorFunc,omitempty"`
|
ExtractorFunc string `json:"extractorFunc,omitempty"`
|
||||||
|
|
Loading…
Reference in a new issue