Compare commits
8 commits
Author | SHA1 | Date | |
---|---|---|---|
|
741fbbd97f | ||
|
c85c4a897b | ||
|
2217d552c1 | ||
|
6e7adc330f | ||
|
20ee57f0c2 | ||
|
e294b9b1a3 | ||
|
95ba7f39c1 | ||
|
5dcdc28356 |
5 changed files with 504 additions and 123 deletions
212
.forgejo/README.md
Normal file
212
.forgejo/README.md
Normal file
|
@ -0,0 +1,212 @@
|
|||
# Forgejo Actions Configuration
|
||||
|
||||
This directory contains Forgejo Actions workflows for the Baktainer project. Forgejo Actions provides Continuous Integration similar to GitHub Actions but runs on Forgejo instances.
|
||||
|
||||
## Directory Structure
|
||||
|
||||
```
|
||||
.forgejo/
|
||||
├── workflows/
|
||||
│ └── ci.yml # Complete CI/CD pipeline
|
||||
└── README.md # This file
|
||||
```
|
||||
|
||||
## Workflow
|
||||
|
||||
### `ci.yml` - Complete CI/CD Pipeline
|
||||
- **Triggers**:
|
||||
- Push to main branch → Test + Build + Deploy
|
||||
- Version tags (v*.*.*) → Test + Build + Deploy with version tag
|
||||
- Pull requests → Test only
|
||||
- **Jobs**: Test → Build → Notify
|
||||
- **Container**: Ruby 3.3 Alpine (with auto-detection)
|
||||
- **Features**:
|
||||
- **Test Job**: Installs dependencies, runs RSpec tests
|
||||
- **Build Job**: Builds Docker image, pushes to Docker Hub as `:latest` and `:version` (for tags)
|
||||
- **Notify Job**: Reports pipeline status
|
||||
- **Pure Shell Commands**: No GitHub Actions dependencies for maximum compatibility
|
||||
- **Auto-Detection**: Supports multiple package managers (apk, apt-get, yum, dnf)
|
||||
- **Robust**: Manual git cloning and Docker operations work with any Forgejo runner
|
||||
|
||||
## Key Differences from GitHub Actions
|
||||
|
||||
### 1. Directory Location
|
||||
- **GitHub**: `.github/workflows/`
|
||||
- **Forgejo**: `.forgejo/workflows/`
|
||||
|
||||
### 2. Runner Types
|
||||
- Uses `runs-on: docker` for containerized jobs
|
||||
- Can specify custom container images with `container:`
|
||||
|
||||
### 3. Action Compatibility
|
||||
- Most GitHub Actions work with Forgejo Actions
|
||||
- Actions are sourced from configured action repositories
|
||||
- Uses same syntax for `actions/checkout@v4`, `docker/build-push-action@v5`, etc.
|
||||
|
||||
### 4. Environment Variables
|
||||
- Same `${{ github.* }}` variables available
|
||||
- Same secret management with `${{ secrets.* }}`
|
||||
|
||||
## Required Secrets
|
||||
|
||||
Configure these secrets in your Forgejo repository settings (`/{owner}/{repository}/settings` → Repository → Secrets):
|
||||
|
||||
| Secret | Description | Example | Required |
|
||||
|--------|-------------|---------|----------|
|
||||
| `DOCKER_USERNAME` | Docker Hub username | `jamez001` | ✅ Yes |
|
||||
| `DOCKER_PASSWORD` | Docker Hub password or token | `dckr_pat_...` | ✅ Yes |
|
||||
| `DOCKER_IMAGE_NAME` | Docker image name | `jamez001/baktainer` | ✅ Yes |
|
||||
|
||||
**Important**: All three secrets must be configured for the workflow to succeed. Missing secrets will cause the build to fail with clear error messages.
|
||||
|
||||
## Configuration Requirements
|
||||
|
||||
### 1. Enable Repository Actions
|
||||
1. Go to `/{owner}/{repository}/settings`
|
||||
2. Click on "Repository" tab
|
||||
3. Check "Enable Repository Actions"
|
||||
|
||||
### 2. Forgejo Runner Setup
|
||||
- Forgejo Actions requires a separate Forgejo Runner
|
||||
- Runner must be configured by the Forgejo administrator
|
||||
- Runner supports Docker, LXC, or host-based execution
|
||||
|
||||
### 3. Action Repository Configuration
|
||||
- Actions are sourced from configured repositories
|
||||
- Default actions available at https://data.forgejo.org
|
||||
- Administrator can configure custom action sources
|
||||
|
||||
## Workflow Features
|
||||
|
||||
### Testing
|
||||
- **Ruby 3.3** with Alpine Linux
|
||||
- **RSpec** test suite with progress format
|
||||
- **Automatic dependency installation** with package manager detection
|
||||
|
||||
### Building
|
||||
- **Docker builds** from Alpine Ruby base
|
||||
- **Automatic tagging** with `:latest` and version tags (`:v1.2.3`)
|
||||
- **Docker Hub integration** with secure authentication
|
||||
- **Build status reporting**
|
||||
|
||||
### Compatibility
|
||||
- **Pure shell commands** for maximum Forgejo runner compatibility
|
||||
- **Package manager auto-detection** (apk, apt-get, yum, dnf)
|
||||
- **No external action dependencies**
|
||||
|
||||
## Usage Examples
|
||||
|
||||
### Manual Workflow Trigger
|
||||
```bash
|
||||
# Push to main (triggers full CI/CD: test → build → deploy)
|
||||
git push origin main
|
||||
|
||||
# Create and push version tag (triggers test → build → deploy with version tag)
|
||||
git tag v0.1.1
|
||||
git push origin v0.1.1
|
||||
|
||||
# Create pull request (triggers test only)
|
||||
git push origin feature-branch
|
||||
# Then create PR in Forgejo UI
|
||||
```
|
||||
|
||||
### Monitoring Workflow Status
|
||||
1. Navigate to repository in Forgejo
|
||||
2. Click on "Actions" tab
|
||||
3. View workflow runs and logs
|
||||
4. Check artifact downloads
|
||||
|
||||
## Troubleshooting
|
||||
|
||||
### Common Issues
|
||||
|
||||
1. **Package manager not found / Node.js executable not found error**
|
||||
```
|
||||
/var/run/act/workflow/0: line 2: apk: command not found
|
||||
OCI runtime exec failed: exec failed: unable to start container process:
|
||||
exec: "node": executable file not found in $PATH: unknown
|
||||
```
|
||||
**Solutions**:
|
||||
- **Current workflow uses pure shell commands** - no GitHub Actions dependencies
|
||||
- **Auto-detects package manager** (apk, apt-get, yum, dnf) for maximum compatibility
|
||||
- **If still experiencing issues**: Check your Forgejo runner configuration and container image support
|
||||
|
||||
2. **Docker push reference format error**
|
||||
```
|
||||
Error parsing reference: ":latest" is not a valid repository/tag: invalid reference format
|
||||
```
|
||||
**Solutions**:
|
||||
- **Missing secret**: Configure `DOCKER_IMAGE_NAME` secret in repository settings
|
||||
- **Example value**: `jamez001/baktainer` (your Docker Hub username/repository)
|
||||
- **Path**: Go to `/{owner}/{repository}/settings` → Repository → Secrets
|
||||
- **Verify**: All three Docker secrets must be configured (USERNAME, PASSWORD, IMAGE_NAME)
|
||||
|
||||
3. **Working directory not found error**
|
||||
```
|
||||
OCI runtime exec failed: exec failed: unable to start container process:
|
||||
chdir to cwd ("/workspace/james/baktainer/./app") set in config.json failed:
|
||||
no such file or directory: unknown
|
||||
```
|
||||
**Solutions**:
|
||||
- **Fixed**: Workflow uses explicit `cd app` commands instead of `working-directory` defaults
|
||||
- The error occurred because `working-directory` was set before repository checkout
|
||||
- Repository must be cloned before changing to subdirectories
|
||||
|
||||
4. **Actions not running**
|
||||
- Check if Repository Actions are enabled
|
||||
- Verify Forgejo Runner is installed and running
|
||||
- Check workflow file syntax
|
||||
|
||||
3. **Docker build failures**
|
||||
- Verify Docker Hub credentials in secrets
|
||||
- Check Dockerfile syntax
|
||||
- Ensure runner has Docker access
|
||||
|
||||
5. **Test failures**
|
||||
- Check Ruby version compatibility
|
||||
- Verify system dependencies in Alpine
|
||||
- Review test output in workflow logs
|
||||
|
||||
6. **GitHub Actions compatibility**
|
||||
- **Not applicable**: Current workflow uses only shell commands
|
||||
- **No external actions**: Maximum compatibility with any Forgejo runner
|
||||
|
||||
### Debugging Steps
|
||||
|
||||
1. **Check workflow syntax**:
|
||||
```bash
|
||||
# Validate YAML syntax
|
||||
yamllint .forgejo/workflows/ci.yml
|
||||
```
|
||||
|
||||
2. **Test locally**:
|
||||
```bash
|
||||
# Run tests in similar environment
|
||||
docker run --rm -v $(pwd):/app -w /app ruby:3.3-alpine sh -c \
|
||||
"apk add --no-cache build-base libffi-dev linux-headers postgresql-dev git && \
|
||||
cd app && bundle install && bundle exec rspec"
|
||||
```
|
||||
|
||||
3. **Check logs**:
|
||||
- View detailed logs in Forgejo Actions UI
|
||||
- Check runner logs on server
|
||||
- Verify secret configuration
|
||||
|
||||
## Migration from GitHub Actions
|
||||
|
||||
This workflow is designed to be compatible with the existing GitHub Actions in `.github/workflows/`. Key adaptations made:
|
||||
|
||||
1. **Pure shell commands**: No external action dependencies for maximum compatibility
|
||||
2. **Runner specification**: Uses `docker` with Ruby 3.3 Alpine container
|
||||
3. **Package manager detection**: Auto-detects apk, apt-get, yum, or dnf
|
||||
4. **Manual operations**: Git clone and Docker commands work with any runner setup
|
||||
|
||||
Both GitHub Actions and Forgejo Actions can coexist in the same repository, allowing for gradual migration or dual CI/CD setup.
|
||||
|
||||
## Simplified Design
|
||||
|
||||
This single workflow replaces multiple complex workflows with one simple, reliable pipeline that:
|
||||
- **Tests** your Ruby application with RSpec
|
||||
- **Builds** a Docker image
|
||||
- **Deploys** by pushing to Docker Hub with proper tagging
|
||||
- **Works** with any Forgejo runner configuration
|
150
.forgejo/workflows/ci.yml
Normal file
150
.forgejo/workflows/ci.yml
Normal file
|
@ -0,0 +1,150 @@
|
|||
name: CI Pipeline
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
tags:
|
||||
- 'v*.*.*'
|
||||
pull_request:
|
||||
branches:
|
||||
- main
|
||||
|
||||
jobs:
|
||||
test:
|
||||
runs-on: docker
|
||||
container:
|
||||
image: ruby:3.3-alpine
|
||||
|
||||
steps:
|
||||
- name: Install system dependencies
|
||||
run: |
|
||||
# Detect OS and install dependencies
|
||||
if command -v apk >/dev/null 2>&1; then
|
||||
# Alpine Linux
|
||||
apk add --no-cache build-base libffi-dev linux-headers postgresql-dev git curl tzdata
|
||||
elif command -v apt-get >/dev/null 2>&1; then
|
||||
# Debian/Ubuntu
|
||||
apt-get update && apt-get install -y build-essential libffi-dev libpq-dev git curl tzdata
|
||||
elif command -v yum >/dev/null 2>&1; then
|
||||
# CentOS/RHEL
|
||||
yum install -y gcc make libffi-devel postgresql-devel git curl tzdata
|
||||
elif command -v dnf >/dev/null 2>&1; then
|
||||
# Fedora
|
||||
dnf install -y gcc make libffi-devel postgresql-devel git curl tzdata
|
||||
fi
|
||||
|
||||
- name: Clone repository
|
||||
run: |
|
||||
git clone ${{ github.server_url }}/${{ github.repository }}.git .
|
||||
git checkout ${{ github.sha }}
|
||||
|
||||
- name: Install bundler
|
||||
run: |
|
||||
cd app
|
||||
gem install bundler -v 2.6.7
|
||||
|
||||
- name: Install Ruby dependencies
|
||||
run: |
|
||||
cd app
|
||||
bundle config path vendor/bundle
|
||||
bundle install --jobs 4 --retry 3
|
||||
|
||||
- name: Run RSpec tests
|
||||
run: |
|
||||
cd app
|
||||
mkdir -p tmp
|
||||
bundle exec rspec --format progress
|
||||
|
||||
- name: Test status
|
||||
run: |
|
||||
if [ $? -eq 0 ]; then
|
||||
echo "✅ All tests passed!"
|
||||
else
|
||||
echo "❌ Tests failed"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
build:
|
||||
needs: test
|
||||
runs-on: docker
|
||||
if: github.event_name == 'push' && (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/'))
|
||||
|
||||
steps:
|
||||
- name: Install Docker and git
|
||||
run: |
|
||||
if command -v apk >/dev/null 2>&1; then
|
||||
apk add --no-cache docker git
|
||||
elif command -v apt-get >/dev/null 2>&1; then
|
||||
apt-get update && apt-get install -y docker.io git
|
||||
elif command -v yum >/dev/null 2>&1; then
|
||||
yum install -y docker git
|
||||
elif command -v dnf >/dev/null 2>&1; then
|
||||
dnf install -y docker git
|
||||
fi
|
||||
|
||||
- name: Clone repository
|
||||
run: |
|
||||
git clone ${{ github.server_url }}/${{ github.repository }}.git .
|
||||
git checkout ${{ github.sha }}
|
||||
|
||||
- name: Build Docker image
|
||||
run: |
|
||||
docker build -t baktainer-test .
|
||||
|
||||
- name: Test Docker image
|
||||
run: |
|
||||
docker run --rm baktainer-test ruby --version
|
||||
|
||||
- name: Login to Docker Hub
|
||||
run: |
|
||||
echo "${{ secrets.DOCKER_PASSWORD }}" | docker login -u "${{ secrets.DOCKER_USERNAME }}" --password-stdin
|
||||
|
||||
- name: Tag and push image
|
||||
run: |
|
||||
IMAGE_NAME="${{ secrets.DOCKER_IMAGE_NAME }}"
|
||||
|
||||
# Check if IMAGE_NAME is set
|
||||
if [ -z "${IMAGE_NAME}" ]; then
|
||||
echo "❌ Error: DOCKER_IMAGE_NAME secret is not set"
|
||||
echo "Please configure the DOCKER_IMAGE_NAME secret in your repository settings"
|
||||
echo "Example: jamez001/baktainer"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "📦 Pushing to Docker Hub as ${IMAGE_NAME}"
|
||||
|
||||
# Tag as latest
|
||||
docker tag baktainer-test "${IMAGE_NAME}:latest"
|
||||
docker push "${IMAGE_NAME}:latest"
|
||||
echo "✅ Pushed ${IMAGE_NAME}:latest"
|
||||
|
||||
# Tag with version if it's a tag
|
||||
if [[ "${GITHUB_REF}" == refs/tags/v* ]]; then
|
||||
VERSION_TAG="${GITHUB_REF#refs/tags/}"
|
||||
docker tag baktainer-test "${IMAGE_NAME}:${VERSION_TAG}"
|
||||
docker push "${IMAGE_NAME}:${VERSION_TAG}"
|
||||
echo "✅ Pushed ${IMAGE_NAME}:${VERSION_TAG}"
|
||||
fi
|
||||
|
||||
echo "✅ Docker image pushed successfully"
|
||||
|
||||
notify:
|
||||
needs: [test, build]
|
||||
runs-on: docker
|
||||
if: always()
|
||||
|
||||
steps:
|
||||
- name: Notify pipeline status
|
||||
run: |
|
||||
echo "📊 Pipeline Status Report:"
|
||||
echo "🧪 Tests: ${{ needs.test.result }}"
|
||||
if [ "${{ needs.build.result }}" != "skipped" ]; then
|
||||
echo "🐳 Build: ${{ needs.build.result }}"
|
||||
fi
|
||||
|
||||
if [ "${{ needs.test.result }}" == "success" ]; then
|
||||
echo "✅ All tests passed!"
|
||||
else
|
||||
echo "❌ Tests failed"
|
||||
fi
|
|
@ -279,10 +279,26 @@ class Baktainer::HealthCheckServer < Sinatra::Base
|
|||
end
|
||||
|
||||
def check_docker_status
|
||||
all_containers = Docker::Container.all
|
||||
running_containers = all_containers.select do |container|
|
||||
begin
|
||||
state = container.info['State']
|
||||
if state.is_a?(String)
|
||||
state == 'running'
|
||||
elsif state.is_a?(Hash)
|
||||
state['Status'] == 'running' || state['Running'] == true
|
||||
else
|
||||
false
|
||||
end
|
||||
rescue
|
||||
false
|
||||
end
|
||||
end
|
||||
|
||||
{
|
||||
version: Docker.version,
|
||||
containers_total: Docker::Container.all.size,
|
||||
containers_running: Docker::Container.all(filters: { status: ['running'] }).size,
|
||||
containers_total: all_containers.size,
|
||||
containers_running: running_containers.size,
|
||||
backup_containers: Baktainer::Containers.find_all(@dependency_container).size
|
||||
}
|
||||
rescue => e
|
||||
|
|
|
@ -1,123 +1,123 @@
|
|||
example_id | status | run_time |
|
||||
------------------------------------------------- | ------ | --------------- |
|
||||
./spec/integration/backup_workflow_spec.rb[1:1:1] | passed | 0.00171 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:1:2] | passed | 0.00195 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:2:1] | passed | 0.00881 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:2:2] | passed | 0.00956 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:3:1] | passed | 0.00764 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:3:2] | passed | 0.00261 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:4:1] | passed | 0.00831 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:4:2] | passed | 0.00211 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:5:1] | passed | 0.52977 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:5:2] | passed | 0.52801 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:5:3] | passed | 0.10974 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:6:1] | passed | 0.00171 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:6:2] | passed | 0.00694 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:7:1] | passed | 0.52673 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:1:1] | passed | 0.00024 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:1:2] | passed | 0.00026 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:2:1] | passed | 0.00023 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:3:1] | passed | 0.00022 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:3:2] | passed | 0.00022 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:4:1] | passed | 0.00069 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:5:1] | passed | 0.00024 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:5:2] | passed | 0.00022 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:6:1] | passed | 0.00023 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:7:1] | passed | 0.00026 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:7:2] | passed | 0.00022 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:8:1] | passed | 0.00022 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:8:2] | passed | 0.00024 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:8:3] | passed | 0.00022 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:8:4] | passed | 0.00024 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:8:5:1] | passed | 0.00039 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:8:5:2] | passed | 0.00023 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:8:5:3] | passed | 0.00024 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:8:5:4] | passed | 0.00027 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:8:5:5] | passed | 0.00026 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:1:1] | passed | 0.00085 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:1:2:1] | passed | 0.00067 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:2:1:1] | passed | 0.00461 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:2:1:2] | passed | 0.0043 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:2:1:3] | passed | 0.00355 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:2:2:1] | passed | 0.00081 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:3:1:1] | passed | 0.00449 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:3:1:2] | passed | 0.0051 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:3:1:3] | passed | 0.00573 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:3:2:1] | passed | 0.00437 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:4:1:1] | passed | 0.0035 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:4:1:2] | passed | 0.04324 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:4:1:3] | passed | 0.04267 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:4:2:1] | passed | 0.00067 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:5:1:1] | passed | 0.04521 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:5:2:1] | passed | 0.00691 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:5:3:1] | passed | 0.00497 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:6:1] | passed | 0.00245 seconds |
|
||||
./spec/unit/backup_rotation_spec.rb[1:1:1] | passed | 0.00051 seconds |
|
||||
./spec/unit/backup_rotation_spec.rb[1:1:2] | passed | 0.00073 seconds |
|
||||
./spec/unit/backup_rotation_spec.rb[1:2:1:1] | passed | 0.00136 seconds |
|
||||
./spec/unit/backup_rotation_spec.rb[1:2:1:2] | passed | 0.00146 seconds |
|
||||
./spec/unit/backup_rotation_spec.rb[1:2:2:1] | passed | 0.00146 seconds |
|
||||
./spec/unit/backup_rotation_spec.rb[1:2:2:2] | passed | 0.00181 seconds |
|
||||
./spec/unit/backup_rotation_spec.rb[1:2:3:1] | passed | 0.0019 seconds |
|
||||
./spec/unit/backup_rotation_spec.rb[1:2:4:1] | passed | 0.00583 seconds |
|
||||
./spec/unit/backup_rotation_spec.rb[1:2:4:2] | passed | 0.00633 seconds |
|
||||
./spec/unit/backup_rotation_spec.rb[1:3:1] | passed | 0.00255 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:1:1] | passed | 0.00191 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:1:2] | passed | 0.0024 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:2:1] | passed | 0.01827 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:2:2] | passed | 0.00589 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:3:1] | passed | 0.0091 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:3:2] | passed | 0.00232 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:4:1] | passed | 0.00732 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:4:2] | passed | 0.00219 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:5:1] | passed | 0.53404 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:5:2] | passed | 0.52251 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:5:3] | passed | 0.11007 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:6:1] | passed | 0.00357 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:6:2] | passed | 0.02485 seconds |
|
||||
./spec/integration/backup_workflow_spec.rb[1:7:1] | passed | 0.53235 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:1:1] | passed | 0.00029 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:1:2] | passed | 0.0003 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:2:1] | passed | 0.0003 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:3:1] | passed | 0.00031 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:3:2] | passed | 0.0003 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:4:1] | passed | 0.00061 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:5:1] | passed | 0.0003 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:5:2] | passed | 0.0003 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:6:1] | passed | 0.00033 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:7:1] | passed | 0.00029 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:7:2] | passed | 0.00027 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:8:1] | passed | 0.00032 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:8:2] | passed | 0.00031 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:8:3] | passed | 0.00029 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:8:4] | passed | 0.00029 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:8:5:1] | passed | 0.00033 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:8:5:2] | passed | 0.00029 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:8:5:3] | passed | 0.00031 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:8:5:4] | passed | 0.00031 seconds |
|
||||
./spec/unit/backup_command_spec.rb[1:8:5:5] | passed | 0.00037 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:1:1] | passed | 0.00082 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:1:2:1] | passed | 0.00073 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:2:1:1] | passed | 0.00636 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:2:1:2] | passed | 0.06349 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:2:1:3] | passed | 0.00542 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:2:2:1] | passed | 0.00107 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:3:1:1] | passed | 0.00398 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:3:1:2] | passed | 0.00371 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:3:1:3] | passed | 0.00386 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:3:2:1] | passed | 0.00094 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:4:1:1] | passed | 0.00395 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:4:1:2] | passed | 0.04289 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:4:1:3] | passed | 0.04335 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:4:2:1] | passed | 0.00093 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:5:1:1] | passed | 0.04249 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:5:2:1] | passed | 0.00399 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:5:3:1] | passed | 0.00405 seconds |
|
||||
./spec/unit/backup_encryption_spec.rb[1:6:1] | passed | 0.00082 seconds |
|
||||
./spec/unit/backup_rotation_spec.rb[1:1:1] | passed | 0.00074 seconds |
|
||||
./spec/unit/backup_rotation_spec.rb[1:1:2] | passed | 0.00062 seconds |
|
||||
./spec/unit/backup_rotation_spec.rb[1:2:1:1] | passed | 0.00314 seconds |
|
||||
./spec/unit/backup_rotation_spec.rb[1:2:1:2] | passed | 0.00351 seconds |
|
||||
./spec/unit/backup_rotation_spec.rb[1:2:2:1] | passed | 0.00173 seconds |
|
||||
./spec/unit/backup_rotation_spec.rb[1:2:2:2] | passed | 0.00196 seconds |
|
||||
./spec/unit/backup_rotation_spec.rb[1:2:3:1] | passed | 0.00195 seconds |
|
||||
./spec/unit/backup_rotation_spec.rb[1:2:4:1] | passed | 0.00709 seconds |
|
||||
./spec/unit/backup_rotation_spec.rb[1:2:4:2] | passed | 0.00749 seconds |
|
||||
./spec/unit/backup_rotation_spec.rb[1:3:1] | passed | 0.00362 seconds |
|
||||
./spec/unit/backup_rotation_spec.rb[1:3:2] | passed | 0.00145 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:1:1] | passed | 0.00125 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:1:2] | passed | 0.00128 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:1:3] | passed | 0.00131 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:1:4] | passed | 0.49121 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:1:5] | passed | 0.00133 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:2:1] | passed | 0.00253 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:2:2] | passed | 0.00184 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:2:3] | passed | 0.00259 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:3:1] | passed | 0.00182 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:3:2] | passed | 0.00171 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:3:3] | passed | 0.00189 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:3:4] | passed | 0.00673 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:4:1:1] | passed | 0.00201 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:4:2:1] | passed | 0.27045 seconds |
|
||||
./spec/unit/container_spec.rb[1:1:1] | passed | 0.00145 seconds |
|
||||
./spec/unit/container_spec.rb[1:2:1] | passed | 0.00128 seconds |
|
||||
./spec/unit/container_spec.rb[1:2:2] | passed | 0.00089 seconds |
|
||||
./spec/unit/container_spec.rb[1:3:1] | passed | 0.00078 seconds |
|
||||
./spec/unit/container_spec.rb[1:3:2] | passed | 0.00084 seconds |
|
||||
./spec/unit/container_spec.rb[1:4:1] | passed | 0.00086 seconds |
|
||||
./spec/unit/container_spec.rb[1:5:1] | passed | 0.00109 seconds |
|
||||
./spec/unit/container_spec.rb[1:5:2] | passed | 0.00088 seconds |
|
||||
./spec/unit/container_spec.rb[1:6:1] | passed | 0.00096 seconds |
|
||||
./spec/unit/container_spec.rb[1:7:1] | passed | 0.00083 seconds |
|
||||
./spec/unit/container_spec.rb[1:8:1] | passed | 0.0009 seconds |
|
||||
./spec/unit/container_spec.rb[1:9:1:1] | passed | 0.00124 seconds |
|
||||
./spec/unit/container_spec.rb[1:9:2:1] | passed | 0.00095 seconds |
|
||||
./spec/unit/container_spec.rb[1:9:3:1] | passed | 0.00073 seconds |
|
||||
./spec/unit/container_spec.rb[1:9:4:1] | passed | 0.00119 seconds |
|
||||
./spec/unit/container_spec.rb[1:9:5:1] | passed | 0.00151 seconds |
|
||||
./spec/unit/container_spec.rb[1:9:6:1] | passed | 0.00097 seconds |
|
||||
./spec/unit/container_spec.rb[1:10:1] | passed | 0.00125 seconds |
|
||||
./spec/unit/container_spec.rb[1:10:2] | passed | 0.00112 seconds |
|
||||
./spec/unit/container_spec.rb[1:10:3] | passed | 0.00119 seconds |
|
||||
./spec/unit/container_spec.rb[1:11:1] | passed | 0.00098 seconds |
|
||||
./spec/unit/container_spec.rb[1:11:2] | passed | 0.00139 seconds |
|
||||
./spec/unit/container_spec.rb[1:11:3] | passed | 0.00109 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:1:1:1] | passed | 0.00039 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:1:1:2] | passed | 0.0003 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:1:2:1] | passed | 0.00037 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:1:3:1] | passed | 0.00035 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:1:4:1] | passed | 0.00245 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:1:5:1] | passed | 0.00036 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:1:6:1] | passed | 0.00033 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:2:1] | passed | 0.00031 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:2:2] | passed | 0.00026 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:3:1] | passed | 0.00126 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:3:2] | passed | 0.00112 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:4:1] | passed | 0.00093 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:4:2] | passed | 0.00034 seconds |
|
||||
./spec/unit/notification_system_spec.rb[1:1:1:1] | passed | 0.00046 seconds |
|
||||
./spec/unit/notification_system_spec.rb[1:1:2:1] | passed | 0.00055 seconds |
|
||||
./spec/unit/notification_system_spec.rb[1:2:1] | passed | 0.00089 seconds |
|
||||
./spec/unit/notification_system_spec.rb[1:3:1] | passed | 0.00095 seconds |
|
||||
./spec/unit/notification_system_spec.rb[1:4:1] | passed | 0.001 seconds |
|
||||
./spec/unit/notification_system_spec.rb[1:5:1] | passed | 0.02489 seconds |
|
||||
./spec/unit/notification_system_spec.rb[1:6:1] | passed | 0.00487 seconds |
|
||||
./spec/unit/notification_system_spec.rb[1:6:2] | passed | 0.00057 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:1:1] | passed | 0.00158 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:1:2] | passed | 0.00281 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:1:3] | passed | 0.0019 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:1:4] | passed | 0.15162 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:1:5] | passed | 0.00152 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:2:1] | passed | 0.0026 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:2:2] | passed | 0.00234 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:2:3] | passed | 0.00303 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:3:1] | passed | 0.0022 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:3:2] | passed | 0.00217 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:3:3] | passed | 0.00234 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:3:4] | passed | 0.0036 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:4:1:1] | passed | 0.00313 seconds |
|
||||
./spec/unit/baktainer_spec.rb[1:4:2:1] | passed | 0.26206 seconds |
|
||||
./spec/unit/container_spec.rb[1:1:1] | passed | 0.00105 seconds |
|
||||
./spec/unit/container_spec.rb[1:2:1] | passed | 0.00156 seconds |
|
||||
./spec/unit/container_spec.rb[1:2:2] | passed | 0.0011 seconds |
|
||||
./spec/unit/container_spec.rb[1:3:1] | passed | 0.00105 seconds |
|
||||
./spec/unit/container_spec.rb[1:3:2] | passed | 0.00122 seconds |
|
||||
./spec/unit/container_spec.rb[1:4:1] | passed | 0.0011 seconds |
|
||||
./spec/unit/container_spec.rb[1:5:1] | passed | 0.00105 seconds |
|
||||
./spec/unit/container_spec.rb[1:5:2] | passed | 0.00113 seconds |
|
||||
./spec/unit/container_spec.rb[1:6:1] | passed | 0.0014 seconds |
|
||||
./spec/unit/container_spec.rb[1:7:1] | passed | 0.00102 seconds |
|
||||
./spec/unit/container_spec.rb[1:8:1] | passed | 0.00108 seconds |
|
||||
./spec/unit/container_spec.rb[1:9:1:1] | passed | 0.00116 seconds |
|
||||
./spec/unit/container_spec.rb[1:9:2:1] | passed | 0.00118 seconds |
|
||||
./spec/unit/container_spec.rb[1:9:3:1] | passed | 0.00098 seconds |
|
||||
./spec/unit/container_spec.rb[1:9:4:1] | passed | 0.00149 seconds |
|
||||
./spec/unit/container_spec.rb[1:9:5:1] | passed | 0.00147 seconds |
|
||||
./spec/unit/container_spec.rb[1:9:6:1] | passed | 0.00125 seconds |
|
||||
./spec/unit/container_spec.rb[1:10:1] | passed | 0.0021 seconds |
|
||||
./spec/unit/container_spec.rb[1:10:2] | passed | 0.00153 seconds |
|
||||
./spec/unit/container_spec.rb[1:10:3] | passed | 0.0063 seconds |
|
||||
./spec/unit/container_spec.rb[1:11:1] | passed | 0.00236 seconds |
|
||||
./spec/unit/container_spec.rb[1:11:2] | passed | 0.0019 seconds |
|
||||
./spec/unit/container_spec.rb[1:11:3] | passed | 0.00145 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:1:1:1] | passed | 0.00045 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:1:1:2] | passed | 0.0004 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:1:2:1] | passed | 0.00045 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:1:3:1] | passed | 0.00048 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:1:4:1] | passed | 0.00045 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:1:5:1] | passed | 0.00045 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:1:6:1] | passed | 0.00046 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:2:1] | passed | 0.00038 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:2:2] | passed | 0.00035 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:3:1] | passed | 0.00044 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:3:2] | passed | 0.00045 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:4:1] | passed | 0.00036 seconds |
|
||||
./spec/unit/label_validator_spec.rb[1:4:2] | passed | 0.00038 seconds |
|
||||
./spec/unit/notification_system_spec.rb[1:1:1:1] | passed | 0.00064 seconds |
|
||||
./spec/unit/notification_system_spec.rb[1:1:2:1] | passed | 0.00066 seconds |
|
||||
./spec/unit/notification_system_spec.rb[1:2:1] | passed | 0.03984 seconds |
|
||||
./spec/unit/notification_system_spec.rb[1:3:1] | passed | 0.00123 seconds |
|
||||
./spec/unit/notification_system_spec.rb[1:4:1] | passed | 0.00291 seconds |
|
||||
./spec/unit/notification_system_spec.rb[1:5:1] | passed | 0.00172 seconds |
|
||||
./spec/unit/notification_system_spec.rb[1:6:1] | passed | 0.00066 seconds |
|
||||
./spec/unit/notification_system_spec.rb[1:6:2] | passed | 0.00059 seconds |
|
||||
|
|
|
@ -51,7 +51,10 @@ RSpec.describe Baktainer::Container do
|
|||
allow(docker_container).to receive(:info).and_return(
|
||||
container_info.merge('State' => nil)
|
||||
)
|
||||
expect(container.state).to be_nil
|
||||
allow(docker_container).to receive(:json).and_return(
|
||||
'State' => { 'Status' => 'unknown' }
|
||||
)
|
||||
expect(container.state).to eq('unknown')
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue