File tree Expand file tree Collapse file tree 4 files changed +47
-2
lines changed Expand file tree Collapse file tree 4 files changed +47
-2
lines changed Original file line number Diff line number Diff line change 91
91
ANSIBLE_FORCE_COLOR : True
92
92
TEST_USER_PASSWORD : ${{ secrets.TEST_USER_PASSWORD }}
93
93
94
+ - name : Confirm Open Ondemand is up (via SOCKS proxy)
95
+ run : |
96
+ . venv/bin/activate
97
+ . environments/smslabs/activate
98
+
99
+ # load ansible variables into shell:
100
+ ansible-playbook ansible/ci/output_vars.yml \
101
+ -e output_vars_hosts=openondemand \
102
+ -e output_vars_path=$APPLIANCES_ENVIRONMENT_ROOT/vars.txt \
103
+ -e output_vars_items=bastion_ip,bastion_user,openondemand_servername
104
+ source $APPLIANCES_ENVIRONMENT_ROOT/vars.txt
105
+
106
+ # setup ssh proxying:
107
+ sudo apt-get --yes install proxychains
108
+ echo proxychains installed
109
+ ssh -v -fN -D 9050 ${bastion_user}@${bastion_ip}
110
+ echo port 9050 forwarded
111
+
112
+ # check OOD server returns 200:
113
+ statuscode=$(proxychains wget \
114
+ --quiet \
115
+ --spider \
116
+ --server-response \
117
+ --no-check-certificate \
118
+ --http-user=testuser \
119
+ --http-password=${TEST_USER_PASSWORD} https://${openondemand_servername} \
120
+ 2>&1)
121
+ (echo $statuscode | grep "200 OK") || (echo $statuscode && exit 1)
122
+ env :
123
+ TEST_USER_PASSWORD : ${{ secrets.TEST_USER_PASSWORD }}
124
+
94
125
- name : Test reimage of login and compute nodes
95
126
run : |
96
127
. venv/bin/activate
Original file line number Diff line number Diff line change
1
+ # Output specific hostvars to a file in a form which can be sourced by bash
2
+ # NB: obviously the keys and values for the hostvars need to be suitable bash variables
3
+ - hosts : " {{ output_vars_hosts }}"
4
+ gather_facts : no
5
+ tasks :
6
+ - copy :
7
+ dest : " {{ output_vars_path }}"
8
+ content : |
9
+ {% for item in output_vars_items.split(',') %}
10
+ export {{output_vars_prefix | default('') }}{{ item }}={{ lookup('vars', item) }}
11
+ {% endfor %}
12
+ delegate_to : localhost
Original file line number Diff line number Diff line change 1
- ansible_ssh_common_args :
' -o ProxyCommand="ssh [email protected] -W %h:%p"'
1
+ bastion_user : slurm-app-ci
2
+ bastion_ip : 185.45.78.150
3
+ ansible_ssh_common_args : ' -o ProxyCommand="ssh {{ bastion_user }}@{{ bastion_ip }} -W %h:%p"'
Original file line number Diff line number Diff line change @@ -28,7 +28,7 @@ resource "openstack_compute_instance_v2" "login" {
28
28
flavor_name = each. value . flavor
29
29
key_pair = var. key_pair
30
30
config_drive = true
31
- security_groups = [" default" , " ssh" ]
31
+ security_groups = [" default" , " ssh" , " HTTPS " ]
32
32
33
33
network {
34
34
uuid = data. openstack_networking_subnet_v2 . cluster_subnet . network_id
You can’t perform that action at this time.
0 commit comments