Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(#310) {vrrp_,}track_file: Enforce only String datatype #312

Merged
merged 1 commit into from Mar 12, 2024

Conversation

tuxmea
Copy link
Member

@tuxmea tuxmea commented Feb 16, 2024

No description provided.

@rwaffen
Copy link
Sponsor Member

rwaffen commented Feb 16, 2024

can you please go into detail why you want to change this? (just for reference, code looks okay)

@bastelfreak
Copy link
Member

Example config:

track_file acme {
  file     "/var/local/vrrp_track_file"
  weight      1
}
vrrp_instance lb_slm_test_4 {
  interface                 ens192
  state                     MASTER
  virtual_router_id         4
  priority                  50
  advert_int                1
  garp_master_delay         5

  track_script {
    access-lb
  }

  track_file {
    acme weight 1
  }

  virtual_ipaddress {
    127.0.0.1/27 dev eth0
  }
}

The parameter track_file in keepalived::vrrp::instance is the list track_file:

  track_file {
    acme weight 1
  }

This can be a random string and references a track_file block with that name:

track_file acme {
  file     "/var/local/vrrp_track_file"
  weight      1
}

^ is created by keepalived::vrrp::track_file defined resource.

@bastelfreak bastelfreak added the bug Something isn't working label Mar 12, 2024
@bastelfreak bastelfreak changed the title vrrp_track file can be an absolute path or a non-empty string (#/310) vrrp_track file can be an absolute path or a non-empty string Mar 12, 2024
@bastelfreak bastelfreak changed the title (#/310) vrrp_track file can be an absolute path or a non-empty string (#310) {vrrp_,}track_file: Enforce only String datatype Mar 12, 2024
Example config:

```
track_file acme {
  file     "/var/local/vrrp_track_file"
  weight      1
}
vrrp_instance lb_slm_test_4 {
  interface                 ens192
  state                     MASTER
  virtual_router_id         4
  priority                  50
  advert_int                1
  garp_master_delay         5

  track_script {
    access-lb
  }

  track_file {
    acme weight 1
  }

  virtual_ipaddress {
    127.0.0.1/27 dev eth0
  }
}
```

The parameter `track_file` in `keepalived::vrrp::instance` is the list `track_file`:

```
  track_file {
    acme weight 1
  }
```

This can be a random string and references a `track_file` block with that name:

```
track_file acme {
  file     "/var/local/vrrp_track_file"
  weight      1
}
```

^ is created by `keepalived::vrrp::track_file` defined resource.
@bastelfreak bastelfreak merged commit 103b8a8 into voxpupuli:master Mar 12, 2024
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants