You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

34 lines
1.1 KiB

  1. on: ['pull_request']
  2. name: Build & Validate Image
  3. jobs:
  4. build:
  5. name: Build & Validate Image
  6. runs-on: self-hosted
  7. timeout-minutes: 2880
  8. env:
  9. working-directory: ./builder
  10. steps:
  11. - name: Checkout code
  12. uses: actions/checkout@v2
  13. - name: Build project
  14. id: builder
  15. working-directory: ${{ env.working-directory }}
  16. run: |
  17. docker rm -v pigen_work
  18. bash build-docker.sh
  19. echo ::set-output name=filename::$(ls deploy/*.tar.xz | xargs -n 1 basename)
  20. - name: Fix Permissions
  21. id: fix_perm_filename
  22. run: |
  23. chmod a+rw ${{ env.working-directory }}/deploy/${{ steps.builder.outputs.filename }}
  24. echo ${{ env.working-directory }}/deploy/${{ steps.builder.outputs.filename }}
  25. - uses: actions/upload-artifact@v1
  26. with:
  27. name: ${{ steps.builder.outputs.filename }}
  28. path: ${{ env.working-directory }}/deploy/${{ steps.builder.outputs.filename }}
  29. - name: Delete Image
  30. id: delete_image
  31. run: |
  32. rm ${{ env.working-directory }}/deploy/${{ steps.builder.outputs.filename }}