-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Benedikt Strehle
committed
Mar 1, 2024
1 parent
7852d09
commit 746a4bc
Showing
12 changed files
with
93 additions
and
70 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
# This file was auto generated by the uix git_deploy plugin. Do not manually edit. | ||
|
||
name: Deploy prod | ||
on: push | ||
env: | ||
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}} | ||
jobs: | ||
test: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout Repo | ||
uses: "actions/checkout@v3" | ||
- name: Setup Deno | ||
uses: "denoland/setup-deno@v1" | ||
- name: Run Tests | ||
run: "deno run -Aq --import-map ./importmap.json https://cdn.unyt.org/unyt-tests/run.ts -s --reportfile testreport.xml" | ||
- name: Publish Test Report | ||
uses: "mikepenz/action-junit-report@v3" | ||
if: "success() || failure()" | ||
with: | ||
report_paths: testreport.xml | ||
deploy: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout Repo | ||
uses: "actions/checkout@v3" | ||
- name: Setup Deno | ||
uses: "denoland/setup-deno@v1" | ||
- name: Deploy UIX App | ||
run: "deno run --importmap ./importmap.json -Aqr https://dev.cdn.unyt.org/uix1/run.ts --stage prod --detach " | ||
needs: test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,8 @@ | ||
name: "Hello UIX", | ||
description: "A simple UIX app project" | ||
description: "A simple UIX app project"; | ||
|
||
plugin git_deploy ( | ||
prod: { | ||
on: "push" | ||
} | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
use stage from #public.uix; | ||
|
||
endpoint: stage { | ||
prod: @+example-video-call-1 | ||
}, | ||
|
||
location: stage { | ||
prod: @+unyt-host-1 | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +0,0 @@ | ||
/** | ||
* Backend entrypoint: | ||
* This module provides a default export that defines the UI that is returned from the backend | ||
* when a page is visited | ||
*/ | ||
|
||
import {provideRedirect} from "uix/html/entrypoint-providers.tsx" | ||
|
||
export default { | ||
|
||
// show backend (hybrid) rendered page on /backend | ||
'/backend': import("../common/page.tsx"), | ||
|
||
// redirect / to /backend | ||
'/': provideRedirect('/backend') | ||
|
||
} | ||
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
import { Endpoint, Target } from "unyt_core/types/addressing.ts"; | ||
import { Component } from "uix/components/Component.ts"; | ||
|
||
|
||
@endpoint class CallManager { | ||
@property static call(mediaStream: MediaStream) { | ||
console.log("call from " + datex.meta.sender, mediaStream) | ||
} | ||
} | ||
|
||
|
||
@template(async function () { | ||
|
||
const src = null//await navigator.mediaDevices.getUserMedia({ video: true, audio: true }); | ||
console.log("src", src); | ||
|
||
return <div> | ||
<p>Video Call</p> | ||
<input type="text" placeholder="Remote Endpoint" value={this.$.remoteEndpointName}/> | ||
<button onclick={()=>{ | ||
const endpoint = Endpoint.get(this.remoteEndpointName); | ||
CallManager.call.to(endpoint)(src); | ||
}}>Call</button> | ||
|
||
<div> | ||
<video id="ownVideo" src={src} /> | ||
<video id="remoteVideo" /> | ||
</div> | ||
|
||
</div> | ||
}) | ||
export class CallView extends Component { | ||
@property remoteEndpointName = "" | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,4 +8,4 @@ | |
"deno.window" | ||
] | ||
} | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
import { CallView } from "common/CallView.tsx"; | ||
|
||
export default <CallView/> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
{ | ||
"imports": { | ||
"datex-core-legacy": "https://cdn.unyt.org/datex-core-js-legacy@0.0.x/datex.ts", | ||
"datex-core-legacy/": "https://cdn.unyt.org/datex-core-js-legacy@0.0.x/", | ||
"unyt_core": "https://cdn.unyt.org/datex-core-js-legacy@0.0.x/datex.ts", | ||
"unyt_core/": "https://cdn.unyt.org/datex-core-js-legacy@0.0.x/", | ||
"uix": "https://cdn.unyt.org/uix@0.1.x/uix.ts", | ||
"uix/": "https://cdn.unyt.org/uix@0.1.x/src/", | ||
"uix/jsx-runtime": "https://cdn.unyt.org/uix@0.1.x/src/jsx-runtime/jsx.ts", | ||
"unyt-tests/": "https://cdn.unyt.org/unyt_tests/" | ||
"datex-core-legacy": "https://dev.cdn.unyt.org/unyt_core/datex.ts", | ||
"datex-core-legacy/": "https://dev.cdn.unyt.org/unyt_core/", | ||
"unyt_core": "https://dev.cdn.unyt.org/unyt_core/datex.ts", | ||
"unyt_core/": "https://dev.cdn.unyt.org/unyt_core/", | ||
"uix": "https://dev.cdn.unyt.org/uix1/uix.ts", | ||
"uix/": "https://dev.cdn.unyt.org/uix1/src/", | ||
"uix/jsx-runtime": "https://dev.cdn.unyt.org/uix1/src/jsx-runtime/jsx.ts", | ||
"unyt-tests/": "https://dev.cdn.unyt.org/unyt_tests/" | ||
} | ||
} |