Skip to content

Commit

Permalink
chore(FEC-13123): replace travis with github actions
Browse files Browse the repository at this point in the history
  • Loading branch information
SivanA-Kaltura authored May 4, 2023
2 parents 38e6c2e + 732eb94 commit 4db479c
Show file tree
Hide file tree
Showing 9 changed files with 87 additions and 198 deletions.
29 changes: 29 additions & 0 deletions .github/workflows/run_canary_full_flow.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
## Canary CI/CD
name: Canary Full Flow
run-name: Canary Full Flow

on:
push:
branches:
- master

jobs:
canary-full-flow:
if: ${{ github.actor != 'PlaykitJs-Bot' }}
uses: kaltura/ovp-pipelines-pub/.github/workflows/[email protected]
secrets:
PLAYER_CENTRAL_ACCOUNT_ID: ${{ secrets.PLAYER_CENTRAL_ACCOUNT_ID }}
PLAYER_SERVICES_ACCOUNT_ID: ${{ secrets.PLAYER_SERVICES_ACCOUNT_ID }}
PLAYER_S3_BUCKET_DEPLOYMENT: ${{ secrets.PLAYER_S3_BUCKET_DEPLOYMENT }}
PLAYER_S3_BUCKET_APPS: ${{ secrets.PLAYER_S3_BUCKET_APPS }}
PLAYER_NPM_TOKEN: ${{ secrets.PLAYER_NPM_TOKEN }}
PLAYER_LAMBDA_NAME: ${{ secrets.PLAYER_LAMBDA_NAME }}
PLAYER_MSTEAMS_WEBHOOK: ${{ secrets.PLAYER_MSTEAMS_WEBHOOK }}
PLAYER_GITHUB_BOT_TOKEN: ${{ secrets.PLAYER_GITHUB_BOT_TOKEN }}
with:
type: "plugin"
stage: "canary"
schema-type: "playerV3Versions"
tests-yarn-run-to-execute: 'eslint flow'
run-on-ubuntu: "false"
run-on-macos: "true"
24 changes: 24 additions & 0 deletions .github/workflows/run_prod.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
## Prod CI
name: Prod
run-name: Prod

on:
workflow_dispatch:

jobs:
prod:
uses: kaltura/ovp-pipelines-pub/.github/workflows/[email protected]
secrets:
PLAYER_CENTRAL_ACCOUNT_ID: ${{ secrets.PLAYER_CENTRAL_ACCOUNT_ID }}
PLAYER_SERVICES_ACCOUNT_ID: ${{ secrets.PLAYER_SERVICES_ACCOUNT_ID }}
PLAYER_S3_BUCKET_DEPLOYMENT: ${{ secrets.PLAYER_S3_BUCKET_DEPLOYMENT }}
PLAYER_S3_BUCKET_APPS: ${{ secrets.PLAYER_S3_BUCKET_APPS }}
PLAYER_NPM_TOKEN: ${{ secrets.PLAYER_NPM_TOKEN }}
PLAYER_LAMBDA_NAME: ${{ secrets.PLAYER_LAMBDA_NAME }}
PLAYER_MSTEAMS_WEBHOOK: ${{ secrets.PLAYER_MSTEAMS_WEBHOOK }}
PLAYER_GITHUB_BOT_TOKEN: ${{ secrets.PLAYER_GITHUB_BOT_TOKEN }}
with:
type: "plugin"
env: "prod"
schema-type: "playerV3Versions"
tests-yarn-run-to-execute: 'eslint flow'
24 changes: 24 additions & 0 deletions .github/workflows/run_tests.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
## CI - Player And Plugin Tests
name: Player And Plugin Tests
run-name: Player And Plugin Tests

on:
pull_request:
branches:
- "*"

jobs:
running-tests:
uses: kaltura/ovp-pipelines-pub/.github/workflows/[email protected]
with:
yarn-run-to-execute: 'eslint flow'
notification:
if: always()
uses: kaltura/ovp-pipelines-pub/.github/workflows/[email protected]
needs: running-tests
secrets:
PLAYER_MSTEAMS_WEBHOOK: ${{ secrets.PLAYER_MSTEAMS_WEBHOOK }}
with:
failure-status: ${{ contains(needs.*.result, 'failure') }}
cancelled-status: ${{ contains(needs.*.result, 'cancelled') }}
is-test: 'true'
96 changes: 0 additions & 96 deletions .travis.yml

This file was deleted.

2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# PlayKit JS AirPlay - Apple AirPlay Plugin for the [Kaltura Player JS]

[![Build Status](https://travis-ci.com/kaltura/playkit-js-airplay.svg?branch=master)](https://travis-ci.com/kaltura/playkit-js-airplay)
[![Build Status](https://github.com/kaltura/playkit-js-airplay/actions/workflows/run_canary_full_flow.yaml/badge.svg)](https://github.com/kaltura/playkit-js-airplay/actions/workflows/run_canary_full_flow.yaml)
[![code style: prettier](https://img.shields.io/badge/code_style-prettier-ff69b4.svg?style=flat-square)](https://github.com/prettier/prettier)
[![](https://img.shields.io/npm/v/@playkit-js/playkit-js-airplay/latest.svg)](https://www.npmjs.com/package/@playkit-js/playkit-js-airplay)
[![](https://img.shields.io/npm/v/@playkit-js/playkit-js-airplay/canary.svg)](https://www.npmjs.com/package/@playkit-js/playkit-js-airplay/v/canary)
Expand Down
27 changes: 4 additions & 23 deletions karma.conf.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,4 @@
const isWindows = /^win/.test(process.platform);
const isMacOS = /^darwin/.test(process.platform);
// Create custom launcher in case running with Travis
const customLaunchers = {
Safari_travis_ci: {
base: 'Safari',
flags: ['--no-sandbox', '--autoplay-policy=no-user-gesture-required']
}
};

//Create custom launcher in case running with Travis
const launchers = {
Safari_browser: {
base: 'Safari',
Expand All @@ -20,8 +11,7 @@ module.exports = function (config) {
logLevel: config.LOG_INFO,
browserDisconnectTimeout: 30000,
browserNoActivityTimeout: 60000,
customLaunchers: launchers,
browsers: ['Safari_browser'],
browsers: [],
concurrency: 1,
singleRun: true,
colors: true,
Expand Down Expand Up @@ -49,16 +39,7 @@ module.exports = function (config) {
}
};

if (process.env.TRAVIS) {
karmaConf.customLaunchers = customLaunchers;
karmaConf.browsers = ['Safari_travis_ci'];
} else {
if (isWindows) {
karmaConf.browsers.push('IE');
} else if (isMacOS) {
karmaConf.browsers.push('Safari');
}
}

karmaConf.customLaunchers = launchers;
karmaConf.browsers = ['Safari_browser'];
config.set(karmaConf);
};
38 changes: 0 additions & 38 deletions scripts/after_deploy.sh

This file was deleted.

40 changes: 0 additions & 40 deletions scripts/travis.sh

This file was deleted.

5 changes: 5 additions & 0 deletions test/src/airplay.spec.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
describe('Airplay Engine', () => {
it('should return true', () => {
return true;
});
});

0 comments on commit 4db479c

Please sign in to comment.