-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #19 from rails/test-ruby-feature
Create workflow for testing for the ruby feature
- Loading branch information
Showing
3 changed files
with
52 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
{ | ||
"image": "mcr.microsoft.com/devcontainers/base:1-bookworm", | ||
"features": { | ||
"ghcr.io/devcontainers/features/common-utils:2": { | ||
"installZsh": "true", | ||
"username": "vscode", | ||
"userUid": "1000", | ||
"userGid": "1000", | ||
"upgradePackages": "true" | ||
}, | ||
"ghcr.io/devcontainers/features/git:1": { | ||
"version": "latest", | ||
"ppa": "false" | ||
}, | ||
"./features/ruby": {} | ||
}, | ||
// Set `remoteUser` to `root` to connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root. | ||
"remoteUser": "vscode" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../../features |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
name: Test ruby feature | ||
|
||
on: | ||
push: | ||
|
||
jobs: | ||
build: | ||
name: Test ruby feature | ||
|
||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: read | ||
packages: write | ||
|
||
steps: | ||
- name: Checkout (GitHub) | ||
uses: actions/checkout@v3 | ||
|
||
- uses: docker/login-action@v2 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ github.repository_owner }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- name: Build and test devcontainer | ||
uses: devcontainers/[email protected] | ||
with: | ||
imageName: ghcr.io/rails/devcontainer/test-ruby-feature | ||
cacheFrom: ghcr.io/rails/devcontainer/test-ruby-feature | ||
subFolder: .github | ||
refFilterForPush: refs/heads/main | ||
runCmd: ruby -v || ( echo "Ruby is not installed."; exit 1 ) |