diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 000000000..ca79ca5b4 --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,6 @@ +version: 2 +updates: + - package-ecosystem: github-actions + directory: / + schedule: + interval: weekly diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 4c15ae642..19d290919 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -1,4 +1,4 @@ -name: Main workflow +name: Builds, tests & co on: pull_request: @@ -7,6 +7,8 @@ on: # Prime the caches every Monday - cron: 0 1 * * MON +permissions: read-all + jobs: build: strategy: @@ -14,22 +16,20 @@ jobs: matrix: os: - macos-latest - - windows-latest + - ubuntu-latest ocaml-compiler: - - 4.13.x + - 5 + - 4 runs-on: ${{ matrix.os }} steps: - - name: Checkout code - uses: actions/checkout@v2 + - name: Checkout tree + uses: actions/checkout@v4 - - name: Use OCaml ${{ matrix.ocaml-compiler }} - uses: ocaml/setup-ocaml@v2 + - name: Set-up OCaml + uses: ocaml/setup-ocaml@v3 with: - opam-repositories: | - opam-repository-mingw: https://github.com/ocaml-opam/opam-repository-mingw.git#sunset - default: https://github.com/ocaml/opam-repository.git ocaml-compiler: ${{ matrix.ocaml-compiler }} - run: opam install . --deps-only --with-test @@ -37,3 +37,32 @@ jobs: - run: opam exec -- dune build - run: opam exec -- dune runtest + + unikernel-example: + strategy: + fail-fast: false + matrix: + mode: + - qubes + - unix + - virtio + + defaults: + run: + working-directory: examples/unikernel + + runs-on: ubuntu-latest + + steps: + - name: Checkout tree + uses: actions/checkout@v4 + + - name: Set-up OCaml + uses: ocaml/setup-ocaml@v3 + with: + ocaml-compiler: 4 + + - run: opam install mirage + - run: opam exec -- mirage configure -t ${{ matrix.mode }} + - run: opam exec -- make depend + - run: opam exec -- make diff --git a/.travis-ci.sh b/.travis-ci.sh deleted file mode 100755 index 82169079f..000000000 --- a/.travis-ci.sh +++ /dev/null @@ -1,11 +0,0 @@ -# build the examples -export OPAMYES=1 -eval `opam config env` - -cd examples/unikernel -git log --oneline |head -5 - -opam install mirage -mirage configure -t $MIRAGE_MODE -make depend -make diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 788cf0dec..000000000 --- a/.travis.yml +++ /dev/null @@ -1,12 +0,0 @@ -language: c -install: wget https://raw.githubusercontent.com/ocaml/ocaml-ci-scripts/master/.travis-docker.sh -script: bash -ex .travis-docker.sh -sudo: false -env: - global: - - POST_INSTALL_HOOK="sh ./.travis-ci.sh" - - PACKAGE=tcpip - matrix: - - DISTRO=alpine OCAML_VERSION=4.09 EXTRA_ENV="MIRAGE_MODE=unix" - - DISTRO=alpine OCAML_VERSION=4.10 EXTRA_ENV="MIRAGE_MODE=qubes" - - DISTRO=alpine OCAML_VERSION=4.10 EXTRA_ENV="MIRAGE_MODE=virtio"