Loading .gitignore +8 −0 Original line number Diff line number Diff line Loading @@ -23,6 +23,14 @@ npm-debug.log* *.tsbuildinfo next-env.d.ts .pnp.* .yarn/* !.yarn/patches !.yarn/plugins !.yarn/releases !.yarn/sdks !.yarn/versions /data /secrets docker-compose.local.yml No newline at end of file .gitlab-ci.yml +15 −2 Original line number Diff line number Diff line include: - local: .gitlab/ci/federation_test.yml build wiki: stage: build trigger: Loading @@ -11,8 +14,18 @@ build image: image: docker:latest rules: - if: $CI_PIPELINE_SOURCE != "merge_request_event" && $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH when: on_success variables: CONTAINER_TAG: latest - if: $CI_PIPELINE_SOURCE == "merge_request_event" when: manual variables: CONTAINER_TAG: mr-$CI_MERGE_REQUEST_IID - when: never before_script: - echo $CI_REGISTRY_PASSWORD | docker login $CI_REGISTRY -u $CI_REGISTRY_USER --password-stdin variables: CONTAINER_IMAGE_NAME: "$CI_REGISTRY_IMAGE:$CONTAINER_TAG" script: - docker build --tag $CI_REGISTRY_IMAGE . - docker push $CI_REGISTRY_IMAGE - docker build --tag $CONTAINER_IMAGE_NAME . - docker push $CONTAINER_IMAGE_NAME .gitlab/ci/federation_test.yml 0 → 100644 +66 −0 Original line number Diff line number Diff line # # TODO: different modes of testing based on branch # - inside MR: test against testing instances # - main branch: test against important public instances # TODO: require manual trigger inside MRs as not every test is needed every commit # .fed test: &fed_test stage: test dependencies: [] needs: [] # image: node:24-alpine image: registry.sc07.dev/sc07/fedi-testkit/node:24-pptr services: - name: postgres:14-alpine alias: postgres variables: POSTGRES_HOST_AUTH_METHOD: trust - name: redis:7-alpine alias: redis variables: DATABASE_URL: postgres://postgres@postgres:5432/fediauth REDIS_URI: redis://redis SESSION_SECRET: test TEST_FEDERATION_MODE: KEYRING PUPPETEER_EXECUTABLE_PATH: /usr/bin/chromium-browser TESTKIT_PUPPETEER_ARGS: --no-sandbox before_script: - corepack enable && corepack prepare - yarn - npx -w backend prisma migrate deploy - npx -w backend prisma generate script: - yarn workspace @fediverse-auth/backend run ci:test artifacts: when: always paths: - backend/vitest.xml reports: junit: backend/vitest.xml mr test federation: when: manual parallel: matrix: - TEST_FEDERATION_KEYRING_SERVICE: - grants.cafe - toast.ooo - piefed.grant.rip - mbin.grant.rip rules: - if: $CI_PIPELINE_SOURCE == "merge_request_event" <<: *fed_test test federation: parallel: matrix: - TEST_FEDERATION_KEYRING_SERVICE: - mastodon.social - mastodon.world - lemmy.world - piefed.social - pixelfed.social rules: - if: $CI_PIPELINE_SOURCE == "push" && $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH <<: *fed_test No newline at end of file .nvmrc +1 −1 Original line number Diff line number Diff line v23.5.0 v24.12.0 .vscode/settings.json 0 → 100644 +5 −0 Original line number Diff line number Diff line { "yaml.schemas": { "https://gitlab.com/gitlab-org/gitlab/-/raw/master/app/assets/javascripts/editor/schema/ci.json": ".gitlab/**/*.yml" } } Loading
.gitignore +8 −0 Original line number Diff line number Diff line Loading @@ -23,6 +23,14 @@ npm-debug.log* *.tsbuildinfo next-env.d.ts .pnp.* .yarn/* !.yarn/patches !.yarn/plugins !.yarn/releases !.yarn/sdks !.yarn/versions /data /secrets docker-compose.local.yml No newline at end of file
.gitlab-ci.yml +15 −2 Original line number Diff line number Diff line include: - local: .gitlab/ci/federation_test.yml build wiki: stage: build trigger: Loading @@ -11,8 +14,18 @@ build image: image: docker:latest rules: - if: $CI_PIPELINE_SOURCE != "merge_request_event" && $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH when: on_success variables: CONTAINER_TAG: latest - if: $CI_PIPELINE_SOURCE == "merge_request_event" when: manual variables: CONTAINER_TAG: mr-$CI_MERGE_REQUEST_IID - when: never before_script: - echo $CI_REGISTRY_PASSWORD | docker login $CI_REGISTRY -u $CI_REGISTRY_USER --password-stdin variables: CONTAINER_IMAGE_NAME: "$CI_REGISTRY_IMAGE:$CONTAINER_TAG" script: - docker build --tag $CI_REGISTRY_IMAGE . - docker push $CI_REGISTRY_IMAGE - docker build --tag $CONTAINER_IMAGE_NAME . - docker push $CONTAINER_IMAGE_NAME
.gitlab/ci/federation_test.yml 0 → 100644 +66 −0 Original line number Diff line number Diff line # # TODO: different modes of testing based on branch # - inside MR: test against testing instances # - main branch: test against important public instances # TODO: require manual trigger inside MRs as not every test is needed every commit # .fed test: &fed_test stage: test dependencies: [] needs: [] # image: node:24-alpine image: registry.sc07.dev/sc07/fedi-testkit/node:24-pptr services: - name: postgres:14-alpine alias: postgres variables: POSTGRES_HOST_AUTH_METHOD: trust - name: redis:7-alpine alias: redis variables: DATABASE_URL: postgres://postgres@postgres:5432/fediauth REDIS_URI: redis://redis SESSION_SECRET: test TEST_FEDERATION_MODE: KEYRING PUPPETEER_EXECUTABLE_PATH: /usr/bin/chromium-browser TESTKIT_PUPPETEER_ARGS: --no-sandbox before_script: - corepack enable && corepack prepare - yarn - npx -w backend prisma migrate deploy - npx -w backend prisma generate script: - yarn workspace @fediverse-auth/backend run ci:test artifacts: when: always paths: - backend/vitest.xml reports: junit: backend/vitest.xml mr test federation: when: manual parallel: matrix: - TEST_FEDERATION_KEYRING_SERVICE: - grants.cafe - toast.ooo - piefed.grant.rip - mbin.grant.rip rules: - if: $CI_PIPELINE_SOURCE == "merge_request_event" <<: *fed_test test federation: parallel: matrix: - TEST_FEDERATION_KEYRING_SERVICE: - mastodon.social - mastodon.world - lemmy.world - piefed.social - pixelfed.social rules: - if: $CI_PIPELINE_SOURCE == "push" && $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH <<: *fed_test No newline at end of file
.vscode/settings.json 0 → 100644 +5 −0 Original line number Diff line number Diff line { "yaml.schemas": { "https://gitlab.com/gitlab-org/gitlab/-/raw/master/app/assets/javascripts/editor/schema/ci.json": ".gitlab/**/*.yml" } }