feat: [#24] add provision command with cloud-init monitoring #6
This file contains hidden or 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
name: Testing | |
on: | |
push: | |
branches: [main, develop] | |
pull_request: | |
branches: [main, develop] | |
jobs: | |
lint: | |
runs-on: ubuntu-latest | |
name: Lint | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Install dependencies | |
run: | | |
sudo apt-get update | |
sudo apt-get install -y yamllint | |
sudo npm install -g markdownlint-cli | |
- name: Run markdown linting | |
run: markdownlint "**/*.md" | |
- name: Run yaml linting | |
run: yamllint -c .yamllint-ci.yml . | |
test: | |
runs-on: ubuntu-latest | |
name: Test | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Install Perl and dependencies | |
run: | | |
# Ubuntu already has Perl 5.34+ installed | |
perl -v | |
# Install cpanminus to ~/perl5/bin | |
curl -L https://cpanmin.us | perl - App::cpanminus | |
# Add perl5/bin to PATH for this step and subsequent ones | |
export PATH="$HOME/perl5/bin:$PATH" | |
echo "$HOME/perl5/bin" >> $GITHUB_PATH | |
# Setup local::lib | |
cpanm --local-lib=~/perl5 local::lib | |
eval $(perl -I ~/perl5/lib/perl5/ -Mlocal::lib) | |
# Install Carmel | |
cpanm Carmel | |
- name: Install project dependencies | |
run: | | |
eval $(perl -I ~/perl5/lib/perl5/ -Mlocal::lib) | |
carmel install | |
- name: Run tests | |
run: | | |
eval $(perl -I ~/perl5/lib/perl5/ -Mlocal::lib) | |
carmel exec -- prove -l t/ |