Skip to content

Commit

Permalink
remove need for action script
Browse files Browse the repository at this point in the history
  • Loading branch information
ChenglimEar committed Nov 1, 2023
1 parent a6ce739 commit a43b445
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 5 deletions.
25 changes: 23 additions & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,27 @@ jobs:
GDRIVE_FOLDER: ${{ vars.GDRIVE_FOLDER }}
steps:
- uses: actions/checkout@v3
- run: pip install -r download/requirements.txt
- run: python download/main.py
- uses: dorny/paths-filter@v2
id: filter
with:
filters: |
devcontainer:
- '.devcontainer/**'
- name: Login to GitHub Container Registry
uses: docker/login-action@v1
with:
registry: ghcr.io
username: ${{github.actor}}
password: ${{secrets.GITHUB_TOKEN}}
- name: Build dev container
if: steps.filter.outputs.devcontainer == 'true'
run: |
docker build --no-cache --tag ghcr.io/caciviclab/disclosure-backend-static:latest -f ./.devcontainer/Dockerfile .
docker push ghcr.io/caciviclab/disclosure-backend-static:latest
- name: Test pull from gdrive
if: steps.filter.outputs.devcontainer != 'true'
uses: ./.github
with:
entrypoint: python
args: download/main.py

5 changes: 2 additions & 3 deletions .github/workflows/verify-gdrive.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,14 @@ jobs:
- name: Build dev container
if: steps.filter.outputs.devcontainer == 'true'
run: |
ls -al
docker build --no-cache --tag ghcr.io/caciviclab/disclosure-backend-static:latest -f ./.devcontainer/Dockerfile .
docker push ghcr.io/caciviclab/disclosure-backend-static:latest
- name: Test pull from gdrive
if: steps.filter.outputs.devcontainer != 'true'
uses: ./.github
with:
entrypoint: bash
args: ./.github/post-action-command.sh
entrypoint: python
args: test_pull_from_gdrive.py
- name: Archive pulled files
if: steps.filter.outputs.devcontainer != 'true'
uses: actions/upload-artifact@v3
Expand Down

0 comments on commit a43b445

Please sign in to comment.