on: [push, pull_request]
name: Test
jobs:
smoke:
name: Smoke Test
runs-on: ubuntu-latest
services:
gitlab:
image: gitlab/gitlab-ee:latest
options: --shm-size 256m
ports:
- 80:80
- 443:443
steps:
- uses: actions/checkout@v4
- name: Start gitlab-cargo-shim
run: |
- name: Install dependencies
run: |
- name: Wait for GitLab to boot
run: timeout 20m bash -c 'until curl -s http://127.0.0.1/users/sign_in | grep csrf-token; do sleep 5; done'
- name: Create GitLab package
run: |
- name: Packaging example-lib
run: |
- name: Uploading example-lib to GitLab
run: |
- name: Creating SSH key to identify with gitlab-cargo-shim
run: |
- name: Fetching public keys from gitlab-cargo-shim and storing in known_hosts
run: |
- name: Write PAT to .config
run: |
- name: Building example-bin using example-lib from registry
run: |
- name: Collect docker logs on failure
if: failure()
uses: jwalton/gh-docker-logs@v2
with:
dest: './logs'
- name: Tar logs
if: failure()
run: tar cvzf ./logs.tgz ./logs
- name: Upload logs as artifacts
if: failure()
uses: actions/upload-artifact@master
with:
name: logs.tgz
path: ./logs.tgz