Skip to content

Commit

Permalink
Merge branch 'master' into rc
Browse files Browse the repository at this point in the history
  • Loading branch information
jonasgloning committed Feb 14, 2023
2 parents 0b6cec2 + ab8ea15 commit cc3fec9
Show file tree
Hide file tree
Showing 52 changed files with 26,520 additions and 15,967 deletions.
51 changes: 15 additions & 36 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -1,37 +1,16 @@
{
"parser": "@typescript-eslint/parser",
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended"
],
"env": {
"node": true,
"es6": true,
"mocha": true
},
"parserOptions": {
"ecmaVersion": 2018,
"sourceType": "module"
},
"rules": {
"no-var": "error",
"no-console": "off",
"@typescript-eslint/camelcase": "off",
"@typescript-eslint/interface-name-prefix": "off",
"@typescript-eslint/member-delimiter-style": [
"error",
{
"multiline": {
"delimiter": "semi",
"requireLast": true
},
"singleline": {
"delimiter": "semi",
"requireLast": true
}
}
],
"@typescript-eslint/explicit-function-return-type": "off"
}
}
"parser": "@typescript-eslint/parser",
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended"
],
"env": {
"node": true,
"es6": true
},
"parserOptions": {
"ecmaVersion": 2018,
"sourceType": "module"
}
}
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -1 +1 @@
blank_issues_enabled: false
blank_issues_enabled: false
34 changes: 18 additions & 16 deletions .github/ISSUE_TEMPLATE/peer-template.md
Original file line number Diff line number Diff line change
@@ -1,28 +1,30 @@
---
name: peer template
about: Create a report to help us improve
title: ''
labels: ''
assignees: ''

title: ""
labels: ""
assignees: ""
---

### I'm having an issue:
- Give an expressive description of what is went wrong
- Version of `peer` you're experiencing this issue
- Nodejs version?
- Platform name and its version (Win, Mac, Linux)?
- Nice to have: a repository with code to reproduce the issue
- If you're getting an error or exception, please provide its full stack-trace as plain-text or screenshot

- Give an expressive description of what is went wrong
- Version of `peer` you're experiencing this issue
- Nodejs version?
- Platform name and its version (Win, Mac, Linux)?
- Nice to have: a repository with code to reproduce the issue
- If you're getting an error or exception, please provide its full stack-trace as plain-text or screenshot

### I have a suggestion:
- Describe your feature / request
- How you're going to use it? Give a usage example(s)

- Describe your feature / request
- How you're going to use it? Give a usage example(s)

### Documentation is missing something or incorrect (have typos, etc.):
- Give an expressive description what you have changed/added and why
- Make sure you're using correct markdown markup
- Make sure all code blocks starts with triple ``` (*backtick*) and have a syntax tag, for more read [this docs](https://help.github.com/articles/creating-and-highlighting-code-blocks/#syntax-highlighting)
- Post addition/changes in issue, we will manage it

- Give an expressive description what you have changed/added and why
- Make sure you're using correct markdown markup
- Make sure all code blocks starts with triple ``` (_backtick_) and have a syntax tag, for more read [this docs](https://help.github.com/articles/creating-and-highlighting-code-blocks/#syntax-highlighting)
- Post addition/changes in issue, we will manage it

## Thank you, and do not forget to get rid of this default message
46 changes: 23 additions & 23 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
@@ -1,28 +1,28 @@
name: Docker build & publish

on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
push:
branches: ["master"]
pull_request:
branches: ["master"]

jobs:
docker:
runs-on: ubuntu-latest
steps:
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Login to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build
if: ${{ github.event_name == 'pull_request' }}
uses: docker/build-push-action@v3
- name: Build & publish
if: ${{ github.event_name == 'push' }}
uses: docker/build-push-action@v3
with:
push: true
tags: peerjs/peerjs-server-test:nightly
docker:
runs-on: ubuntu-latest
steps:
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Login to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build
if: ${{ github.event_name == 'pull_request' }}
uses: docker/build-push-action@v3
- name: Build & publish
if: ${{ github.event_name == 'push' }}
uses: docker/build-push-action@v3
with:
push: true
tags: peerjs/peerjs-server-test:nightly
10 changes: 5 additions & 5 deletions .github/workflows/fly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ name: Fly Deploy

on:
push:
branches:
- master
branches:
- master

env:
FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }}
Expand All @@ -13,6 +13,6 @@ jobs:
name: Deploy app
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: superfly/flyctl-actions/setup-flyctl@master
- run: flyctl deploy --remote-only
- uses: actions/checkout@v3
- uses: superfly/flyctl-actions/setup-flyctl@master
- run: flyctl deploy --remote-only
33 changes: 16 additions & 17 deletions .github/workflows/node.js.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,12 @@ name: Node.js CI

on:
push:
branches: [ "master" ]
branches: ["master"]
pull_request:
branches: [ "master" ]
branches: ["master"]

jobs:
build:

runs-on: ubuntu-latest

strategy:
Expand All @@ -20,17 +19,17 @@ jobs:
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/

steps:
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- run: npm ci
- run: npm run build
- run: npm run lint
- run: npm run coverage
- name: Publish code coverage to CodeClimate
uses: paambaati/[email protected]
env:
CC_TEST_REPORTER_ID: ${{secrets.CC_TEST_REPORTER_ID}}
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: "npm"
- run: npm ci
- run: npm run build
- run: npm run lint
- run: npm run coverage
- name: Publish code coverage to CodeClimate
uses: paambaati/[email protected]
env:
CC_TEST_REPORTER_ID: ${{secrets.CC_TEST_REPORTER_ID}}
23 changes: 23 additions & 0 deletions .github/workflows/prettier.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# From https://til.simonwillison.net/github-actions/prettier-github-actions
name: Check JavaScript for conformance with Prettier

on:
push:
pull_request:

jobs:
prettier:
runs-on: ubuntu-latest
steps:
- name: Check out repo
uses: actions/checkout@v3
- uses: actions/cache@v3
name: Configure npm caching
with:
path: ~/.npm
key: ${{ runner.os }}-npm-${{ hashFiles('**/workflows/prettier.yml') }}
restore-keys: |
${{ runner.os }}-npm-
- name: Run prettier
run: |-
npx prettier --check .
6 changes: 0 additions & 6 deletions .nycrc

This file was deleted.

5 changes: 5 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
dist
coverage

# semantic-release
CHANGELOG.md
3 changes: 3 additions & 0 deletions .prettierrc.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
trailingComma = "all"
semi = true
useTabs = true
58 changes: 29 additions & 29 deletions .releaserc.json
Original file line number Diff line number Diff line change
@@ -1,31 +1,31 @@
{
"branches": [
"stable",
{
"name": "rc",
"prerelease": true
}
],
"plugins": [
"@semantic-release/commit-analyzer",
"@semantic-release/release-notes-generator",
"@semantic-release/changelog",
"@semantic-release/npm",
"@semantic-release/git",
"@semantic-release/github",
[
"@codedependant/semantic-release-docker",
{
"dockerTags": [
"{{#if prerelease.[0]}}{{prerelease.[0]}}{{else}}latest{{/if}}",
"{{major}}-{{#if prerelease.[0]}}{{prerelease.[0]}}{{else}}latest{{/if}}",
"{{major}}.{{minor}}-{{#if prerelease.[0]}}{{prerelease.[0]}}{{else}}latest{{/if}}",
"{{version}}"
],
"dockerImage": "peerjs-server-test",
"dockerFile": "Dockerfile",
"dockerProject": "peerjs"
}
]
]
"branches": [
"stable",
{
"name": "rc",
"prerelease": true
}
],
"plugins": [
"@semantic-release/commit-analyzer",
"@semantic-release/release-notes-generator",
"@semantic-release/changelog",
"@semantic-release/npm",
"@semantic-release/git",
"@semantic-release/github",
[
"@codedependant/semantic-release-docker",
{
"dockerTags": [
"{{#if prerelease.[0]}}{{prerelease.[0]}}{{else}}latest{{/if}}",
"{{major}}-{{#if prerelease.[0]}}{{prerelease.[0]}}{{else}}latest{{/if}}",
"{{major}}.{{minor}}-{{#if prerelease.[0]}}{{prerelease.[0]}}{{else}}latest{{/if}}",
"{{version}}"
],
"dockerImage": "peerjs-server",
"dockerFile": "Dockerfile",
"dockerProject": "peerjs"
}
]
]
}
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,6 @@ WORKDIR /peer-server
COPY package.json package-lock.json ./
RUN npm clean-install --omit=dev
COPY --from=build /peer-server/dist/bin/peerjs.js ./
EXPOSE 9000
ENV PORT 9000
EXPOSE ${PORT}
ENTRYPOINT ["node", "peerjs.js"]
CMD [ "--port", "9000" ]
4 changes: 2 additions & 2 deletions PRIVACY.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
**We do not collect or store any information.**

While you are connected to a PeerJS server, your IP address, randomly-generated
client ID, and signalling data are kept in the server's memory. With default
client ID, and signalling data are kept in the server's memory. With default
settings, the server will remove this information from memory 60 seconds after
you stop communicating with the service. (See the
you stop communicating with the service. (See the
[`alive_timeout`](https://github.com/peers/peerjs-server#config--cli-options)
setting.)
Loading

0 comments on commit cc3fec9

Please sign in to comment.