Skip to content

Commit

Permalink
Add devcontainer for Codespaces
Browse files Browse the repository at this point in the history
  • Loading branch information
perlpunk committed Jun 4, 2024
1 parent a2cd372 commit b5f7cfc
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 0 deletions.
10 changes: 10 additions & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"name": "openQA Single Instance",
"image": "registry.opensuse.org/devel/openqa/containers15.5/openqa-single-instance",
"runArgs": [ "--privileged", "--device", "/dev/kvm", "--entrypoint", "bash" ],
"postCreateCommand": "chown root:kvm /dev/kvm",
"containerEnv": {
"VNCPORT_OFFSET": "100"
},
"postAttachCommand": "(/usr/share/openqa/script/openqa-bootstrap >/var/log/openqa-bootstrap.log 2>&1 &) ; echo \"Welcome to openqa-single-instance! Check the openQA logs with 'tail -f /var/log/openqa-bootstrap.log'. Wait for the Web UI to become available. Then you can clone a job with 'openqa-clone-job url-to-job'.\""
}
20 changes: 20 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,26 @@ Feel free to add issues in github or send pull requests.
If this is too much hassle for you feel free to provide incomplete pull
requests for consideration or create an issue with a code change proposal.

## Developing tests in a browser

If you only have a browser available, you can also develop tests with
[GitHub Codespaces](https://docs.github.com/en/codespaces).

On
[os-autoinst-distri-example](https://github.com/os-autoinst/os-autoinst-distri-example).
click on the "Code" button and select "Codespaces". Just click on the plus sign
to create a new Codespace. Or use
[this link](https://codespaces.new/os-autoinst/os-autoinst-distri-example?quickstart=1)
as a quickstart to resume existing instances or create new ones.

See [OpenQA in a browser](https://open.qa/docs/#_openqa_in_a_browser) for
documentation on how to use it.

You can then directly modify tests in VSCode and run
```
openqa-clone-job url-to-job CASEDIR=$PWD
```

### Local testing and CI environment

This repo is intended to be used with openQA as a learning example. The
Expand Down

0 comments on commit b5f7cfc

Please sign in to comment.