Skip to content

Some AI changes... interesting #340

Some AI changes... interesting

Some AI changes... interesting #340

Workflow file for this run

name: Publish Docker image
on:
push:
branches: ["main", "build"]
pull_request:
branches: ["main"]
release:
types: [published]
workflow_dispatch:
jobs:
build_and_test:
name: Run tests and collect coverage
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Node
uses: actions/setup-node@v4
- name: Install dependencies
run: npm install
- name: Prep .env file for integration tests
env:
envFileContents: ${{ secrets.INTEGRATION_ENV }}
run: |
echo "$envFileContents" >> test/integration/.env.sync-bot.tests
- name: Run tests
run: npm run test:all
- name: Upload results to Codecov
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
- name: Upload test results to Codecov
if: ${{ !cancelled() }}
uses: codecov/test-results-action@v1
with:
token: ${{ secrets.CODECOV_TOKEN }}
push_to_registry:
name: Push Docker image to Docker Hub
runs-on: ubuntu-latest
steps:
- name: Check out the repo
uses: actions/checkout@v3
- name: Log in to Docker Hub
uses: docker/login-action@v2.1.0
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Extract metadata (tags, labels) for Docker
id: meta
uses: docker/metadata-action@v4.3.0
with:
images: trfc/github-teams-user-sync
- name: Build and push Docker image
uses: docker/build-push-action@v3.3.0
with:
context: .
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
file: Dockerfile