This repository is the main website for Radio4000, web CMS for streamed media libraries → https://radio4000.com.
Join the discussion about the evolution and the development of Radio4000 onGitHub issues and the#radio4000:matrix.org chat.
This project aims at development and discussions on building a fairand open access ecosystem of tools and services; for music andcultural goods to be globally accessed and explored.
The goals and objectives of Radio4000 are defined in itsmanifest.
The application in this repository is written in JavaScript, using the frontend frameworkEmber.js for the client part of theapplication. Ember Data is used for the local data store, and also to build the API calls.Emberfire is used for itsadapter and serializers to our Firebase database.
The server part is, for now, using Google's Firebase and the code canbe found ontheradio4000-apirepository.
The code for the music player used by this project can be found atradio4000-player.
The plan is to move everything to libre software, self-hosted, withdecentralization in mind. It is not there yet and we would loveassistance in architecture and development.
To use Radio4000, you only have to visitradio4000.com, and start discovering new userselections.
The rest of this document will introduce some of the technical aspectsof:
See the file contributing, for more informationon how to contribute to the project.
To start developing on this project (namely radio4000, radio4000-cms,r4-cms), you will have to:
Then, clone this repository, install dependencies and start a development server:
git clone git@github.com:internet4000/radio4000.git
cd radio4000
yarn
yarn start
The start command will launch the application locally, find it in yourbrowser at http://localhost:4000.
By default this repository uses the radio4000-staging
database. Itcan also work with any other instance of Firebase Realtime database.
Run yarn test
for a single test or yarn ember test --server
to start a test server.
Lint scripts with:
yarn lint:js
yarn lint:js -- --fix
The site is hosted on netlify.com. Netlify deploys each branch and pull request automatically.
production
branch to https://radio4000.com (request new deployment)master
branch to https://master--radio4000.netlify.comBranch deploys are lowercased and hyphenated. That is, a branch named
feat/my-feature
would result in the URLfeat-my-feature--radio4000.netlify.com
. It usually takes ~2 minutes from git push to deployment is live.
See contributing.md for more.
We use Google's Firebase as our backend (database and API, on GoogleCloud Engine), as well as for authentication.
Firestore is not supported. Plans are more leaning toward moving offGoogle's infrastructures.
The security rules defining what can be read, updated, written,deleted, on each API endpoints are in theradio4000-apirepository,in the ./database.rules.json
file.
You will need to use this file to setup you database instance if you arerunning your instance of radio4000. In the Firebase Console of yourproject, under Datatbase > Rules.
To run your own firebase instance:
on the Firebase Console,create new project, to get an instance of Firebase Realtime database.
update the security rules of your project's database, as describedin the section above, [Security](./#Security Rules)
If there you don't have an app already, create one of type Web App
. You can fin the values for your application, in your firebaseproject's console, at Settings > Project Settings > General > Your Apps
. This will provide us the Firebase API keys.
Add your API keys to the CMS, in the file ./config/environment.js
apiKey
: 'your-api-key'
authDomain
: 'your-project.firebaseapp.com'
databaseURL
: 'your-project.firebaseio.com'
> You will have to update the following keys, for the default
> environment, as well as `production` depending on your objectives.
## Authentication
We're using a combination of [Firebase
Authentication](https://firebase.google.com/products/auth/),
[Torii](https://github.com/vestorly/torii) and
[EmberFire](https://github.com/firebase/emberfire/blob/master/docs/guide/authentication.md)
to handle authentication.
To access authentication in the Ember application, all routes and
controllers come with the `session` service already injected.
To get the current user (model), do `this.get('session.currentUser')`.
For more on auth, check the folders `app/auth` and `app/torii-adapters` as well as the above links.
## Firebase configuration
Links:
- firebase project console: https://console.firebase.google.com
- google cloud console (GCC) (> credentials): https://console.cloud.google.com/apis/credentials
> At the moment, authentication can be enabled with `Email and
> Password`, `Google`, `Facebook`. Note that social providers
> authentication with Google and Facebook will be shutdown in future versions.
For authentication to work, you need to already have setup the
Firebase keys in the file `radio4000/config/environment.js`
### Email/password
1. In your project's console, `Authentication > Sign-in methods`, activate **Email/Password** (no
need of activating email-link).
2. In the Google Cloud Console, create a new api key (name: `auth`)
- Application restrictions: HTTP referrers
- Website restriction: `https://your-domain.com/*` +
`https://your-project.firebaseapp.com/*`
- API restriction (1): Identity Toolkit API
You should be done!
#### Password reset link error
There has been issues with the reset link set to users asking for it
through the cms interface (and it using the provided firebase sdk method).
> "Your request to reset your password has expired or the link has
> already been used".
The reset link has a parameter `apiKey=abcd` that might be using a
different key that the one configured in the cms. Be sure to find that
key in the google cloud console for your project, and add it: `API
restriction (1): Identity Toolkit API`. This key needs only access to
this one service.
### oAuth2 social login
#### Google
1. In the Google cloud Console, create a new `OAuth 2.0 Client IDs`
Set the settings to:
- Authorized JavaScript origins: `https://your-domain.com`
- Authorized redirect URIs: `https://your-domain.com` +
`https://your-project.firebaseapp.com/__/auth/handler`
Copy, for the next step, the `Client ID` and `Client secret` values.
2. In your project's console, `Authentication > Sign-in methods`,
activate **Google**.
Under `Sign-in methods > Google > Web SDK configuration`, paste the
**Client ID** and **Secret** you copied before; save.
3. Check the oAuth Consent Screen section,
https://console.cloud.google.com/apis/credentials/consent
- Scopes for Google APIs: only the default (and minimum...), don't
require anything else, it is already too much (email, profile, openID).
- Authorized domains: `your-domain.com` +
`your-project.firebaseapp.com`
#### Facebook
1. On the Facebook for Developers site
(https://developers.facebook.com), get the **App ID** and an **App Secret**
for your app.
2. On your Firebase project console, at `Authentication > Sign-in
methodes > Facebook`, **activate** Facebook, then paste in **App ID**
and **Secret**
### Youtube API key
For automatic fetching of tracks title, you will need a Youtube API key.
https://console.cloud.google.com/apis/credentials
- Enable Youtube Data Api
- Create a new key, and restrict it to Youtube Data Api
- paste the key in `/config/environment.js`
radio组件 Radio4000播放器 (Radio4000 Player) This is a web component that plays channels from Radio4000. It uses the public radio4000-api and Vue.js. 这是一个播放Radio4000频道的Web组件。 它使用公共radio4000-api和Vue.js。 Vie
单选框 click clear isSelected package com.test.selenium; import java.util.List; import org.openqa.selenium.By; import org.openqa.selenium.WebDriver; import org.openqa.selenium.WebElement; import org.ope
C. Polycarp at the Radio time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output Polycarp is a music editor at the radio station. He received a pl
From : "Fabio Belavenuto" <belavenuto@gmail.com> To : video4linux-list@redhat.com Subject : [PATCH] Add TEA5764 radio driver Date : Wed, 17 Dec 2008 20:49:33 -0200 A
最近公司在做一个服务平台的项目,使用的若依框架,在一个单页面的vue文件中使用 有使用到搜索候选词,选中并且可能要发送给接口进行查询列表 以下代码仅供参考,是否在项目中有较高的实用度,无法确认,目前还没有接口进行测试 也不知道这样子加数组会怎么样,之后如果有修改再说。 单页面的html: 我是准备用form提交给后台查询 <el-form label-width="110px">
nricp - Non-rigid iterative closest point nricp is a MATLAB implementation of a non-rigid variant of the iterative closest point algorithm. It can be used to register 3D surfaces or point-clouds. The
HTTP 203 Non-Authoritative Information响应状态表明请求已成功,但封装的有效负载已由源服务器的200(OK)响应由变换代理修改。 的203响应是相似的值214,这意味着Transformation Applied所述的,Warning标题代码,其具有可应用于与任何状态码的响应的附加优点。 状态 203 Non-Authoritative Information
Utility classes to write to and read from non-blocking files and sockets. Contents: : Generic interface for reading and writing. : Implementation of BaseIOStream using non-blocking sockets. : SSL-awar
网站所有者反复提出的问题是,是否选择非 www 或 www 网址。本页面提供了一些有关最好的建议。 什么是域名? In an HTTP URL, the first substring that follows the initial http:// or https:// is called the domain. It is the name of the server where the d
问题内容: 我正在尝试在上配置我的电子邮件,并且不断收到错误消息: 我已经在网上看到了大量有关该错误的信息,但是我没有得到任何帮助。我在Fedora Linux(不是OpenJDK)上使用Sun的JDK。 这是我尝试过的几件事。我试着从以下这个建议后,但复制从Windows的cacerts到托管詹金斯没有工作,我的Fedora箱。在尝试将Gmail配置为SMTP服务器时,我尝试按照本指南进行操作,
本文向大家介绍mysql Non-Transactional Database Only(只支持MyISAM),包括了mysql Non-Transactional Database Only(只支持MyISAM)的使用技巧和注意事项,需要的朋友参考一下 后来在做WordPress,一开始还不知道原来WordPress用的是InnoDB数据引擎,于是在原来的数据库里面就建了一个数据库,一开始也没发
问题内容: 因此,我有两个要合并在一起的数据框。 我要合并3列,其中2列很容易。 我希望这是使用第三列,但这将是一个比较,如下所示: 不知道正确的语法在这里。 如果是SQL,对我来说将很容易。 有帮助吗? 问题答案: 熊猫只支持等联接。您需要添加第二步来过滤结果,如下所示:
我用java编写这个简单的类只是为了测试它的一些特性。 0 那么为什么当我在构造函数方法声明中使用时,类的静态字段不再改变了呢?