Skip to content

Commit

Permalink
Added job to run package manifests docker container and upload json f…
Browse files Browse the repository at this point in the history
…ile.
  • Loading branch information
ebelfarsi committed Jun 25, 2024
1 parent d6dffe0 commit df7a0e4
Showing 1 changed file with 32 additions and 0 deletions.
32 changes: 32 additions & 0 deletions .github/workflows/build-assets.yml
Original file line number Diff line number Diff line change
Expand Up @@ -743,3 +743,35 @@ jobs:
with:
name: windows-2022-logs
path: ./ECLIDE/build/**/*.log

run-package-manifest:
needs: [ preamble, build-docker ] # Ensure it runs after the necessary jobs
runs-on: ubuntu-22.04
steps:
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }} # Assuming you have stored the username in secrets
password: ${{ secrets.DOCKER_PASSWORD }}

- name: Pull Docker Image
run: docker pull ${{ github.repository_owner }}/package-manifest:latest

- name: Run Docker Container
run: docker run -d --name package-container -v ${{ github.workspace }}/app:/app ${{ github.repository_owner }}/package-manifest:latest

- name: Wait for Container to Complete
run: |
while [ $(docker inspect -f '{{.State.Running}}' package-container) = "true" ]; do
sleep 10
done
- name: Fetch Output from Container
run: docker cp package-container:/app/output.json ${{ github.workspace }}/app/output.json

- name: Upload output.json to Artifacts
uses: actions/upload-artifact@v2
with:
name: output-json
path: ${{ github.workspace }}/app/output.json

0 comments on commit df7a0e4

Please sign in to comment.