Skip to content

Commit

Permalink
🐳 Publish registration page to docker (#24)
Browse files Browse the repository at this point in the history
  • Loading branch information
shepilov authored Feb 2, 2024
1 parent 10f0196 commit c210076
Show file tree
Hide file tree
Showing 5 changed files with 62 additions and 30 deletions.
15 changes: 15 additions & 0 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: pr

on:
pull_request:
branches:
- main
- master
merge_group:
workflow_dispatch:

jobs:
test:
name: Build And Test
uses: ./.github/workflows/registration-publish.yml
secrets: inherit
16 changes: 16 additions & 0 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
on:
push:
branches:
- main

jobs:
test:
name: Build And Test
uses: ./.github/workflows/registration-build.yml
secrets: inherit

publish:
needs: [test]
name: Publish Registration Page
uses: ./.github/workflows/registration-publish.yml
secrets: inherit
Original file line number Diff line number Diff line change
@@ -1,16 +1,8 @@
name: CI
name: build

on:
push:
branches:
- main
pull_request:
branches:
- main
workflow_call:

workflow_dispatch:
env:
CI: true
jobs:
build:
runs-on: ubuntu-latest
Expand All @@ -27,7 +19,6 @@ jobs:
node-version: ${{ matrix.node-version }}
- name: npm install and build
run: |
cd registration
npm i
npm run build --if-present
env:
CI: true
28 changes: 28 additions & 0 deletions .github/workflows/registration-publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Docker Build

on:
workflow_call:

jobs:
publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Get all src files that have changed
id: changed-files
uses: tj-actions/changed-files@v41
with:
files: |
packages/registration/**/*
.github/workflows/**
- name: Publish to dockerhub
uses: elgohr/Publish-Docker-Github-Action@v5
with:
name: linagora/twake-matrix-registration
username: ${{ secrets.DOCKERHUB_USER }}
password: ${{ secrets.DOCKERHUB_PASSWORD }}
workdir: "${{ github.workspace }}/registration"
context: .
buildoptions: "-t linagora/twake-matrix-registration -f Dockerfile"
tags: "latest"

18 changes: 0 additions & 18 deletions registration/.github/workflows/docker.yml

This file was deleted.

0 comments on commit c210076

Please sign in to comment.