Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds docs for Personal Myradio Dev #372

Open
wants to merge 12 commits into
base: development
Choose a base branch
from
40 changes: 40 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,46 @@ $ make build-docker-image #Builds the image, will only have to be re-run if you
$ make docker #Runs the image
```

## Using with your own Myradio

### Inital setup

Next you need a api_key to allow the website to access myradio's show information,

login into database with details used during setup of myradio

```sql
INSERT INTO myury.api_key (key_string, description) VALUES ('ARANDOMSTRINGOFCHARACTERS', '2016-site development api key');
INSERT INTO myury.api_key_auth (key_string, typeid) VALUES ('ARANDOMSTRINGOFCHARACTERS', (SELECT typeid FROM l_action WHERE phpconstant = 'AUTH_APISUDO'));
```

[please choose a better key than 'ARANDOMSTRINGOFCHARACTERS']
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

square brackets is markdown syntax - and you should probably give an example of generating a random key like openssl rand -hex 32 - which should come before the SQL statements

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

bump


You might need add some other database columns to create shows

for example:
- explict podcasts (to create shows)
- selector (expected by 2016-site/can remove this from models/index.go 2016-site)

This will fix shows not loading on 2016-site when using the base myradio as,

2016-site uses parts of database that aren't made on myradio creation.

### finishing steps

After completing all these setups:
You can setup a reverse proxy to "https://localhost:4443" or configure ssl for https connections,

And change 2016-site to use your myradio instance:

In Config.toml:

```
myradio_api = "https://{hostname}/api/v2"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this should probably just explain how to connect it to localhost, don't bother with https/another reverse proxy

Copy link
Contributor Author

@hitime1234 hitime1234 Sep 15, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the problem I encoured is there no easy way of running it over https which is required by myradio apache server, without reverse proxying through a domain.
as it looks like you might need to gen some of your own certificates before you can use api
x509: cannot validate certificate
I'll see if I can make it work on localhost

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if you go to http://localhost:7080/myradio/ rather than https://localhost:4443, it will work over http (if you have already set up a local instance, you need to change the port in Config:$base_url in src/MyRadio_Config.local.php)

```



## Editor Config
There is a handy editor config file included in this repo, most editors/IDE's have support for this either natively or through a plugin, see [here](http://editorconfig.org/#download).