-
-
Notifications
You must be signed in to change notification settings - Fork 8
Add organization exports #64
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
mvfc
wants to merge
42
commits into
main
Choose a base branch
from
mc/organization_export
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
42 commits
Select commit
Hold shift + click to select a range
fffb3f3
Downgrade bw version to 2025.10 (last known fully compatible version)
mvfc 3657bac
Remove initial run if it's not the initial setup. Also accomodate for…
mvfc 7ca7a2a
Add comprehensive testing infrastructure
mvfc 1677238
Add AGENTS.md and organizations exports
mvfc 342ce66
Merge branch 'main' into mc/organization_export
mvfc abbe355
Enhance CI workflow and improve code documentation
mvfc 5085ab3
Fix CI and run tests, add bin to gitignore
mvfc 703f595
fix CI
mvfc 48bd975
reintroduce raw and bitwarden on org encryption modes
mvfc 66ee852
Enhance CI workflows, add Bitwarden CLI installation, and improve HTM…
mvfc 42a4377
Refactor CI and E2E workflows, improve Docker image testing, and enha…
mvfc 3630b9e
Enhance E2E workflow: use secrets for sensitive data, set up Python a…
mvfc 29f4c68
add missing dependencies in CI lint
mvfc 2192b62
fix dependencies in CI lint
mvfc d749cec
fix ci errors and add dependencies
mvfc b53d33e
Update .github/workflows/ci.yml
mvfc a775658
Update .github/workflows/e2e.yml
mvfc d0a6fc0
Update .github/workflows/ci.yml
mvfc 37eced1
Merge branch 'mc/organization_export' of github.com:mvfc/backvault in…
mvfc 2e8e53b
Update opencode workflow permissions and enhance README and form UI f…
mvfc aa8d737
Refactor CI and E2E workflows, enhance opencode conditions, and updat…
mvfc d1231c9
Fix init.py default to multiple; fix personal file condition
mvfc a4b9ffc
Add error handling for multiple-mode org exports
mvfc bdb861b
Fix single+bitwarden silent exit to warning
mvfc ed92975
Enhance CI/CD workflows, improve error handling, and update organizat…
mvfc 4597a2d
fix appgroup
mvfc b361562
Update CI workflows, enhance error handling, and improve organization…
mvfc 624eefc
- Fixed 15 issues across various files, including test_run.py, e2e.ym…
mvfc 6641dd7
Enhance E2E tests with ADMIN_TOKEN validation, improve opencode job c…
mvfc 9a4537e
Update src/form.html
mvfc c44f16e
ruff format
mvfc 58c4181
Merge branch 'mc/organization_export' of github.com:mvfc/backvault in…
mvfc 88407e1
Add cleanup step for appgroup and appuser in E2E workflow
mvfc dcefb9c
Refactor Dockerfile to create appgroup and appuser idempotently
mvfc e2cd14f
Update src/bw_client.py
mvfc 15d6bac
Update src/bw_client.py
mvfc b4a0d1c
Update E2E workflow to pull Docker image and adjust organization expo…
mvfc d4f22b6
Merge branch 'mc/organization_export' of github.com:mvfc/backvault in…
mvfc 2ca9301
Refactor logging statements for improved readability in organization …
mvfc d062647
Fix organization export condition to handle None value for org_export…
mvfc 6c60dff
Enhance organization export logic and update E2E tests
mvfc 38689e8
fix dockerfile appgroup
mvfc File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,125 @@ | ||
| name: E2E Tests | ||
| permissions: | ||
| contents: read | ||
| actions: read | ||
|
|
||
| on: | ||
| workflow_run: | ||
| workflows: [CI] | ||
| types: [completed] | ||
| branches: [main] | ||
| pull_request: | ||
| paths: | ||
| - 'tests/**' | ||
| - '.github/workflows/e2e.yml' | ||
| - 'src/**' | ||
| workflow_dispatch: | ||
|
|
||
|
coderabbitai[bot] marked this conversation as resolved.
|
||
| env: | ||
| IMAGE_NAME: docker.io/mvflc/backvault | ||
| VAULTWARDEN_PORT: '8888' | ||
| VAULTWARDEN_URL: http://localhost:8888 | ||
|
|
||
| jobs: | ||
| e2e: | ||
| name: E2E Tests | ||
| if: > | ||
| (github.event_name == 'workflow_run' && github.event.workflow_run.conclusion == 'success') || | ||
| (github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository) || | ||
| github.event_name == 'workflow_dispatch' | ||
|
coderabbitai[bot] marked this conversation as resolved.
|
||
| runs-on: ubuntu-latest | ||
| services: | ||
| vaultwarden: | ||
| image: vaultwarden/server:latest | ||
| env: | ||
| SIGNUPS_ALLOWED: "true" | ||
| ADMIN_TOKEN: ${{ secrets.ADMIN_TOKEN }} | ||
| I_REALLY_WANT_VOLATILE_STORAGE: "true" | ||
| ports: | ||
| - 8888:80 | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
|
|
||
| - name: Set up QEMU | ||
| uses: docker/setup-qemu-action@v3 | ||
|
|
||
| - name: Set up Docker Buildx | ||
| uses: docker/setup-buildx-action@v3 | ||
|
|
||
| - name: Cleanup appgroup | ||
| run: | | ||
| sudo delgroup appgroup 2>/dev/null || true | ||
| sudo deluser appuser 2>/dev/null || true | ||
|
|
||
| - name: Validate ADMIN_TOKEN | ||
| env: | ||
| ADMIN_TOKEN: ${{ secrets.ADMIN_TOKEN }} | ||
| run: | | ||
| if [ -z "$ADMIN_TOKEN" ]; then | ||
| echo "Error: ADMIN_TOKEN secret is required" | ||
| exit 1 | ||
| fi | ||
|
coderabbitai[bot] marked this conversation as resolved.
|
||
|
|
||
|
greptile-apps[bot] marked this conversation as resolved.
|
||
| - name: Pull test image | ||
| run: | | ||
| docker pull docker.io/mvflc/backvault:test | ||
| docker tag docker.io/mvflc/backvault:test ${{ env.IMAGE_NAME }}:test | ||
|
|
||
| - name: Wait for Vaultwarden | ||
| run: | | ||
| for i in $(seq 1 30); do | ||
| HTTP_CODE=$(curl -so /dev/null -w '%{http_code}' -L "http://localhost:8888/api/config" 2>/dev/null) | ||
| if [ "$HTTP_CODE" = "200" ]; then | ||
| echo "Vaultwarden is ready (HTTP $HTTP_CODE)" | ||
| exit 0 | ||
| fi | ||
| echo "Attempt $i/30: Waiting... (HTTP $HTTP_CODE)" | ||
| sleep 2 | ||
| done | ||
| echo "Error: Vaultwarden failed to start" | ||
| exit 1 | ||
|
|
||
| - name: Verify Vaultwarden is running | ||
| run: | | ||
| HTTP_CODE=$(curl -so /dev/null -w '%{http_code}' -L "http://localhost:8888/api/config" 2>/dev/null) | ||
| if [ "$HTTP_CODE" != "200" ]; then | ||
| echo "Error: Vaultwarden health check failed (HTTP $HTTP_CODE)" | ||
| exit 1 | ||
| fi | ||
| echo "Vaultwarden health check passed" | ||
|
|
||
| - name: Set up Python | ||
| uses: actions/setup-python@v5 | ||
| with: | ||
| python-version: '3.13' | ||
|
|
||
| - name: Set up Node.js | ||
| uses: actions/setup-node@v4 | ||
| with: | ||
| node-version: '20' | ||
|
|
||
| - name: Install system dependencies | ||
| run: sudo apt-get update && sudo apt-get install -y libsqlite3-dev libsqlcipher-dev libssl-dev | ||
|
|
||
| - name: Install Bitwarden CLI | ||
| run: | | ||
| npm install -g @bitwarden/cli | ||
|
|
||
| - name: Install dependencies | ||
| run: | | ||
| pip install uv | ||
| uv sync --dev | ||
|
coderabbitai[bot] marked this conversation as resolved.
|
||
|
|
||
| - name: Run E2E tests | ||
| env: | ||
| VAULTWARDEN_URL: ${{ env.VAULTWARDEN_URL }} | ||
| BW_TEST_EMAIL: ${{ secrets.BW_TEST_EMAIL }} | ||
| BW_TEST_PASSWORD: ${{ secrets.BW_TEST_PASSWORD }} | ||
| BW_TEST_MASTER_PASSWORD: ${{ secrets.BW_TEST_MASTER_PASSWORD }} | ||
| IMAGE_NAME: ${{ env.IMAGE_NAME }}:test | ||
| run: uv run pytest tests/test_e2e.py -v -m e2e -o "addopts=" | ||
|
|
||
| - name: Cleanup Docker buildx | ||
| if: always() | ||
| run: | | ||
| docker buildx prune --all -f 2>/dev/null || true | ||
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.