use inky as user & cleanup
This commit is contained in:
		
							
								
								
									
										33
									
								
								.github/workflows/tests.yml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										33
									
								
								.github/workflows/tests.yml
									
									
									
									
										vendored
									
									
								
							| @@ -51,17 +51,6 @@ jobs: | |||||||
|           git commit -m "update docs [bot]" |           git commit -m "update docs [bot]" | ||||||
|           git push |           git push | ||||||
|  |  | ||||||
|       - name: Create artifact |  | ||||||
|         run: | |  | ||||||
|           mkdir artefacts |  | ||||||
|           tar -czf artefacts/workspace.tar.gz --exclude=./artefacts . |  | ||||||
|  |  | ||||||
|       - name: Save Workspace Archive |  | ||||||
|         uses: actions/upload-artifact@v2 |  | ||||||
|         with: |  | ||||||
|           name: workspace |  | ||||||
|           path: artefacts/workspace.tar.gz |  | ||||||
|  |  | ||||||
|   test-on-arm: |   test-on-arm: | ||||||
|     name: Run Tests on Raspberry Pi OS |     name: Run Tests on Raspberry Pi OS | ||||||
|     needs: update-docs |     needs: update-docs | ||||||
| @@ -70,15 +59,6 @@ jobs: | |||||||
|       contents: write |       contents: write | ||||||
|  |  | ||||||
|     steps: |     steps: | ||||||
|       - name: Restore Workspace |  | ||||||
|         uses: actions/download-artifact@v2 |  | ||||||
|         with: |  | ||||||
|           name: workspace |  | ||||||
|  |  | ||||||
|       - name: Extract Workspace Archive |  | ||||||
|         run: | |  | ||||||
|           tar -xzf workspace.tar.gz |  | ||||||
|  |  | ||||||
|       - name: Run Tests on Raspberry Pi OS |       - name: Run Tests on Raspberry Pi OS | ||||||
|         uses: pguyot/arm-runner-action@v2 |         uses: pguyot/arm-runner-action@v2 | ||||||
|         id: build_image |         id: build_image | ||||||
| @@ -92,15 +72,24 @@ jobs: | |||||||
|           base_image: https://downloads.raspberrypi.org/raspios_lite_armhf/images/raspios_lite_armhf-2023-05-03/2023-05-03-raspios-bullseye-armhf-lite.img.xz |           base_image: https://downloads.raspberrypi.org/raspios_lite_armhf/images/raspios_lite_armhf-2023-05-03/2023-05-03-raspios-bullseye-armhf-lite.img.xz | ||||||
|           image_additional_mb: 1500 # enlarge free space to 1.5 GB |           image_additional_mb: 1500 # enlarge free space to 1.5 GB | ||||||
|           optimize_image: true |           optimize_image: true | ||||||
|           user: inky |  | ||||||
|           commands: | |           commands: | | ||||||
|             sudo adduser inky |             sudo adduser inky | ||||||
|             sudo usermod -a -G adm,dialout,cdrom,sudo,audio,video,plugdev,games,users,input,netdev,gpio,i2c,spi inky |             sudo usermod -a -G adm,dialout,cdrom,sudo,audio,video,plugdev,games,users,input,netdev,gpio,i2c,spi inky | ||||||
|  |             su - inky | ||||||
|             sudo apt-get update -y |             sudo apt-get update -y | ||||||
|             sudo apt-get install -y python3-pip |             sudo apt-get install -y python3-pip | ||||||
|             sudo apt-get install zlib1g libjpeg-dev libatlas-base-dev rustc libopenjp2-7 python3-dev scons libssl-dev python3-venv python3-pip git libfreetype6-dev -y |             sudo apt-get install zlib1g libjpeg-dev libatlas-base-dev rustc libopenjp2-7 python3-dev scons libssl-dev python3-venv python3-pip git libfreetype6-dev -y | ||||||
|  |             cd ~/home/$USER | ||||||
|  |              | ||||||
|  |       - name: Clone Inkycal repo | ||||||
|  |         uses: actions/checkout@v3 | ||||||
|  |         with: | ||||||
|  |           ref: main | ||||||
|  |            | ||||||
|  |       - name: install requirements and run tests | ||||||
|  |         run: | | ||||||
|           ls |           ls | ||||||
|             cd /Inkycal |           cd ~/home/$USER/Inkycal | ||||||
|           . venv/bin/activate |           . venv/bin/activate | ||||||
|           python -m pip install --upgrade pip |           python -m pip install --upgrade pip | ||||||
|           pip install wheel |           pip install wheel | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user