Skip to content

Commit

Permalink
Address review feedback.
Browse files Browse the repository at this point in the history
  • Loading branch information
alliepiper committed Jun 10, 2024
1 parent 45ed25a commit d9ba9d7
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 13 deletions.
21 changes: 11 additions & 10 deletions .github/actions/workflow-run-job-linux/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,15 @@ description: "Run a job on a Linux runner."
# ```
# Error: JavaScript Actions in Alpine containers are only supported on x64 Linux runners. Detected Linux Arm64
# ```
#
# This action expects the repo to be already checked out in <workdir>/<repo-name>, e.g.
#
# - name: Checkout repo
# uses: actions/checkout@v4
# with:
# path: ${{github.event.repository.name}}
# persist-credentials: false


inputs:
id:
Expand Down Expand Up @@ -48,11 +57,6 @@ runs:
# Install script dependencies
apt update
apt install -y --no-install-recommends tree git
- name: Checkout repo
uses: actions/checkout@v4
with:
path: ${{github.event.repository.name}}
persist-credentials: false
- name: Add NVCC problem matcher
shell: bash --noprofile --norc -euo pipefail {0}
run: |
Expand All @@ -75,10 +79,6 @@ runs:
AWS_SESSION_TOKEN: "${{env.AWS_SESSION_TOKEN}}"
AWS_SECRET_ACCESS_KEY: "${{env.AWS_SECRET_ACCESS_KEY}}"
run: |
echo "[host] github.workspace: ${{github.workspace}}"
echo "[container] GITHUB_WORKSPACE: ${GITHUB_WORKSPACE:-}"
echo "[container] PWD: $(pwd)"
# Necessary because we're doing docker-outside-of-docker:
# Make a symlink in the container that matches the host's ${{github.workspace}}, so that way `$(pwd)`
# in `.devcontainer/launch.sh` constructs volume paths relative to the hosts's ${{github.workspace}}.
Expand Down Expand Up @@ -140,7 +140,7 @@ runs:
}
# Launch this container using the host's docker daemon
set -x
set -x # Print the launch.sh command-line to the log:
${{github.event.repository.name}}/.devcontainer/launch.sh \
--docker \
--cuda ${{inputs.cuda}} \
Expand All @@ -162,6 +162,7 @@ runs:
--volume "$(host_path "$RUNNER_TEMP")/.aws:/root/.aws" \
--volume "$(dirname "$(dirname "${{github.workspace}}")"):/__w" \
-- /ci.sh
set +x
- name: Prepare job artifacts
shell: bash --noprofile --norc -euo pipefail {0}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,10 @@ jobs:
- name: Checkout repo
uses: actions/checkout@v4
with:
path: ${{github.event.repository.name}}
persist-credentials: false
- name: Run job
uses: ./.github/actions/workflow-run-job-linux
uses: ./${{github.event.repository.name}}/.github/actions/workflow-run-job-linux
with:
id: ${{ matrix.id }}
command: ${{ matrix.command }}
Expand Down
6 changes: 4 additions & 2 deletions .github/workflows/workflow-dispatch-two-stage-linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,10 @@ jobs:
- name: Checkout repo
uses: actions/checkout@v4
with:
path: ${{github.event.repository.name}}
persist-credentials: false
- name: Run job
uses: ./.github/actions/workflow-run-job-linux
uses: ./${{github.event.repository.name}}/.github/actions/workflow-run-job-linux
with:
id: ${{ fromJSON(inputs.producers)[0].id }}
command: ${{ fromJSON(inputs.producers)[0].command }}
Expand Down Expand Up @@ -63,9 +64,10 @@ jobs:
- name: Checkout repo
uses: actions/checkout@v4
with:
path: ${{github.event.repository.name}}
persist-credentials: false
- name: Run job
uses: ./.github/actions/workflow-run-job-linux
uses: ./${{github.event.repository.name}}/.github/actions/workflow-run-job-linux
with:
id: ${{ matrix.id }}
command: ${{ matrix.command }}
Expand Down

0 comments on commit d9ba9d7

Please sign in to comment.