copr-builders: ibmcloud token filename on one place

This commit is contained in:
Pavel Raiskup 2022-01-12 14:14:27 +01:00
parent fb905b9481
commit 88c881048d
2 changed files with 5 additions and 3 deletions

View file

@ -33,7 +33,9 @@
become: yes
become_user: postgres
- set_fact: provision_directory=/var/lib/resallocserver/provision
- set_fact:
provision_directory: /var/lib/resallocserver/provision
ibmcloud_token_file: /var/lib/resallocserver/.ibm-cloud-token
tags:
- provision_config
@ -149,7 +151,7 @@
- name: install IBM Cloud token file
copy:
content: "IBMCLOUD_API_KEY={{ copr_cloud_ibm_token | default('unset') }}"
dest: /var/lib/resallocserver/.ibm-cloud-token
dest: "{{ ibmcloud_token_file }}"
owner: resalloc
group: resalloc
mode: 0600

View file

@ -16,7 +16,7 @@ from ibm_vpc import VpcV1
from ibm_cloud_sdk_core.authenticators import IAMAuthenticator
DEFAULT_PLAYBOOK = "{{ provision_directory }}/libvirt-provision.yml"
DEFAULT_TOKEN_FILE = "/var/lib/resallocserver/.ibm-cloud-token"
DEFAULT_TOKEN_FILE = "{{ ibmcloud_token_file }}"
DEFAULT_IMAGE = "{{ copr_builder_images.ibm_cloud.s390x }}"
SUBNET_ID = "02f7-98674f68-aae1-4ea1-a889-5a0b7a07f4b8"