openqa: adjust to new 'fixed' asset stuff on staging
The capability to handle a variance between prod and staging here is just temporary while I'm testing the new fixed asset handling stuff by deploying it on staging. Once it's tested and merged we'll just have prod and staging do the same thing. But for now we need to cleanly handle them having the static disk images in different places.
This commit is contained in:
parent
01e2ae3b53
commit
33fae65883
4 changed files with 14 additions and 3 deletions
|
@ -28,6 +28,10 @@ openqa_dbuser: openqastg
|
|||
openqa_dbpassword: "{{ stg_openqa_dbpassword }}"
|
||||
openqa_assetsize: 300
|
||||
|
||||
# this is a temporary variance between staging and prod while
|
||||
# testing https://github.com/os-autoinst/openQA/pull/945
|
||||
openqa_fixed: /var/lib/openqa/share/factory/hdd/fixed
|
||||
|
||||
openqa_key: "{{ stg_openqa_apikey }}"
|
||||
openqa_secret: "{{ stg_openqa_apisecret }}"
|
||||
|
||||
|
|
1
roles/openqa/server/defaults/main.yml
Normal file
1
roles/openqa/server/defaults/main.yml
Normal file
|
@ -0,0 +1 @@
|
|||
openqa_fixed: /var/lib/openqa/share/factory/hdd
|
|
@ -16,6 +16,11 @@
|
|||
# - external_hostname
|
||||
## string - The public hostname for the server (will be used as ServerName)
|
||||
## default - ansible_nodename
|
||||
# - openqa_fixed
|
||||
## string - location for fixed hdd assets; this varies depending on
|
||||
## what openQA version is in use. This is a temporary thing
|
||||
## while we're testing PR #945 on staging
|
||||
## default - /var/lib/openqa/share/factory/hdd
|
||||
|
||||
# Optional vars
|
||||
# - openqa_static_uid
|
||||
|
@ -128,16 +133,17 @@
|
|||
with_items:
|
||||
- /var/lib/openqa/share/factory/iso
|
||||
- /var/lib/openqa/share/factory/hdd
|
||||
- /var/lib/openqa/share/factory/hdd/fixed
|
||||
- /var/lib/openqa/share/factory/repo
|
||||
- /var/lib/openqa/share/factory/other
|
||||
|
||||
- name: Set up createhdds cron job
|
||||
copy: src=createhdds dest=/etc/cron.daily/createhdds owner=root group=root mode=0755
|
||||
template: src=createhdds.j2 dest=/etc/cron.daily/createhdds owner=root group=root mode=0755
|
||||
|
||||
- name: Check if any hard disk images need (re)building
|
||||
command: "/root/openqa_fedora_tools/tools/createhdds.py check"
|
||||
args:
|
||||
chdir: /var/lib/openqa/share/factory/hdd/
|
||||
chdir: "{{ openqa_fixed }}"
|
||||
register: diskcheck
|
||||
failed_when: "1 != 1"
|
||||
changed_when: "1 != 1"
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
#!/bin/sh
|
||||
|
||||
cd /var/lib/openqa/share/factory/hdd
|
||||
cd {{ openqa_fixed }}
|
||||
LIBGUESTFS_BACKEND=direct withlock /var/lock/createhdds.lock /root/openqa_fedora_tools/tools/createhdds.py all --clean
|
Loading…
Add table
Add a link
Reference in a new issue