Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit c452fa2

Browse files
authored
Merge pull request #433 from blackcandy-org/bump_version
Release v3.1
2 parents 77fc58e + 5131a8c commit c452fa2

File tree

5 files changed

+291
-280
lines changed

5 files changed

+291
-280
lines changed

README.md

Lines changed: 27 additions & 56 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
![Screenshot](https://raw.githubusercontent.com/blackcandy-org/blackcandy/master/docs/images/screenshot_main.png)
1212

13-
Black Candy is a self-hosted music streaming server, your personal music center.
13+
Black Candy is a self-hosted music streaming server, your personal music center.
1414

1515
## Try The Demo
1616

@@ -24,21 +24,20 @@ Please visit <https://demo.blackcandy.org> and use demo user (email: admin@admin
2424
Black Candy uses docker image to install easily. You can run Black Candy like this.
2525

2626
```shell
27-
docker run -p 3000:3000 ghcr.io/blackcandy-org/blackcandy:latest
27+
docker run -p 80:80 ghcr.io/blackcandy-org/blackcandy:latest
2828

2929
# Or pull from Docker Hub.
30-
docker run -p 3000:3000 blackcandy/blackcandy:latest
30+
docker run -p 80:80 blackcandy/blackcandy:latest
3131
```
3232

33-
That's all. Now, you can access either http://localhost:3000 or http://host-ip:3000 in a browser, and use initial admin user to log in (email: [email protected], password: foobar).
33+
That's all. Now, you can access either http://localhost or http://host-ip in a browser, and use initial admin user to log in (email: [email protected], password: foobar).
3434

3535
## Upgrade
3636

37-
> [!IMPORTANT]
38-
> If you upgrade to a major version, you need to read the upgrade guide carefully before upgrade. Because there are some breaking changes in a major version.
39-
>
40-
> - See [V3 Upgrade](https://github.com/blackcandy-org/blackcandy/blob/master/docs/v3_upgrade.md) for upgrade from V2 release.
41-
> - See [Edge Upgrade](https://github.com/blackcandy-org/blackcandy/blob/master/docs/edge_upgrade.md) for upgrade from edge release to latest stable release.
37+
> [!IMPORTANT]
38+
> If you upgrade to a new version, you need to read the upgrade guide carefully before upgrade. Because there are may some breaking changes in a new version.
39+
>
40+
> Please Check the [Upgrade Guide](https://github.com/blackcandy-org/blackcandy/blob/master/docs/upgrade.md) for upgrading to a new version
4241
4342
Upgrade Black Candy is pull new image from remote. Then remove an old container and create a new one.
4443

@@ -71,13 +70,13 @@ For Android app, you can also download APK from [GitHub Release](https://github.
7170

7271
### Port Mapping
7372

74-
Black Candy exports the 3000 port. If you want to be able to access it from the host, you can use the `-p` option to map the port.
73+
Black Candy exports the 80 port. If you want to be able to access it from the host, you can use the `-p` option to map the port.
7574

7675
```shell
77-
docker run -p 3000:3000 ghcr.io/blackcandy-org/blackcandy:latest
76+
docker run -p 3000:80 ghcr.io/blackcandy-org/blackcandy:latest
7877
```
7978

80-
### Media Files Mounts
79+
### Media Files Mounts
8180

8281
You can mount media files from host to container and use `MEDIA_PATH` environment variable to set the media path for black candy.
8382

@@ -103,41 +102,12 @@ mkdir storage_data
103102
docker run -v ./storage_data:/app/storage ghcr.io/blackcandy-org/blackcandy:latest
104103
```
105104

106-
### Nginx To Send File
107-
108-
Black Candy supports use Nginx to delivery audio file to the client. It's a more effective way than handled by Black Candy backend. And Black Candy docker image is also ready for [nginx-proxy](https://github.com/nginx-proxy/nginx-proxy), which means you can set up a Nginx proxy for Black Candy easily.
109-
110-
You can use docker-compose to set up those services. The docker-compose.yml file looks like this:
111-
112-
```yaml
113-
version: '3'
114-
115-
services:
116-
nginx-proxy:
117-
image: nginxproxy/nginx-proxy
118-
ports:
119-
- "80:80"
120-
volumes:
121-
- ./blackcandy.local:/etc/nginx/vhost.d/blackcandy.local:ro
122-
- /var/run/docker.sock:/tmp/docker.sock:ro
123-
- /media_data:/media_data # Keep the path of media files in container the same as blackcandy container.
124-
125-
app:
126-
image: ghcr.io/blackcandy-org/blackcandy:latest
127-
volumes:
128-
- ./storage_data:/app/storage
129-
- /media_data:/media_data
130-
environment:
131-
VIRTUAL_HOST: blackcandy.local
132-
MEDIA_PATH: /media_data
133-
NGINX_SENDFILE: "true" # Don't forget to set `NGINX_SENDFILE` environment variable to true to enable nginx sendfile.
134-
```
105+
### Running as an Arbitrary User
135106

136-
```shell
137-
# Get the default sendfile config for blackcandy. This file need to mount to nginx proxy container to add custom configuration for nginx.
138-
curl https://raw.githubusercontent.com/blackcandy-org/blackcandy/v3.0.0/config/nginx/sendfile.conf > blackcandy.local
107+
When mounting volumes, you may encounter permission issues between the host and the Docker container. To resolve this issue, pass the UID and GID with the `--user` to set the same UID and GID as your host user.
139108

140-
docker-compose up
109+
```shell
110+
docker run --user 2000:2000 -v ./storage_data:/app/storage ghcr.io/blackcandy-org/blackcandy:latest
141111
```
142112

143113
### Logging
@@ -146,15 +116,17 @@ Black Candy logs to `STDOUT` by default. So if you want to control the log, Dock
146116

147117
## Environment Variables
148118

149-
| Name | Default | Description |
150-
| --- | --- | --- |
151-
| DB_URL | | The URL of PostgreSQL database. You must set this environment variable if you use PostgreSQL as database. |
152-
| MEDIA_PATH | | You can use this environment variable to set media path for Black Candy, otherwise you can set media path in settings page. |
153-
| DB_ADAPTER | "sqlite" | There are two adapters are supported, "sqlite" and "postgresql".|
154-
| NGINX_SENDFILE | false | Whether enable Nginx sendfile. |
119+
| Name | Default | Description |
120+
| --- | --- |-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
121+
| DB_URL | | The URL of PostgreSQL database. You must set this environment variable if you use PostgreSQL as database. |
122+
| CABLE_DB_URL | | The URL of Pub/Sub database. You must set this environment variable if you use PostgreSQL as database. |
123+
| QUEUE_DB_URL | | The URL of background job database. You must set this environment variable if you use PostgreSQL as database. |
124+
| CACHE_DB_URL | | The URL of cache database. You must set this environment variable if you use PostgreSQL as database. |
125+
| MEDIA_PATH | | You can use this environment variable to set media path for Black Candy, otherwise you can set media path in settings page. |
126+
| DB_ADAPTER | "sqlite" | There are two adapters are supported, "sqlite" and "postgresql". |
155127
| SECRET_KEY_BASE | | When the SECRET_KEY_BASE environment variable is not set, Black candy will generate SECRET_KEY_BASE environment variable every time when service start up. This will cause old sessions invalid, You can set your own SECRET_KEY_BASE environment variable on docker service to avoid it. |
156-
| FORCE_SSL | false | Force all access to the app over SSL. |
157-
| DEMO_MODE | false | Whether to enable demo mode, when demo mode is on, all users cannot access administrator privileges, even user is admin. And also users cannot change their profile. |
128+
| FORCE_SSL | false | Force all access to the app over SSL. |
129+
| DEMO_MODE | false | Whether to enable demo mode, when demo mode is on, all users cannot access administrator privileges, even user is admin. And also users cannot change their profile. |
158130

159131
## Edge Version
160132

@@ -213,9 +185,8 @@ $ rails lint:all
213185

214186
Black Candy support get artist and album image from Discogs API. You can create an API token from Discogs and set Discogs token on Setting page to enable it.
215187

216-
## Sponsorship
188+
## Sponsorship
217189

218190
This project is supported by:
219191

220-
<a href="https://www.digitalocean.com/"><img src="https://opensource.nyc3.cdn.digitaloceanspaces.com/attribution/assets/SVG/DO_Logo_horizontal_blue.svg" width="200px"></a>
221-
<a href="https://www.jetbrains.com/community/opensource"><img src="https://resources.jetbrains.com/storage/products/company/brand/logos/jb_square.svg"></a>
192+
<a href="https://www.jetbrains.com/community/opensource"><img src="https://resources.jetbrains.com/storage/products/company/brand/logos/jb_square.svg"></a>

docs/edge_upgrade.md

Lines changed: 0 additions & 29 deletions
This file was deleted.

0 commit comments

Comments
 (0)