lxc-solr: detect the real partition options
This commit is contained in:
parent
8089d90bd1
commit
26f9d171a4
|
@ -14,6 +14,8 @@ The **patch** part changes is incremented if multiple releases happen the same m
|
||||||
|
|
||||||
### Changed
|
### Changed
|
||||||
|
|
||||||
|
* lxc-solr: detect the real partition options
|
||||||
|
|
||||||
### Fixed
|
### Fixed
|
||||||
|
|
||||||
### Removed
|
### Removed
|
||||||
|
|
|
@ -43,11 +43,19 @@
|
||||||
- lxc_unprivilegied_containers | bool
|
- lxc_unprivilegied_containers | bool
|
||||||
- root_subuids.rc != 0
|
- root_subuids.rc != 0
|
||||||
|
|
||||||
- name: Check if /var has not mount options or nosuid or nodev or noexec
|
- name: Get filesystem options
|
||||||
shell: findmnt | grep -E "/var[^/]" | grep -e nodev -e noexec -e nosuid
|
command: findmnt --noheadings --target /var/lib/lxc --output OPTIONS
|
||||||
register: check_var
|
|
||||||
changed_when: false
|
changed_when: false
|
||||||
failed_when: "check_var.rc == 0"
|
check_mode: no
|
||||||
|
register: check_fs_options
|
||||||
|
|
||||||
|
- name: Check if options are correct
|
||||||
|
assert:
|
||||||
|
that:
|
||||||
|
- "'nodev' not in check_fs_options.stdout"
|
||||||
|
- "'noexec' not in check_fs_options.stdout"
|
||||||
|
- "'nosuid' not in check_fs_options.stdout"
|
||||||
|
msg: "LXC directory is in a filesystem with incompatible options"
|
||||||
|
|
||||||
- name: Create containers
|
- name: Create containers
|
||||||
include: create-container.yml
|
include: create-container.yml
|
||||||
|
|
Loading…
Reference in a new issue