Skip to content

Commit

Permalink
New CI/CD pipelines
Browse files Browse the repository at this point in the history
  • Loading branch information
neliebi committed Jan 31, 2024
1 parent 02d3cf8 commit 3042fa0
Show file tree
Hide file tree
Showing 3 changed files with 38 additions and 16 deletions.
22 changes: 22 additions & 0 deletions .github/workflows/deployment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
on:
pull_request:
branches:
- master
types: [closed]

jobs:
deployment:
if: github.event.pull_request.merged == true
runs-on:
- self-hosted
steps:
- name: Pull repository
run:
ssh ${{ secrets.BSUB_SERVER }} "git -C ${{ secrets.DEPLOY_PATH }}/ pull"
- name: Deploy
run: |
ssh ${{ secrets.BSUB_SERVER }} "bsub -K -q datamover 'cd ${{ secrets.DEPLOY_PATH }} && find . -name \"*.xsd\" -exec cp --parents {} ${{ secrets.FTP_PATH2 }}/ \\;'"
ssh ${{ secrets.BSUB_SERVER }} "bsub -K -q datamover 'rsync -av ${{ secrets.DEPLOY_PATH }}/emdb_schemas/ ${{ secrets.FTP_PATH }}/'"
- name: Send e-mail
run:
echo "The AddedAnnotations repository was pulled and moved to production." | mail -s "[emdb-emicss] addedAnnotations has updated" [email protected]
16 changes: 0 additions & 16 deletions .github/workflows/main.yml

This file was deleted.

16 changes: 16 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
name: Run Unit Tests

on:
pull_request:
branches:
- master

jobs:
test:
runs-on: self-hosted

steps:
- name: Test in a sample data
run: |
rsync ${{ secrets.BSUB_SERVER }}:${{ secrets.DATA_PATH }}/emd-8117-v30.xml .
xmllint --noout --schema emdb_schemas/current/emdb_relaxed.xsd emd-8117-v30.xml

0 comments on commit 3042fa0

Please sign in to comment.