-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtest-commands.txt
111 lines (68 loc) · 4.84 KB
/
test-commands.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
oc edit deployment test-bigip-controller-1 -n kube-system
oc logs -f deploy/test-bigip-controller-1 -n kube-system |grep -i 'as3\|info\|fail\|error'
curl --resolve foo.com:443:172.16.3.30 https://foo.com/foo2 -v or -k
Run:
source ~/systest-common/systest-venv/bin/activate
Openshift Test:
git checkout as3_openshift
py.test -svvra --symbols ~/testenv_symbols/testenv_symbols.json --vars controller-pool-mode:cluster namespace-mode:all --include C2400352 --exclude incomplete no_regression no_openshift no_pool_mode_cluster no_namespace_all --autolog-outputdir ~/test_results --autolog-session bigip_ctlr_master_os_functest_v13_0_devel-master -- tests/bigip_ctlr
//Latest working
py.test -svvra --symbols ~/testenv_symbols/testenv_symbols.json --vars controller-pool-mode:cluster namespace-mode:all skip_teardown:false --include test_tcp_options_in_tcp_profile --exclude not_supported incomplete no_regression no_openshift no_pool_mode_cluster no_namespace_all --autolog-outputdir ~/test_results --autolog-session bigip_ctlr_master_os_functest_v13_0_devel-master -- tests/bigip_ctlr/
Code:
For insecure route: C2400352
For passthrought route: test_as3_passthrough_routes or oss-2
For reencrypt route: oss-3
oc delete serviceaccount run-as-anyid
oc delete serviceaccount bigip-controller -n kube-system
oc delete clusterrole bigip-controller-role
oc delete clusterrolebinding bigip-controllers -n kube-system
oc delete hostsubnet bigip
Cluster Mode test OSCP:
-----------------------
py.test -svvra --symbols ~/testenv_symbols/testenv_symbols.json --vars controller-pool-mode:cluster namespace-mode:all skip_teardown:false --include func --exclude not_supported incomplete no_regression no_openshift no_pool_mode_cluster no_namespace_all --autolog-outputdir ~/test_results --autolog-session bigip_ctlr_master_os_functest_v13_0_devel-master -- tests/bigip_ctlr/
Nodeport Mode OSCP:
-------------------
py.test -svvra --symbols ~/testenv_symbols/testenv_symbols.json --vars controller-pool-mode:nodeport namespace-mode:all skip_teardown:false --include func --exclude not_supported incomplete no_regression no_openshift no_pool_mode_nodeport no_namespace_all --autolog-outputdir ~/test_results --autolog-session bigip_ctlr_master_os_functest_v13_0_devel-master -- tests/bigip_ctlr/
Cluster Mode in k8s env
-----------------------
py.test -svvra --symbols ~/testenv_symbols/testenv_symbols.json --vars controller-pool-mode:cluster namespace-mode:all skip_teardown:false --include test_as3_edge_routes_Allow_policy test_as3_passthrough_routes_NonePolicy test_as3_reencrypt_routes_AllowPolicy test_as3_a_b_deployment_passthrough --exclude no_regression no_k8s no_pool_mode_cluster no_namespace_all --autolog-outputdir ~/test_results --autolog-session bigip_ctlr_master_os_functest_v13_0_devel-master -- tests/bigip_ctlr
sudo subscription-manager unregister
sudo subscription-manager clean
sudo subscription-manager register --username=amit49g --password=Redhat@123
sudo subscription-manager refresh
sudo subscription-manager attach –-pool=8a85f99b6ae5e42a016b0c8ffa100cb5
sudo subscription-manager attach –auto
sudo subscription-manager repos --enable='rhel-7-server-rpms' --enable='rhel-7-server-extras-rpms' --enable='rhel-7-server-ose-3.11-rpms' --enable='rhel-7-fast-datapath-rpms'
sudo subscription-manager attach --pool=$(sudo subscription-manager list --available --matches='Red Hat OpenShift Container Platform Broker/Master Infrastructure' | grep -B 10 Virtual | grep Pool | awk '{print $3}')
[root@localhost:Active:Standalone] config # tmsh create net vlan internal interfaces add { 1.1 }
[root@localhost:Active:Standalone] config # tmsh create net self selfip.internal address 172.16.1.5/24 allow-service all vlan internal
[root@localhost:Active:Standalone] config # tmsh create net vlan external interfaces add { 1.2 }
[root@localhost:Active:Standalone] config # tmsh create net self selfip.external address 172.16.3.16/24 allow-service all vlan external
[root@localhost:Active:Standalone] config # tmsh modify sys global-settings hostname bigip1
python virtual envirnment create
------------------
$deactivate
$cd system-common
$rm -rf systest-venv
$python3.8 -m venv systest-venv
$source ~/systest-common/systest-venv/bin/activate
//Create Virtual env and then install all packages on venv
$pip3 install -r conf/requirements.txt
If we get error: Peer's Certificate issuer is not recognized.
git config --global http.sslVerify false
BIGIP VPN Tunnel error fix:
---------------------------
ps alx | grep svpn
kill -9 <pid>
----------------------------------------------------------
Create service account per namespace. and add it to policy.
sa.yaml
------------------------
apiVersion: v1
kind: ServiceAccount
metadata:
name: run-as-anyid
namespace: n1
------------------------
$oc create ns n1
$oc adm policy add-scc-to-user anyuid -z run-as-anyid -n n1