Skip to content

Commit

Permalink
sanitize the code
Browse files Browse the repository at this point in the history
  • Loading branch information
magicaner committed Sep 23, 2024
1 parent 412d576 commit fa6c4cb
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions docs/selector.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Selector

Deployer uses the selector to choose hosts. Each host can have a set of labels.
Labels are key-value pairs.
Labels are key-value pairs.

For example, `stage: production` or `role: web`.

Expand All @@ -25,7 +25,6 @@ host('db.example.com')
```
or use `->addLables()` method to add labels to the existing host.


Now let's define a task to check labels:

```php
Expand Down Expand Up @@ -78,7 +77,6 @@ task info

As you can see, both hosts are selected (as both of them have the `env: prod` label).


We can use `&` to define **AND**. For example, `type=web & env=prod` is a selector
for hosts with `type: web` **AND** `env: prod` labels.

Expand Down Expand Up @@ -168,8 +166,6 @@ task('info', function () {
})->select('type=web|db,env=prod');
```
## Labels in YAML
You can also define labels in a YAML recipe. For example:
Expand Down

0 comments on commit fa6c4cb

Please sign in to comment.