1*** Settings ***
2Library           Collections
3Library           String
4Library           RequestsLibrary.RequestsKeywords
5Library           OperatingSystem
6Variables         ../data/variables.py
7
8*** Variables ***
9
10# By default power, support x86 as well.
11${PLATFORM_ARCH_TYPE}             power
12
13# FFDC Redfish OEM path /<oem>/v1/
14${OEM_REDFISH_PATH}               ${EMPTY}
15
16# Transition REST vs Redfish ONLY temporary changes for stagging
17# automation infrastructure change and for continuity.
18${REDFISH_SUPPORT_TRANS_STATE}    ${0}
19
20# By default Delete all Redfish session per boot run.
21${REDFISH_DELETE_SESSIONS}        ${1}
22
23${OPENBMC_MODEL}  ${EMPTY}
24${OPENBMC_HOST}   ${EMPTY}
25${DBUS_PREFIX}    ${EMPTY}
26${PORT}           ${EMPTY}
27# AUTH_SUFFIX here is derived from variables.py
28${AUTH_URI}       https://${OPENBMC_HOST}${AUTH_SUFFIX}
29${OPENBMC_USERNAME}    root
30${OPENBMC_PASSWORD}    0penBmc
31${REST_USERNAME}       root
32${REST_PASSWORD}       0penBmc
33${OPENBMC_ADMIN_PASSWORD}  0penBmc
34${SERVICE_USER_PASSWORD}   0penBmc
35
36${CHASSIS_ID}  chassis
37${COMPONENT_NAME_OF_POWER_SUPPLY}  powersupply
38
39# MTLS_ENABLED indicates whether mTLS is enabled.
40${MTLS_ENABLED}        False
41# Valid mTLS certificate for authentication.
42${VALID_CERT}          ${EMPTY}
43# Path of mTLS certificates directory.
44${CERT_DIR_PATH}       ${EMPTY}
45
46${IPMI_PASSWORD}       0penBmc
47${MACHINE_TYPE}    palmetto
48${DBUS_POLL_INTERVAL}      15s
49${OPENBMC_REBOOT_TIMEOUT}   ${10}
50# IPMI_COMMAND here is set to "External" by default. User
51# can override to "Dbus" from command line.
52${IPMI_COMMAND}    External
53# IPMI chipher default.
54${IPMI_CIPHER_LEVEL}  ${17}
55# IPMI timeout default.
56${IPMI_TIMEOUT}       ${3}
57
58# Log default path for IPMI SOL.
59${IPMI_SOL_LOG_FILE}    ${EXECDIR}${/}logs${/}sol_${OPENBMC_HOST}
60
61# PDU related parameters
62${PDU_TYPE}         ${EMPTY}
63${PDU_IP}           ${EMPTY}
64${PDU_USERNAME}     ${EMPTY}
65${PDU_PASSWORD}     ${EMPTY}
66${PDU_SLOT_NO}      ${EMPTY}
67
68# User define input SSH and HTTPS related parameters
69${SSH_PORT}         22
70${HTTPS_PORT}       443
71${IPMI_PORT}        623
72${HOST_SOL_PORT}    2200
73${OPENBMC_SERIAL_HOST}      ${EMPTY}
74${OPENBMC_SERIAL_PORT}      ${EMPTY}
75
76# OS related parameters.
77${OS_HOST}          ${EMPTY}
78${OS_USERNAME}      ${EMPTY}
79${OS_PASSWORD}      ${EMPTY}
80${OS_WAIT_TIMEOUT}  ${15*60}
81
82# Networking related parameters
83${NETWORK_PORT}            80
84${PACKET_TYPE}             tcp
85${ICMP_PACKETS}            icmp
86${NETWORK_RETRY_TIME}      6
87${NETWORK_TIMEOUT}         18
88${ICMP_TIMESTAMP_REQUEST}  13
89${ICMP_ECHO_REQUEST}       8
90${CHANNEL_NUMBER}          1
91${TCP_PACKETS}             tcp
92${ICMP_NETMASK_REQUEST}    17
93${REDFISH_INTERFACE}       443
94${SYN_PACKETS}             SYN
95${RESET_PACKETS}           RST
96${FIN_PACKETS}             FIN
97${SYN_ACK_RESET}           SAR
98${ALL_FLAGS}               ALL
99# Used to set BMC static IPv4 configuration.
100${STATIC_IP}            10.10.10.10
101${NETMASK}              255.255.255.0
102${GATEWAY}              10.10.10.10
103
104# BMC debug tarball parameter
105${DEBUG_TARBALL_PATH}  ${EMPTY}
106
107# Upload Image parameters
108${TFTP_SERVER}                  ${EMPTY}
109${PNOR_TFTP_FILE_NAME}          ${EMPTY}
110${BMC_TFTP_FILE_NAME}           ${EMPTY}
111${IMAGE_FILE_PATH}              ${EMPTY}
112${ALTERNATE_IMAGE_FILE_PATH}    ${EMPTY}
113${PNOR_IMAGE_FILE_PATH}         ${EMPTY}
114${BMC_IMAGE_FILE_PATH}          ${EMPTY}
115${BAD_IMAGES_DIR_PATH}          ${EMPTY}
116${SKIP_UPDATE_IF_ACTIVE}        false
117
118# Parameters for doing N-1 and N+1 code updates.
119${N_MINUS_ONE_IMAGE_FILE_PATH}    ${EMPTY}
120${N_PLUS_ONE_IMAGE_FILE_PATH}     ${EMPTY}
121
122# The caller must set this to the string "true" in order to delete images. The
123# code is picky.
124${DELETE_OLD_PNOR_IMAGES}   false
125${DELETE_OLD_GUARD_FILE}    false
126
127# Caller can specify a value for LAST_KNOWN_GOOD_VERSION to indicate that if
128# the machine already has that version on it, the update should be skipped.
129${LAST_KNOWN_GOOD_VERSION}  ${EMPTY}
130
131# By default field mode is disabled.
132${FIELD_MODE}               ${False}
133
134# LDAP related variables.
135${LDAP_BASE_DN}             ${EMPTY}
136${LDAP_BIND_DN}             ${EMPTY}
137${LDAP_SERVER_HOST}         ${EMPTY}
138${LDAP_SECURE_MODE}         ${EMPTY}
139${LDAP_BIND_DN_PASSWORD}    ${EMPTY}
140${LDAP_SEARCH_SCOPE}        ${EMPTY}
141${LDAP_TYPE}                ${EMPTY}
142${LDAP_USER}                ${EMPTY}
143${LDAP_USER_PASSWORD}       ${EMPTY}
144
145# General tool variables
146# FFDC_DEFAULT == 1; use Default FFDC methods
147${FFDC_DEFAULT}            ${1}
148
149*** Keywords ***
150Get Inventory Schema
151    [Documentation]  Get inventory schema.
152    [Arguments]    ${machine}
153    [Return]    &{INVENTORY}[${machine}]
154
155Get Inventory Items Schema
156    [Documentation]  Get inventory items schema.
157    [Arguments]    ${machine}
158    [Return]    &{INVENTORY_ITEMS}[${machine}]
159
160Get Sensor Schema
161    [Documentation]  Get sensors schema.
162    [Arguments]    ${machine}
163    [Return]    &{SENSORS}[${machine}]
164