@@ -5,8 +5,8 @@ description: >
55 and uploads it to the Github registry
66
77inputs :
8- # python_version:
9- # required: true
8+ python_version :
9+ required : true
1010 SA_GH_USER_NAME :
1111 required : true
1212 SA_GH_USER_EMAIL :
4343 - name : Setup python
4444 uses : actions/setup-python@v4
4545 with :
46- python-version : ' 3.7 '
46+ python-version : ${{ inputs.python_version }}
4747
4848 - name : Create requirements file for pip
4949 shell : bash
@@ -114,20 +114,20 @@ runs:
114114 PrNumber : ${{ github.event.number }}
115115
116116 - name : Download THIRDPARTY
117- if : ' 3.7 ' == '3.7' && github.event_name != 'pull_request' && github.event_name != 'schedule'
117+ if : ${{ inputs.python_version }} == '3.7' && github.event_name != 'pull_request' && github.event_name != 'schedule'
118118 uses : actions/download-artifact@v3
119119 with :
120120 name : THIRDPARTY
121121
122122 - name : Download THIRDPARTY (Optional for PR and schedule)
123- if : ' 3.7 ' == '3.7' && github.event_name == 'pull_request' || github.event_name == 'schedule'
123+ if : ${{ inputs.python_version }} == '3.7' && github.event_name == 'pull_request' || github.event_name == 'schedule'
124124 continue-on-error : true
125125 uses : actions/download-artifact@v3
126126 with :
127127 name : THIRDPARTY
128128
129129 - name : Update Notices
130- if : ' 3.7 ' == '3.7'
130+ if : ${{ inputs.python_version }} == '3.7'
131131 shell : bash
132132 run : |
133133 cp -f THIRDPARTY package/THIRDPARTY || echo "THIRDPARTY file not found (allowed for PR and schedule)"
@@ -139,7 +139,7 @@ runs:
139139 version : ${{ steps.BuildVersion.outputs.VERSION }}
140140
141141 - name : Slim Package
142- if : always() && '3.7' == '3.7'
142+ if : always() && ${{ inputs.python_version }} == '3.7'
143143 id : slim
144144 uses : splunk/addonfactory-packaging-toolkit-action@v1
145145 with :
@@ -148,26 +148,26 @@ runs:
148148 - name : debug
149149 shell : bash
150150 run : |
151- echo "'3.7' "
151+ echo "${{ inputs.python_version }} "
152152 echo "${{ inputs.ucc_modinput_functional }}"
153153 echo "${{ github.event_name }}"
154154
155155 - name : Artifact OpenAPI
156- if : ' 3.7 ' == '3.7' && ${{ !cancelled() && inputs.ucc_modinput_functional == 'true' && inputs.modinput_functional == 'true' }}
156+ if : ${{ inputs.python_version }} == '3.7' && ${{ !cancelled() && inputs.ucc_modinput_functional == 'true' && inputs.modinput_functional == 'true' }}
157157 uses : actions/upload-artifact@v3
158158 with :
159159 name : artifact-openapi
160160 path : ${{ github.workspace }}/${{ steps.uccgen.outputs.OUTPUT }}/static/openapi.json
161161
162162 - name : Artifact Splunkbase
163- if : ${{ !cancelled() }} && '3.7' == '3.7'
163+ if : ${{ !cancelled() }} && ${{ inputs.python_version }} == '3.7'
164164 uses : actions/upload-artifact@v3
165165 with :
166166 name : package-splunkbase
167167 path : ${{ steps.slim.outputs.OUTPUT }}
168168
169169 - name : Upload build to S3
170- if : ' 3.7 ' == '3.7'
170+ if : ${{ inputs.python_version }} == '3.7'
171171 id : buildupload
172172 shell : bash
173173 env :
@@ -180,7 +180,7 @@ runs:
180180 aws s3 cp "${{ steps.slim.outputs.OUTPUT }}" s3://ta-production-artifacts/ta-apps/
181181
182182 - name : Artifact Splunk parts
183- if : ${{ !cancelled() }} && '3.7' == '3.7'
183+ if : ${{ !cancelled() }} && ${{ inputs.python_version }} == '3.7'
184184 uses : actions/upload-artifact@v3
185185 with :
186186 name : package-deployment
0 commit comments