@@ -2,43 +2,145 @@ name: Verify Installation
2
2
3
3
on :
4
4
workflow_dispatch :
5
+ inputs :
6
+ install-registry :
7
+ required : true
8
+ description : ' Registry used for install tests, e.g. RubyGem, packagecloud'
9
+ type : choice
10
+ default : ' RubyGem'
11
+ options :
12
+ - RubyGem
13
+ - packagecloud
5
14
6
-
7
- env :
8
- SW_APM_SERVICE_KEY : ${{ secrets.SW_APM_SERVICE_KEY_PROD }}
9
- SW_APM_COLLECTOR : ${{ secrets.SW_APM_COLLECTOR_PROD}}
15
+ solarwinds-version :
16
+ required : true
17
+ description : ' Solarwinds apm version'
10
18
11
19
jobs :
12
- # --------------------------------------------------------------------
13
- # RUBY 3.1
14
- # --------------------------------------------------------------------
15
20
16
- ruby31_install_ubuntu_20 :
21
+ verify_install_amd64_test :
22
+ name : ruby - ${{ matrix.ruby_version }} - ${{ matrix.os }} amd64 - ${{ github.event.inputs.solarwinds-version }}
23
+ runs-on : ubuntu-latest
24
+
25
+ strategy :
26
+ fail-fast : false
27
+ matrix :
28
+ os : [ubuntu, alpine]
29
+ ruby_version : ['3.1.0', '2.7.5']
30
+ steps :
31
+ - uses : actions/checkout@v3
32
+
33
+ - name : Log in to the Container Registry
34
+ uses : docker/login-action@v2
35
+ with :
36
+ registry : ghcr.io
37
+ username : ${{ github.repository_owner }}
38
+ password : ${{ secrets.GITHUB_TOKEN }}
39
+
40
+ - run : docker pull --platform linux/amd64 ghcr.io/${{ github.repository }}/apm_ruby_${{ matrix.os }}:latest
41
+
42
+ - name : Run tests in container
43
+ run : |
44
+ sudo docker run \
45
+ --platform linux/amd64 \
46
+ -e SW_APM_SERVICE_KEY=${{ secrets.SW_APM_SERVICE_KEY_PROD }} \
47
+ -e SW_APM_COLLECTOR=${{ secrets.SW_APM_COLLECTOR_PROD }} \
48
+ -e SOLARWINDS_APM_VERSION=${{ github.event.inputs.solarwinds-version }} \
49
+ -e PACKAGECLOUD_TOKEN=${{ secrets.PACKAGECLOUD_TOKEN }} \
50
+ -e MODE=${{ github.event.inputs.install-registry }} \
51
+ -e RUBY_VERSION=${{ matrix.ruby_version }} \
52
+ -v $(pwd):/home \
53
+ --rm ghcr.io/${{ github.repository }}/apm_ruby_${{ matrix.os }}:nh-27837-b \
54
+ ./home/.github/workflows/scripts/_helper_run_install_tests.sh
55
+
56
+
57
+ verify_install_arm64_test :
58
+ name : ruby - ${{ matrix.ruby_version }} - ${{ matrix.os }} arm64 - ${{ github.event.inputs.solarwinds-version }}
17
59
runs-on : ubuntu-latest
18
- container :
19
- image : ruby:3.1.3-bullseye
60
+
61
+ strategy :
62
+ fail-fast : false
63
+ matrix :
64
+ os : [ubuntu, alpine]
65
+ ruby_version : ['3.1.0', '2.7.5']
66
+
20
67
steps :
21
- - uses : actions/checkout@v2
22
- - name : Setup and run install test
23
- working-directory : .github/workflows/
68
+ - uses : actions/checkout@v3
69
+ - uses : docker/setup-qemu-action@v2
70
+
71
+ - name : Log in to the Container Registry
72
+ uses : docker/login-action@v2
73
+ with :
74
+ registry : ghcr.io
75
+ username : ${{ github.repository_owner }}
76
+ password : ${{ secrets.GITHUB_TOKEN }}
77
+
78
+ - run : docker pull --platform linux/arm64 ghcr.io/${{ github.repository }}/apm_ruby_${{ matrix.os }}:latest
79
+
80
+ - name : Run tests in container using QEMU
24
81
run : |
25
- sleep 1
26
- gem install solarwinds_apm
27
- ruby ./scripts/test_install.rb
82
+ sudo docker run \
83
+ --platform linux/arm64 \
84
+ -e SW_APM_SERVICE_KEY=${{ secrets.SW_APM_SERVICE_KEY_PROD }} \
85
+ -e SW_APM_COLLECTOR=${{ secrets.SW_APM_COLLECTOR_PROD }} \
86
+ -e SOLARWINDS_APM_VERSION=${{ github.event.inputs.solarwinds-version }} \
87
+ -e PACKAGECLOUD_TOKEN=${{ secrets.PACKAGECLOUD_TOKEN }} \
88
+ -e MODE=${{ github.event.inputs.install-registry }} \
89
+ -e RUBY_VERSION=${{ matrix.ruby_version }} \
90
+ -v $(pwd):/home \
91
+ --rm ghcr.io/${{ github.repository }}/apm_ruby_${{ matrix.os }}:nh-27837-b \
92
+ ./home/.github/workflows/scripts/_helper_run_install_tests.sh
28
93
29
- ruby31_install_ubuntu_20_arm :
94
+ verify_install_ubi8_amd64_test :
95
+ name : ruby - ${{ matrix.ruby_version }} - ubi8 amd64 - ${{ github.event.inputs.solarwinds-version }}
30
96
runs-on : ubuntu-latest
31
- container :
32
- image : arm64v8/ruby:3.1.3-bullseye
97
+
98
+ strategy :
99
+ fail-fast : false
100
+ matrix :
101
+ ruby_version : [3.1.0, 2.7.5]
102
+
33
103
steps :
34
- - name : Set up QEMU
35
- uses : docker/setup-qemu-action@v2
104
+ - uses : actions/checkout@v3
105
+ - run : docker pull redhat/ubi8
106
+ - name : Run tests in ubi8 container
107
+ run : |
108
+ sudo docker run \
109
+ --platform linux/amd64 \
110
+ -e RUBY_VERSION=${{ matrix.ruby_version }} \
111
+ -e SW_APM_SERVICE_KEY=${{ secrets.SW_APM_SERVICE_KEY_PROD }} \
112
+ -e SW_APM_COLLECTOR=${{ secrets.SW_APM_COLLECTOR_PROD }} \
113
+ -e SOLARWINDS_APM_VERSION=${{ github.event.inputs.solarwinds-version }} \
114
+ -e PACKAGECLOUD_TOKEN=${{ secrets.PACKAGECLOUD_TOKEN }} \
115
+ -e MODE=${{ github.event.inputs.install-registry }} \
116
+ -v $(pwd):/home \
117
+ --rm redhat/ubi8 \
118
+ ./home/.github/workflows/scripts/_helper_run_install_tests.sh
36
119
37
- - uses : actions/checkout@v2
120
+ verify_install_ubi8_arm64_test :
121
+ name : ruby - ${{ matrix.ruby_version }} - ubi8 arm64 - ${{ github.event.inputs.solarwinds-version }}
122
+ runs-on : ubuntu-latest
123
+
124
+ strategy :
125
+ fail-fast : false
126
+ matrix :
127
+ ruby_version : [3.1.0, 2.7.5]
38
128
39
- - name : Setup and run install test
40
- working-directory : .github/workflows/
129
+ steps :
130
+ - uses : actions/checkout@v3
131
+ - uses : docker/setup-qemu-action@v2
132
+ - run : docker pull --platform linux/arm64 redhat/ubi8
133
+ - name : Run tests in ubi8 container using QEMU
41
134
run : |
42
- sleep 1
43
- gem install solarwinds_apm
44
- ruby ./scripts/test_install.rb
135
+ sudo docker run \
136
+ --platform linux/arm64 \
137
+ -e RUBY_VERSION=${{ matrix.ruby_version }} \
138
+ -e SW_APM_SERVICE_KEY=${{ secrets.SW_APM_SERVICE_KEY_PROD }} \
139
+ -e SW_APM_COLLECTOR=${{ secrets.SW_APM_COLLECTOR_PROD }} \
140
+ -e SOLARWINDS_APM_VERSION=${{ github.event.inputs.solarwinds-version }} \
141
+ -e PACKAGECLOUD_TOKEN=${{ secrets.PACKAGECLOUD_TOKEN }} \
142
+ -e MODE=${{ github.event.inputs.install-registry }} \
143
+ -v $(pwd):/home \
144
+ --rm redhat/ubi8 \
145
+ ./home/.github/workflows/scripts/_helper_run_install_tests.sh
146
+
0 commit comments