mirror of
https://github.com/linuxserver/docker-librespeed.git
synced 2026-02-05 11:28:06 +08:00
Compare commits
313 Commits
5.2.2-ls41
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
0af9fb3843 | ||
|
|
23d787e38a | ||
|
|
1e653525c5 | ||
|
|
2f1440e5b2 | ||
|
|
a6cae78234 | ||
|
|
eda8ed702c | ||
|
|
9c9aa4e8d4 | ||
|
|
62d6ff57e9 | ||
|
|
ce752942b7 | ||
|
|
829c166ebc | ||
|
|
3482fb8fd0 | ||
|
|
8a99f2fa77 | ||
|
|
1e5945ddb6 | ||
|
|
5cca129fe0 | ||
|
|
423c2717e0 | ||
|
|
96e202d210 | ||
|
|
7a1166efeb | ||
|
|
f3289fbcb7 | ||
|
|
61cd94a972 | ||
|
|
58b81bbee3 | ||
|
|
a08f4c9a21 | ||
|
|
029934e0fa | ||
|
|
07a63030a6 | ||
|
|
f3a52b3431 | ||
|
|
e13d1ed2cd | ||
|
|
3c98530c10 | ||
|
|
5cd263f3bd | ||
|
|
8104707c69 | ||
|
|
c7a3d2b2cc | ||
|
|
8f5e5b97db | ||
|
|
d9dc6a91ea | ||
|
|
78eb212cbc | ||
|
|
1fc3dfab4c | ||
|
|
d73ce997d7 | ||
|
|
ac5ead1c5d | ||
|
|
a9e49b8877 | ||
|
|
b051882a22 | ||
|
|
97f2d16d59 | ||
|
|
a5e23d0523 | ||
|
|
7bb5c1a96f | ||
|
|
c3af8fc175 | ||
|
|
775d6b4969 | ||
|
|
5d676ccb65 | ||
|
|
9f86411739 | ||
|
|
16dbc39b92 | ||
|
|
7939e9dabc | ||
|
|
776c3332d3 | ||
|
|
d301781918 | ||
|
|
56e64e5c85 | ||
|
|
1f529388d3 | ||
|
|
e9beb00dff | ||
|
|
95def58b00 | ||
|
|
fa3a79e40a | ||
|
|
a2d50a6c13 | ||
|
|
ba5ce1b966 | ||
|
|
74e2580a8e | ||
|
|
24e653cdc9 | ||
|
|
16d75460bc | ||
|
|
d2f7affc6e | ||
|
|
c562d93552 | ||
|
|
bc33c46f53 | ||
|
|
f4334057f6 | ||
|
|
b2903921d8 | ||
|
|
c1c19d386c | ||
|
|
4bbbeefdf7 | ||
|
|
4ec383a903 | ||
|
|
b77098ceae | ||
|
|
98c3370841 | ||
|
|
9a35111101 | ||
|
|
fbcfa99c54 | ||
|
|
d31608ea94 | ||
|
|
8a2b3d51f1 | ||
|
|
51c01db172 | ||
|
|
0e224932bb | ||
|
|
5bebe6563d | ||
|
|
766ef285f8 | ||
|
|
02302e6ab9 | ||
|
|
1324b41bb2 | ||
|
|
4fa1652686 | ||
|
|
48b594f9d7 | ||
|
|
5a8a422a41 | ||
|
|
fe2751834a | ||
|
|
51c490cdcb | ||
|
|
3ec89e70a5 | ||
|
|
be7d07d98f | ||
|
|
2eec1a9453 | ||
|
|
4af28ae322 | ||
|
|
1ab369f47c | ||
|
|
efd7168624 | ||
|
|
02f440be1b | ||
|
|
5515afc9e3 | ||
|
|
8f1149020d | ||
|
|
42acb4c827 | ||
|
|
f08be17734 | ||
|
|
79bf392b08 | ||
|
|
a4c938d2a5 | ||
|
|
554cfa6eb4 | ||
|
|
9743c34f48 | ||
|
|
f72ed2aa21 | ||
|
|
e0f2173971 | ||
|
|
35fa615a93 | ||
|
|
d51b332033 | ||
|
|
feb99a2c6e | ||
|
|
c36a1f3d5a | ||
|
|
dfa20e93b8 | ||
|
|
02006ba857 | ||
|
|
5dd8ddacd8 | ||
|
|
44b6dbe6f2 | ||
|
|
facb7c7874 | ||
|
|
822ac17790 | ||
|
|
be7653c872 | ||
|
|
0efc70cc4c | ||
|
|
d363577478 | ||
|
|
5e35738d88 | ||
|
|
4247ac009f | ||
|
|
f8d4f47673 | ||
|
|
c85d0987bd | ||
|
|
4b58c81607 | ||
|
|
7ca823fe13 | ||
|
|
b7e2340096 | ||
|
|
0194fd6d4c | ||
|
|
f9c0abb1a5 | ||
|
|
65ca524c62 | ||
|
|
59449bcac5 | ||
|
|
f0929d66ad | ||
|
|
d1223dc650 | ||
|
|
286ab1ea08 | ||
|
|
7326f17e77 | ||
|
|
37e6db2325 | ||
|
|
d64f416625 | ||
|
|
44a6a5e065 | ||
|
|
1500497cc6 | ||
|
|
92d4a42113 | ||
|
|
0582e90e54 | ||
|
|
d48b43bc8b | ||
|
|
f2ae1331e8 | ||
|
|
3e69e87f36 | ||
|
|
49e9224710 | ||
|
|
3e9e4f55e3 | ||
|
|
600902f899 | ||
|
|
8bcf066d17 | ||
|
|
02ec833ced | ||
|
|
f6d25e54ec | ||
|
|
1087c351a6 | ||
|
|
748cd2f067 | ||
|
|
75cc2e9e6e | ||
|
|
8848365b20 | ||
|
|
bc163cf85c | ||
|
|
48b5d1c6dd | ||
|
|
55cebed8d4 | ||
|
|
5f4c1a6cf0 | ||
|
|
d0e3cfae2d | ||
|
|
50ad92d139 | ||
|
|
9641fc4900 | ||
|
|
b4b0dd15de | ||
|
|
456088d2fd | ||
|
|
38a7f43699 | ||
|
|
7b7ecdc966 | ||
|
|
4e5d560d84 | ||
|
|
89feb75154 | ||
|
|
6b7544a21b | ||
|
|
0377880f63 | ||
|
|
6d86e7e4dd | ||
|
|
479def07aa | ||
|
|
59c68f68cd | ||
|
|
369f8f329f | ||
|
|
0f505d36b0 | ||
|
|
51bdd8de0a | ||
|
|
f331a66abf | ||
|
|
d3431389ac | ||
|
|
5b85e61fb5 | ||
|
|
c51859971d | ||
|
|
10607691f6 | ||
|
|
a4d56400e1 | ||
|
|
111ec746d3 | ||
|
|
29ae1394f2 | ||
|
|
9c44eab697 | ||
|
|
70f66ea39b | ||
|
|
edd4e38be7 | ||
|
|
3e4a2f77a2 | ||
|
|
4c467d7d08 | ||
|
|
35ba5b9049 | ||
|
|
5b8d8c4a4d | ||
|
|
e82c9b8e8e | ||
|
|
264ace608f | ||
|
|
c6ba9a6416 | ||
|
|
a5df5885e6 | ||
|
|
38cbd5748d | ||
|
|
0f399e2a12 | ||
|
|
25ea517aec | ||
|
|
41a8011efe | ||
|
|
62c9c92e60 | ||
|
|
73f421cf13 | ||
|
|
bf40e99d5c | ||
|
|
c41bee28e0 | ||
|
|
7dd77d7bce | ||
|
|
b91b9faef3 | ||
|
|
d3cbec32cb | ||
|
|
2bc1fba3e2 | ||
|
|
1bc0d2b6f7 | ||
|
|
98f8df3a90 | ||
|
|
5c80c8e974 | ||
|
|
f8d054781d | ||
|
|
7b7fbd2731 | ||
|
|
724bd72022 | ||
|
|
267c6bc572 | ||
|
|
ed00ec0a4a | ||
|
|
62180e4bc2 | ||
|
|
a790790cf5 | ||
|
|
0fdefbe88f | ||
|
|
5ba43993bd | ||
|
|
67749ac6e9 | ||
|
|
dd205aaf43 | ||
|
|
be8a76e5dd | ||
|
|
a42d8b782a | ||
|
|
b39f96ba25 | ||
|
|
6b042bbc4b | ||
|
|
2a85eb3983 | ||
|
|
05398fe9cd | ||
|
|
bb570b004c | ||
|
|
4692da6925 | ||
|
|
09f2485594 | ||
|
|
f8dbe4517c | ||
|
|
ee44968e62 | ||
|
|
7e13a1106b | ||
|
|
c73f9f1f84 | ||
|
|
95294c15d9 | ||
|
|
f6fe54901e | ||
|
|
a654559292 | ||
|
|
36942677ae | ||
|
|
1568d8600f | ||
|
|
7f07d95964 | ||
|
|
5a6e56b01a | ||
|
|
10f800f1cf | ||
|
|
0197832e9b | ||
|
|
71ee254fb4 | ||
|
|
4ccc943429 | ||
|
|
43f19a84d9 | ||
|
|
6487c842f2 | ||
|
|
47356ee98a | ||
|
|
c348f0ee6f | ||
|
|
b10225b1a0 | ||
|
|
9fa036384b | ||
|
|
2750a810c2 | ||
|
|
a9e1b1dff3 | ||
|
|
97eb7aab7d | ||
|
|
3e11516a82 | ||
|
|
650256ee8b | ||
|
|
8b1ba7749a | ||
|
|
e5a857004c | ||
|
|
84e7cd7a3e | ||
|
|
95b53e11bd | ||
|
|
2f70f45ca3 | ||
|
|
e26ac50de6 | ||
|
|
3459429386 | ||
|
|
e9a99be352 | ||
|
|
2fef70ddd6 | ||
|
|
8d278082e8 | ||
|
|
ccf2235d9a | ||
|
|
c8355bd2ae | ||
|
|
ee00e2cbae | ||
|
|
932e45425a | ||
|
|
bc07f85266 | ||
|
|
d95492463c | ||
|
|
b4b0ab5b89 | ||
|
|
1052087bb9 | ||
|
|
67d4fa1bf0 | ||
|
|
13eaf5b5e9 | ||
|
|
99339e0776 | ||
|
|
b22529959c | ||
|
|
45660378ef | ||
|
|
12c91e12e4 | ||
|
|
2a503d037b | ||
|
|
ccfffe5b7e | ||
|
|
7131e616d1 | ||
|
|
1d3163c6fc | ||
|
|
277cca0039 | ||
|
|
6b89f55fd6 | ||
|
|
df644cba7d | ||
|
|
e5409e993f | ||
|
|
e7696b4b68 | ||
|
|
eee8e3db5b | ||
|
|
7b22f0dad8 | ||
|
|
18a7899abe | ||
|
|
4fd0a4c0b3 | ||
|
|
49c59b5e7a | ||
|
|
62a088a7ce | ||
|
|
98313e5497 | ||
|
|
bf2e0d5d08 | ||
|
|
0eedf439b2 | ||
|
|
aa92f318a8 | ||
|
|
4de0a4bc35 | ||
|
|
43f8fa50f3 | ||
|
|
57f0af41e3 | ||
|
|
ccccc425ef | ||
|
|
fe1df05881 | ||
|
|
930816761d | ||
|
|
8347dd995e | ||
|
|
9cda8fb552 | ||
|
|
f44dd349d7 | ||
|
|
5590fceeb4 | ||
|
|
0ac708bd94 | ||
|
|
d61943d6bb | ||
|
|
23fd1d89e6 | ||
|
|
8dbac00ad7 | ||
|
|
c75418788d | ||
|
|
7a34c42b6c | ||
|
|
e5a0b6f817 | ||
|
|
46aaeeaee4 | ||
|
|
8998aba989 | ||
|
|
666a425320 | ||
|
|
416c303b21 | ||
|
|
534eb361f2 |
20
.editorconfig
Normal file
20
.editorconfig
Normal file
@ -0,0 +1,20 @@
|
||||
# This file is globally distributed to all container image projects from
|
||||
# https://github.com/linuxserver/docker-jenkins-builder/blob/master/.editorconfig
|
||||
|
||||
# top-most EditorConfig file
|
||||
root = true
|
||||
|
||||
# Unix-style newlines with a newline ending every file
|
||||
[*]
|
||||
end_of_line = lf
|
||||
insert_final_newline = true
|
||||
# trim_trailing_whitespace may cause unintended issues and should not be globally set true
|
||||
trim_trailing_whitespace = false
|
||||
|
||||
[{Dockerfile*,**.yml}]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
||||
[{**.sh,root/etc/s6-overlay/s6-rc.d/**,root/etc/cont-init.d/**,root/etc/services.d/**}]
|
||||
indent_style = space
|
||||
indent_size = 4
|
||||
15
.github/CONTRIBUTING.md
vendored
Executable file → Normal file
15
.github/CONTRIBUTING.md
vendored
Executable file → Normal file
@ -4,9 +4,9 @@
|
||||
|
||||
* While contributing make sure to make all your changes before creating a Pull Request, as our pipeline builds each commit after the PR is open.
|
||||
* Read, and fill the Pull Request template
|
||||
* If this is a fix for a typo in code or documentation in the README please file an issue
|
||||
* If this is a fix for a typo (in code, documentation, or the README) please file an issue and let us sort it out. We do not need a PR
|
||||
* If the PR is addressing an existing issue include, closes #\<issue number>, in the body of the PR commit message
|
||||
* If you want to discuss changes, you can also bring it up in [#dev-talk](https://discordapp.com/channels/354974912613449730/757585807061155840) in our [Discord server](https://discord.gg/YWrKVTn)
|
||||
* If you want to discuss changes, you can also bring it up in [#dev-talk](https://discordapp.com/channels/354974912613449730/757585807061155840) in our [Discord server](https://linuxserver.io/discord)
|
||||
|
||||
## Common files
|
||||
|
||||
@ -96,7 +96,7 @@ If you are proposing additional packages to be added, ensure that you added the
|
||||
|
||||
### Testing your changes
|
||||
|
||||
```
|
||||
```bash
|
||||
git clone https://github.com/linuxserver/docker-librespeed.git
|
||||
cd docker-librespeed
|
||||
docker build \
|
||||
@ -105,14 +105,15 @@ docker build \
|
||||
-t linuxserver/librespeed:latest .
|
||||
```
|
||||
|
||||
The ARM variants can be built on x86_64 hardware using `multiarch/qemu-user-static`
|
||||
```
|
||||
docker run --rm --privileged multiarch/qemu-user-static:register --reset
|
||||
The ARM variants can be built on x86_64 hardware and vice versa using `lscr.io/linuxserver/qemu-static`
|
||||
|
||||
```bash
|
||||
docker run --rm --privileged lscr.io/linuxserver/qemu-static --reset
|
||||
```
|
||||
|
||||
Once registered you can define the dockerfile to use with `-f Dockerfile.aarch64`.
|
||||
|
||||
## Update the chagelog
|
||||
## Update the changelog
|
||||
|
||||
If you are modifying the Dockerfiles or any of the startup scripts in [root](https://github.com/linuxserver/docker-librespeed/tree/master/root), add an entry to the changelog
|
||||
|
||||
|
||||
0
.github/FUNDING.yml
vendored
Executable file → Normal file
0
.github/FUNDING.yml
vendored
Executable file → Normal file
2
.github/ISSUE_TEMPLATE/config.yml
vendored
Executable file → Normal file
2
.github/ISSUE_TEMPLATE/config.yml
vendored
Executable file → Normal file
@ -1,7 +1,7 @@
|
||||
blank_issues_enabled: false
|
||||
contact_links:
|
||||
- name: Discord chat support
|
||||
url: https://discord.gg/YWrKVTn
|
||||
url: https://linuxserver.io/discord
|
||||
about: Realtime support / chat with the community and the team.
|
||||
|
||||
- name: Discourse discussion forum
|
||||
|
||||
40
.github/ISSUE_TEMPLATE/issue.bug.md
vendored
40
.github/ISSUE_TEMPLATE/issue.bug.md
vendored
@ -1,40 +0,0 @@
|
||||
---
|
||||
name: Bug report
|
||||
about: Create a report to help us improve
|
||||
|
||||
---
|
||||
[linuxserverurl]: https://linuxserver.io
|
||||
[][linuxserverurl]
|
||||
|
||||
<!--- If you are new to Docker or this application our issue tracker is **ONLY** used for reporting bugs or requesting features. Please use [our discord server](https://discord.gg/YWrKVTn) for general support. --->
|
||||
|
||||
<!--- Provide a general summary of the bug in the Title above -->
|
||||
|
||||
------------------------------
|
||||
|
||||
## Expected Behavior
|
||||
<!--- Tell us what should happen -->
|
||||
|
||||
## Current Behavior
|
||||
<!--- Tell us what happens instead of the expected behavior -->
|
||||
|
||||
## Steps to Reproduce
|
||||
<!--- Provide a link to a live example, or an unambiguous set of steps to -->
|
||||
<!--- reproduce this bug. Include code to reproduce, if relevant -->
|
||||
1.
|
||||
2.
|
||||
3.
|
||||
4.
|
||||
|
||||
## Environment
|
||||
**OS:**
|
||||
**CPU architecture:** x86_64/arm32/arm64
|
||||
**How docker service was installed:**
|
||||
<!--- ie. from the official docker repo, from the distro repo, nas OS provided, etc. -->
|
||||
<!--- Providing context helps us come up with a solution that is most useful in the real world -->
|
||||
|
||||
## Command used to create docker container (run/create/compose/screenshot)
|
||||
<!--- Provide your docker create/run command or compose yaml snippet, or a screenshot of settings if using a gui to create the container -->
|
||||
|
||||
## Docker logs
|
||||
<!--- Provide a full docker log, output of "docker logs librespeed" -->
|
||||
76
.github/ISSUE_TEMPLATE/issue.bug.yml
vendored
Normal file
76
.github/ISSUE_TEMPLATE/issue.bug.yml
vendored
Normal file
@ -0,0 +1,76 @@
|
||||
# Based on the issue template
|
||||
name: Bug report
|
||||
description: Create a report to help us improve
|
||||
title: "[BUG] <title>"
|
||||
labels: [Bug]
|
||||
body:
|
||||
- type: checkboxes
|
||||
attributes:
|
||||
label: Is there an existing issue for this?
|
||||
description: Please search to see if an issue already exists for the bug you encountered.
|
||||
options:
|
||||
- label: I have searched the existing issues
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Current Behavior
|
||||
description: Tell us what happens instead of the expected behavior.
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Expected Behavior
|
||||
description: Tell us what should happen.
|
||||
validations:
|
||||
required: false
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Steps To Reproduce
|
||||
description: Steps to reproduce the behavior.
|
||||
placeholder: |
|
||||
1. In this environment...
|
||||
2. With this config...
|
||||
3. Run '...'
|
||||
4. See error...
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Environment
|
||||
description: |
|
||||
examples:
|
||||
- **OS**: Ubuntu 20.04
|
||||
- **How docker service was installed**: distro's packagemanager
|
||||
value: |
|
||||
- OS:
|
||||
- How docker service was installed:
|
||||
render: markdown
|
||||
validations:
|
||||
required: false
|
||||
- type: dropdown
|
||||
attributes:
|
||||
label: CPU architecture
|
||||
options:
|
||||
- x86-64
|
||||
- arm64
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Docker creation
|
||||
description: |
|
||||
Command used to create docker container
|
||||
Provide your docker create/run command or compose yaml snippet, or a screenshot of settings if using a gui to create the container
|
||||
render: bash
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
description: |
|
||||
Provide a full docker log, output of "docker logs librespeed"
|
||||
label: Container logs
|
||||
placeholder: |
|
||||
Output of `docker logs librespeed`
|
||||
render: bash
|
||||
validations:
|
||||
required: true
|
||||
25
.github/ISSUE_TEMPLATE/issue.feature.md
vendored
25
.github/ISSUE_TEMPLATE/issue.feature.md
vendored
@ -1,25 +0,0 @@
|
||||
---
|
||||
name: Feature request
|
||||
about: Suggest an idea for this project
|
||||
|
||||
---
|
||||
[linuxserverurl]: https://linuxserver.io
|
||||
[][linuxserverurl]
|
||||
|
||||
<!--- If you are new to Docker or this application our issue tracker is **ONLY** used for reporting bugs or requesting features. Please use [our discord server](https://discord.gg/YWrKVTn) for general support. --->
|
||||
|
||||
<!--- If this acts as a feature request please ask yourself if this modification is something the whole userbase will benefit from --->
|
||||
<!--- If this is a specific change for corner case functionality or plugins please look at making a Docker Mod or local script https://blog.linuxserver.io/2019/09/14/customizing-our-containers/ -->
|
||||
|
||||
<!--- Provide a general summary of the request in the Title above -->
|
||||
|
||||
------------------------------
|
||||
|
||||
## Desired Behavior
|
||||
<!--- Tell us what should happen -->
|
||||
|
||||
## Current Behavior
|
||||
<!--- Tell us what happens instead of the expected behavior -->
|
||||
|
||||
## Alternatives Considered
|
||||
<!--- Tell us what other options you have tried or considered -->
|
||||
31
.github/ISSUE_TEMPLATE/issue.feature.yml
vendored
Normal file
31
.github/ISSUE_TEMPLATE/issue.feature.yml
vendored
Normal file
@ -0,0 +1,31 @@
|
||||
# Based on the issue template
|
||||
name: Feature request
|
||||
description: Suggest an idea for this project
|
||||
title: "[FEAT] <title>"
|
||||
labels: [enhancement]
|
||||
body:
|
||||
- type: checkboxes
|
||||
attributes:
|
||||
label: Is this a new feature request?
|
||||
description: Please search to see if a feature request already exists.
|
||||
options:
|
||||
- label: I have searched the existing issues
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Wanted change
|
||||
description: Tell us what you want to happen.
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Reason for change
|
||||
description: Justify your request, why do you want it, what is the benefit.
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Proposed code change
|
||||
description: Do you have a potential code change in mind?
|
||||
validations:
|
||||
required: false
|
||||
2
.github/PULL_REQUEST_TEMPLATE.md
vendored
2
.github/PULL_REQUEST_TEMPLATE.md
vendored
@ -6,7 +6,7 @@
|
||||
|
||||
<!--- Before submitting a pull request please check the following -->
|
||||
|
||||
<!--- If this is a fix for a typo in code or documentation in the README please file an issue and let us sort it out we do not need a PR -->
|
||||
<!--- If this is a fix for a typo (in code, documentation, or the README) please file an issue and let us sort it out. We do not need a PR -->
|
||||
<!--- Ask yourself if this modification is something the whole userbase will benefit from, if this is a specific change for corner case functionality or plugins please look at making a Docker Mod or local script https://blog.linuxserver.io/2019/09/14/customizing-our-containers/ -->
|
||||
<!--- That if the PR is addressing an existing issue include, closes #<issue number> , in the body of the PR commit message -->
|
||||
<!--- You have included links to any files / patches etc your PR may be using in the body of the PR commit message -->
|
||||
|
||||
19
.github/workflows/call_issue_pr_tracker.yml
vendored
Normal file
19
.github/workflows/call_issue_pr_tracker.yml
vendored
Normal file
@ -0,0 +1,19 @@
|
||||
name: Issue & PR Tracker
|
||||
|
||||
on:
|
||||
issues:
|
||||
types: [opened,reopened,labeled,unlabeled,closed]
|
||||
pull_request_target:
|
||||
types: [opened,reopened,review_requested,review_request_removed,labeled,unlabeled,closed]
|
||||
pull_request_review:
|
||||
types: [submitted,edited,dismissed]
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
|
||||
jobs:
|
||||
manage-project:
|
||||
permissions:
|
||||
issues: write
|
||||
uses: linuxserver/github-workflows/.github/workflows/issue-pr-tracker.yml@v1
|
||||
secrets: inherit
|
||||
16
.github/workflows/call_issues_cron.yml
vendored
Normal file
16
.github/workflows/call_issues_cron.yml
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
name: Mark stale issues and pull requests
|
||||
on:
|
||||
schedule:
|
||||
- cron: '11 2 * * *'
|
||||
workflow_dispatch:
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
|
||||
jobs:
|
||||
stale:
|
||||
permissions:
|
||||
issues: write
|
||||
pull-requests: write
|
||||
uses: linuxserver/github-workflows/.github/workflows/issues-cron.yml@v1
|
||||
secrets: inherit
|
||||
148
.github/workflows/external_trigger.yml
vendored
Executable file → Normal file
148
.github/workflows/external_trigger.yml
vendored
Executable file → Normal file
@ -3,89 +3,145 @@ name: External Trigger Main
|
||||
on:
|
||||
workflow_dispatch:
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
|
||||
jobs:
|
||||
external-trigger-master:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2.3.3
|
||||
- uses: actions/checkout@v4.1.1
|
||||
|
||||
- name: External Trigger
|
||||
if: github.ref == 'refs/heads/master'
|
||||
env:
|
||||
SKIP_EXTERNAL_TRIGGER: ${{ vars.SKIP_EXTERNAL_TRIGGER }}
|
||||
run: |
|
||||
if [ -n "${{ secrets.PAUSE_EXTERNAL_TRIGGER_LIBRESPEED_MASTER }}" ]; then
|
||||
echo "**** Github secret PAUSE_EXTERNAL_TRIGGER_LIBRESPEED_MASTER is set; skipping trigger. ****"
|
||||
printf "# External trigger for docker-librespeed\n\n" >> $GITHUB_STEP_SUMMARY
|
||||
if grep -q "^librespeed_master_" <<< "${SKIP_EXTERNAL_TRIGGER}"; then
|
||||
echo "> [!NOTE]" >> $GITHUB_STEP_SUMMARY
|
||||
echo "> Github organizational variable \`SKIP_EXTERNAL_TRIGGER\` contains \`librespeed_master_\`; will skip trigger if version matches." >> $GITHUB_STEP_SUMMARY
|
||||
elif grep -q "^librespeed_master" <<< "${SKIP_EXTERNAL_TRIGGER}"; then
|
||||
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
||||
echo "> Github organizational variable \`SKIP_EXTERNAL_TRIGGER\` contains \`librespeed_master\`; skipping trigger." >> $GITHUB_STEP_SUMMARY
|
||||
exit 0
|
||||
fi
|
||||
echo "**** External trigger running off of master branch. To disable this trigger, set a Github secret named \"PAUSE_EXTERNAL_TRIGGER_LIBRESPEED_MASTER\". ****"
|
||||
echo "**** Retrieving external version ****"
|
||||
echo "> [!NOTE]" >> $GITHUB_STEP_SUMMARY
|
||||
echo "> External trigger running off of master branch. To disable this trigger, add \`librespeed_master\` into the Github organizational variable \`SKIP_EXTERNAL_TRIGGER\`." >> $GITHUB_STEP_SUMMARY
|
||||
printf "\n## Retrieving external version\n\n" >> $GITHUB_STEP_SUMMARY
|
||||
EXT_RELEASE=$(curl -u "${{ secrets.CR_USER }}:${{ secrets.CR_PAT }}" -sX GET "https://api.github.com/repos/librespeed/speedtest/releases/latest" | jq -r '. | .tag_name')
|
||||
echo "Type is \`github_stable\`" >> $GITHUB_STEP_SUMMARY
|
||||
if grep -q "^librespeed_master_${EXT_RELEASE}" <<< "${SKIP_EXTERNAL_TRIGGER}"; then
|
||||
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
||||
echo "> Github organizational variable \`SKIP_EXTERNAL_TRIGGER\` matches current external release; skipping trigger." >> $GITHUB_STEP_SUMMARY
|
||||
exit 0
|
||||
fi
|
||||
if [ -z "${EXT_RELEASE}" ] || [ "${EXT_RELEASE}" == "null" ]; then
|
||||
echo "**** Can't retrieve external version, exiting ****"
|
||||
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
||||
echo "> Can't retrieve external version, exiting" >> $GITHUB_STEP_SUMMARY
|
||||
FAILURE_REASON="Can't retrieve external version for librespeed branch master"
|
||||
GHA_TRIGGER_URL="https://github.com/linuxserver/docker-librespeed/actions/runs/${{ github.run_id }}"
|
||||
curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://cdn.discordapp.com/avatars/354986384542662657/df91181b3f1cf0ef1592fbe18e0962d7.png","embeds": [{"color": 16711680,
|
||||
"description": "**Trigger Failed** \n**Reason:** '"${FAILURE_REASON}"' \n"}],
|
||||
"description": "**Trigger Failed** \n**Reason:** '"${FAILURE_REASON}"' \n**Trigger URL:** '"${GHA_TRIGGER_URL}"' \n"}],
|
||||
"username": "Github Actions"}' ${{ secrets.DISCORD_WEBHOOK }}
|
||||
exit 1
|
||||
fi
|
||||
EXT_RELEASE=$(echo ${EXT_RELEASE} | sed 's/[~,%@+;:/]//g')
|
||||
echo "**** External version: ${EXT_RELEASE} ****"
|
||||
echo "**** Retrieving last pushed version ****"
|
||||
EXT_RELEASE_SANITIZED=$(echo ${EXT_RELEASE} | sed 's/[~,%@+;:/]//g')
|
||||
echo "Sanitized external version: \`${EXT_RELEASE_SANITIZED}\`" >> $GITHUB_STEP_SUMMARY
|
||||
echo "Retrieving last pushed version" >> $GITHUB_STEP_SUMMARY
|
||||
image="linuxserver/librespeed"
|
||||
tag="latest"
|
||||
token=$(curl -sX GET \
|
||||
"https://ghcr.io/token?scope=repository%3Alinuxserver%2Flibrespeed%3Apull" \
|
||||
| jq -r '.token')
|
||||
multidigest=$(curl -s \
|
||||
multidigest=$(curl -s \
|
||||
--header "Accept: application/vnd.docker.distribution.manifest.v2+json" \
|
||||
--header "Accept: application/vnd.oci.image.index.v1+json" \
|
||||
--header "Authorization: Bearer ${token}" \
|
||||
"https://ghcr.io/v2/${image}/manifests/${tag}")
|
||||
if jq -e '.layers // empty' <<< "${multidigest}" >/dev/null 2>&1; then
|
||||
# If there's a layer element it's a single-arch manifest so just get that digest
|
||||
digest=$(jq -r '.config.digest' <<< "${multidigest}")
|
||||
else
|
||||
# Otherwise it's multi-arch or has manifest annotations
|
||||
if jq -e '.manifests[]?.annotations // empty' <<< "${multidigest}" >/dev/null 2>&1; then
|
||||
# Check for manifest annotations and delete if found
|
||||
multidigest=$(jq 'del(.manifests[] | select(.annotations))' <<< "${multidigest}")
|
||||
fi
|
||||
if [[ $(jq '.manifests | length' <<< "${multidigest}") -gt 1 ]]; then
|
||||
# If there's still more than one digest, it's multi-arch
|
||||
multidigest=$(jq -r ".manifests[] | select(.platform.architecture == \"amd64\").digest?" <<< "${multidigest}")
|
||||
else
|
||||
# Otherwise it's single arch
|
||||
multidigest=$(jq -r ".manifests[].digest?" <<< "${multidigest}")
|
||||
fi
|
||||
if digest=$(curl -s \
|
||||
--header "Accept: application/vnd.docker.distribution.manifest.v2+json" \
|
||||
--header "Accept: application/vnd.oci.image.manifest.v1+json" \
|
||||
--header "Authorization: Bearer ${token}" \
|
||||
"https://ghcr.io/v2/${image}/manifests/${tag}" \
|
||||
| jq -r 'first(.manifests[].digest)')
|
||||
digest=$(curl -s \
|
||||
--header "Accept: application/vnd.docker.distribution.manifest.v2+json" \
|
||||
--header "Authorization: Bearer ${token}" \
|
||||
"https://ghcr.io/v2/${image}/manifests/${multidigest}" \
|
||||
| jq -r '.config.digest')
|
||||
"https://ghcr.io/v2/${image}/manifests/${multidigest}"); then
|
||||
digest=$(jq -r '.config.digest' <<< "${digest}");
|
||||
fi
|
||||
fi
|
||||
image_info=$(curl -sL \
|
||||
--header "Authorization: Bearer ${token}" \
|
||||
"https://ghcr.io/v2/${image}/blobs/${digest}" \
|
||||
| jq -r '.container_config')
|
||||
"https://ghcr.io/v2/${image}/blobs/${digest}")
|
||||
if [[ $(echo $image_info | jq -r '.container_config') == "null" ]]; then
|
||||
image_info=$(echo $image_info | jq -r '.config')
|
||||
else
|
||||
image_info=$(echo $image_info | jq -r '.container_config')
|
||||
fi
|
||||
IMAGE_RELEASE=$(echo ${image_info} | jq -r '.Labels.build_version' | awk '{print $3}')
|
||||
IMAGE_VERSION=$(echo ${IMAGE_RELEASE} | awk -F'-ls' '{print $1}')
|
||||
if [ -z "${IMAGE_VERSION}" ]; then
|
||||
echo "**** Can't retrieve last pushed version, exiting ****"
|
||||
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
||||
echo "Can't retrieve last pushed version, exiting" >> $GITHUB_STEP_SUMMARY
|
||||
FAILURE_REASON="Can't retrieve last pushed version for librespeed tag latest"
|
||||
curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://cdn.discordapp.com/avatars/354986384542662657/df91181b3f1cf0ef1592fbe18e0962d7.png","embeds": [{"color": 16711680,
|
||||
"description": "**Trigger Failed** \n**Reason:** '"${FAILURE_REASON}"' \n"}],
|
||||
"username": "Github Actions"}' ${{ secrets.DISCORD_WEBHOOK }}
|
||||
exit 1
|
||||
fi
|
||||
echo "**** Last pushed version: ${IMAGE_VERSION} ****"
|
||||
if [ "${EXT_RELEASE}" == "${IMAGE_VERSION}" ]; then
|
||||
echo "**** Version ${EXT_RELEASE} already pushed, exiting ****"
|
||||
echo "Last pushed version: \`${IMAGE_VERSION}\`" >> $GITHUB_STEP_SUMMARY
|
||||
if [ "${EXT_RELEASE_SANITIZED}" == "${IMAGE_VERSION}" ]; then
|
||||
echo "Sanitized version \`${EXT_RELEASE_SANITIZED}\` already pushed, exiting" >> $GITHUB_STEP_SUMMARY
|
||||
exit 0
|
||||
elif [ $(curl -s https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-librespeed/job/master/lastBuild/api/json | jq -r '.building') == "true" ]; then
|
||||
echo "**** New version ${EXT_RELEASE} found; but there already seems to be an active build on Jenkins; exiting ****"
|
||||
echo "New version \`${EXT_RELEASE}\` found; but there already seems to be an active build on Jenkins; exiting" >> $GITHUB_STEP_SUMMARY
|
||||
exit 0
|
||||
else
|
||||
echo "**** New version ${EXT_RELEASE} found; old version was ${IMAGE_VERSION}. Triggering new build ****"
|
||||
response=$(curl -iX POST \
|
||||
https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-librespeed/job/master/buildWithParameters?PACKAGE_CHECK=false \
|
||||
--user ${{ secrets.JENKINS_USER }}:${{ secrets.JENKINS_TOKEN }} | grep -i location | sed "s|^[L|l]ocation: \(.*\)|\1|")
|
||||
echo "**** Jenkins job queue url: ${response%$'\r'} ****"
|
||||
echo "**** Sleeping 10 seconds until job starts ****"
|
||||
sleep 10
|
||||
buildurl=$(curl -s "${response%$'\r'}api/json" | jq -r '.executable.url')
|
||||
buildurl="${buildurl%$'\r'}"
|
||||
echo "**** Jenkins job build url: ${buildurl} ****"
|
||||
echo "**** Attempting to change the Jenkins job description ****"
|
||||
curl -iX POST \
|
||||
"${buildurl}submitDescription" \
|
||||
--user ${{ secrets.JENKINS_USER }}:${{ secrets.JENKINS_TOKEN }} \
|
||||
--data-urlencode "description=GHA external trigger https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" \
|
||||
--data-urlencode "Submit=Submit"
|
||||
echo "**** Notifying Discord ****"
|
||||
TRIGGER_REASON="A version change was detected for librespeed tag latest. Old version:${IMAGE_VERSION} New version:${EXT_RELEASE}"
|
||||
curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://cdn.discordapp.com/avatars/354986384542662657/df91181b3f1cf0ef1592fbe18e0962d7.png","embeds": [{"color": 9802903,
|
||||
"description": "**Build Triggered** \n**Reason:** '"${TRIGGER_REASON}"' \n**Build URL:** '"${buildurl}display/redirect"' \n"}],
|
||||
"username": "Github Actions"}' ${{ secrets.DISCORD_WEBHOOK }}
|
||||
if [[ "${artifacts_found}" == "false" ]]; then
|
||||
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
||||
echo "> New version detected, but not all artifacts are published yet; skipping trigger" >> $GITHUB_STEP_SUMMARY
|
||||
FAILURE_REASON="New version ${EXT_RELEASE} for librespeed tag latest is detected, however not all artifacts are uploaded to upstream release yet. Will try again later."
|
||||
curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://cdn.discordapp.com/avatars/354986384542662657/df91181b3f1cf0ef1592fbe18e0962d7.png","embeds": [{"color": 9802903,
|
||||
"description": "**Trigger Failed** \n**Reason:** '"${FAILURE_REASON}"' \n"}],
|
||||
"username": "Github Actions"}' ${{ secrets.DISCORD_WEBHOOK }}
|
||||
else
|
||||
printf "\n## Trigger new build\n\n" >> $GITHUB_STEP_SUMMARY
|
||||
echo "New sanitized version \`${EXT_RELEASE_SANITIZED}\` found; old version was \`${IMAGE_VERSION}\`. Triggering new build" >> $GITHUB_STEP_SUMMARY
|
||||
if [[ "${artifacts_found}" == "true" ]]; then
|
||||
echo "All artifacts seem to be uploaded." >> $GITHUB_STEP_SUMMARY
|
||||
fi
|
||||
response=$(curl -iX POST \
|
||||
https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-librespeed/job/master/buildWithParameters?PACKAGE_CHECK=false \
|
||||
--user ${{ secrets.JENKINS_USER }}:${{ secrets.JENKINS_TOKEN }} | grep -i location | sed "s|^[L|l]ocation: \(.*\)|\1|")
|
||||
echo "Jenkins [job queue url](${response%$'\r'})" >> $GITHUB_STEP_SUMMARY
|
||||
echo "Sleeping 10 seconds until job starts" >> $GITHUB_STEP_SUMMARY
|
||||
sleep 10
|
||||
buildurl=$(curl -s "${response%$'\r'}api/json" | jq -r '.executable.url')
|
||||
buildurl="${buildurl%$'\r'}"
|
||||
echo "Jenkins job [build url](${buildurl})" >> $GITHUB_STEP_SUMMARY
|
||||
echo "Attempting to change the Jenkins job description" >> $GITHUB_STEP_SUMMARY
|
||||
curl -iX POST \
|
||||
"${buildurl}submitDescription" \
|
||||
--user ${{ secrets.JENKINS_USER }}:${{ secrets.JENKINS_TOKEN }} \
|
||||
--data-urlencode "description=GHA external trigger https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" \
|
||||
--data-urlencode "Submit=Submit"
|
||||
echo "**** Notifying Discord ****"
|
||||
TRIGGER_REASON="A version change was detected for librespeed tag latest. Old version:${IMAGE_VERSION} New version:${EXT_RELEASE_SANITIZED}"
|
||||
curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://cdn.discordapp.com/avatars/354986384542662657/df91181b3f1cf0ef1592fbe18e0962d7.png","embeds": [{"color": 9802903,
|
||||
"description": "**Build Triggered** \n**Reason:** '"${TRIGGER_REASON}"' \n**Build URL:** '"${buildurl}display/redirect"' \n"}],
|
||||
"username": "Github Actions"}' ${{ secrets.DISCORD_WEBHOOK }}
|
||||
fi
|
||||
fi
|
||||
|
||||
37
.github/workflows/external_trigger_scheduler.yml
vendored
Executable file → Normal file
37
.github/workflows/external_trigger_scheduler.yml
vendored
Executable file → Normal file
@ -2,42 +2,47 @@ name: External Trigger Scheduler
|
||||
|
||||
on:
|
||||
schedule:
|
||||
- cron: '10 * * * *'
|
||||
- cron: '33 * * * *'
|
||||
workflow_dispatch:
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
|
||||
jobs:
|
||||
external-trigger-scheduler:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2.3.3
|
||||
- uses: actions/checkout@v4.1.1
|
||||
with:
|
||||
fetch-depth: '0'
|
||||
|
||||
- name: External Trigger Scheduler
|
||||
run: |
|
||||
echo "**** Branches found: ****"
|
||||
git for-each-ref --format='%(refname:short)' refs/remotes
|
||||
echo "**** Pulling the yq docker image ****"
|
||||
docker pull ghcr.io/linuxserver/yq
|
||||
for br in $(git for-each-ref --format='%(refname:short)' refs/remotes)
|
||||
printf "# External trigger scheduler for docker-librespeed\n\n" >> $GITHUB_STEP_SUMMARY
|
||||
printf "Found the branches:\n\n%s\n" "$(git for-each-ref --format='- %(refname:lstrip=3)' refs/remotes)" >> $GITHUB_STEP_SUMMARY
|
||||
for br in $(git for-each-ref --format='%(refname:lstrip=3)' refs/remotes)
|
||||
do
|
||||
br=$(echo "$br" | sed 's|origin/||g')
|
||||
echo "**** Evaluating branch ${br} ****"
|
||||
ls_branch=$(curl -sX GET https://raw.githubusercontent.com/linuxserver/docker-librespeed/${br}/jenkins-vars.yml \
|
||||
| docker run --rm -i --entrypoint yq ghcr.io/linuxserver/yq -r .ls_branch)
|
||||
if [ "$br" == "$ls_branch" ]; then
|
||||
echo "**** Branch ${br} appears to be live; checking workflow. ****"
|
||||
if [[ "${br}" == "HEAD" ]]; then
|
||||
printf "\nSkipping %s.\n" ${br} >> $GITHUB_STEP_SUMMARY
|
||||
continue
|
||||
fi
|
||||
printf "\n## Evaluating \`%s\`\n\n" ${br} >> $GITHUB_STEP_SUMMARY
|
||||
ls_jenkins_vars=$(curl -sX GET https://raw.githubusercontent.com/linuxserver/docker-librespeed/${br}/jenkins-vars.yml)
|
||||
ls_branch=$(echo "${ls_jenkins_vars}" | yq -r '.ls_branch')
|
||||
ls_trigger=$(echo "${ls_jenkins_vars}" | yq -r '.external_type')
|
||||
if [[ "${br}" == "${ls_branch}" ]] && [[ "${ls_trigger}" != "os" ]]; then
|
||||
echo "Branch appears to be live and trigger is not os; checking workflow." >> $GITHUB_STEP_SUMMARY
|
||||
if curl -sfX GET https://raw.githubusercontent.com/linuxserver/docker-librespeed/${br}/.github/workflows/external_trigger.yml > /dev/null 2>&1; then
|
||||
echo "**** Workflow exists. Triggering external trigger workflow for branch ${br} ****."
|
||||
echo "Triggering external trigger workflow for branch." >> $GITHUB_STEP_SUMMARY
|
||||
curl -iX POST \
|
||||
-H "Authorization: token ${{ secrets.CR_PAT }}" \
|
||||
-H "Accept: application/vnd.github.v3+json" \
|
||||
-d "{\"ref\":\"refs/heads/${br}\"}" \
|
||||
https://api.github.com/repos/linuxserver/docker-librespeed/actions/workflows/external_trigger.yml/dispatches
|
||||
else
|
||||
echo "**** Workflow doesn't exist; skipping trigger. ****"
|
||||
echo "Skipping branch due to no external trigger workflow present." >> $GITHUB_STEP_SUMMARY
|
||||
fi
|
||||
else
|
||||
echo "**** ${br} appears to be a dev branch; skipping trigger. ****"
|
||||
echo "Skipping branch due to being detected as dev branch or having no external version." >> $GITHUB_STEP_SUMMARY
|
||||
fi
|
||||
done
|
||||
|
||||
8
.github/workflows/greetings.yml
vendored
Executable file → Normal file
8
.github/workflows/greetings.yml
vendored
Executable file → Normal file
@ -2,12 +2,18 @@ name: Greetings
|
||||
|
||||
on: [pull_request_target, issues]
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
|
||||
jobs:
|
||||
greeting:
|
||||
permissions:
|
||||
issues: write
|
||||
pull-requests: write
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/first-interaction@v1
|
||||
with:
|
||||
issue-message: 'Thanks for opening your first issue here! Be sure to follow the [issue template](https://github.com/linuxserver/docker-librespeed/blob/master/.github/ISSUE_TEMPLATE.md)!'
|
||||
issue-message: 'Thanks for opening your first issue here! Be sure to follow the relevant issue templates, or risk having this issue marked as invalid.'
|
||||
pr-message: 'Thanks for opening this pull request! Be sure to follow the [pull request template](https://github.com/linuxserver/docker-librespeed/blob/master/.github/PULL_REQUEST_TEMPLATE.md)!'
|
||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
38
.github/workflows/package_trigger.yml
vendored
38
.github/workflows/package_trigger.yml
vendored
@ -1,38 +0,0 @@
|
||||
name: Package Trigger Main
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
package-trigger-master:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2.3.3
|
||||
|
||||
- name: Package Trigger
|
||||
if: github.ref == 'refs/heads/master'
|
||||
run: |
|
||||
if [ -n "${{ secrets.PAUSE_PACKAGE_TRIGGER_LIBRESPEED_MASTER }}" ]; then
|
||||
echo "**** Github secret PAUSE_PACKAGE_TRIGGER_LIBRESPEED_MASTER is set; skipping trigger. ****"
|
||||
exit 0
|
||||
fi
|
||||
if [ $(curl -s https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-librespeed/job/master/lastBuild/api/json | jq -r '.building') == "true" ]; then
|
||||
echo "**** There already seems to be an active build on Jenkins; skipping package trigger ****"
|
||||
exit 0
|
||||
fi
|
||||
echo "**** Package trigger running off of master branch. To disable, set a Github secret named \"PAUSE_PACKAGE_TRIGGER_LIBRESPEED_MASTER\". ****"
|
||||
response=$(curl -iX POST \
|
||||
https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-librespeed/job/master/buildWithParameters?PACKAGE_CHECK=true \
|
||||
--user ${{ secrets.JENKINS_USER }}:${{ secrets.JENKINS_TOKEN }} | grep -i location | sed "s|^[L|l]ocation: \(.*\)|\1|")
|
||||
echo "**** Jenkins job queue url: ${response%$'\r'} ****"
|
||||
echo "**** Sleeping 10 seconds until job starts ****"
|
||||
sleep 10
|
||||
buildurl=$(curl -s "${response%$'\r'}api/json" | jq -r '.executable.url')
|
||||
buildurl="${buildurl%$'\r'}"
|
||||
echo "**** Jenkins job build url: ${buildurl} ****"
|
||||
echo "**** Attempting to change the Jenkins job description ****"
|
||||
curl -iX POST \
|
||||
"${buildurl}submitDescription" \
|
||||
--user ${{ secrets.JENKINS_USER }}:${{ secrets.JENKINS_TOKEN }} \
|
||||
--data-urlencode "description=GHA package trigger https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" \
|
||||
--data-urlencode "Submit=Submit"
|
||||
111
.github/workflows/package_trigger_scheduler.yml
vendored
Executable file → Normal file
111
.github/workflows/package_trigger_scheduler.yml
vendored
Executable file → Normal file
@ -2,49 +2,102 @@ name: Package Trigger Scheduler
|
||||
|
||||
on:
|
||||
schedule:
|
||||
- cron: '53 14 * * 5'
|
||||
- cron: '7 10 * * 0'
|
||||
workflow_dispatch:
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
|
||||
jobs:
|
||||
package-trigger-scheduler:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2.3.3
|
||||
- uses: actions/checkout@v4.1.1
|
||||
with:
|
||||
fetch-depth: '0'
|
||||
|
||||
- name: Package Trigger Scheduler
|
||||
env:
|
||||
SKIP_PACKAGE_TRIGGER: ${{ vars.SKIP_PACKAGE_TRIGGER }}
|
||||
run: |
|
||||
echo "**** Branches found: ****"
|
||||
git for-each-ref --format='%(refname:short)' refs/remotes
|
||||
echo "**** Pulling the yq docker image ****"
|
||||
docker pull ghcr.io/linuxserver/yq
|
||||
for br in $(git for-each-ref --format='%(refname:short)' refs/remotes)
|
||||
printf "# Package trigger scheduler for docker-librespeed\n\n" >> $GITHUB_STEP_SUMMARY
|
||||
printf "Found the branches:\n\n%s\n" "$(git for-each-ref --format='- %(refname:lstrip=3)' refs/remotes)" >> $GITHUB_STEP_SUMMARY
|
||||
for br in $(git for-each-ref --format='%(refname:lstrip=3)' refs/remotes)
|
||||
do
|
||||
br=$(echo "$br" | sed 's|origin/||g')
|
||||
echo "**** Evaluating branch ${br} ****"
|
||||
ls_branch=$(curl -sX GET https://raw.githubusercontent.com/linuxserver/docker-librespeed/${br}/jenkins-vars.yml \
|
||||
| docker run --rm -i --entrypoint yq ghcr.io/linuxserver/yq -r .ls_branch)
|
||||
if [ "${br}" == "${ls_branch}" ]; then
|
||||
echo "**** Branch ${br} appears to be live; checking workflow. ****"
|
||||
if curl -sfX GET https://raw.githubusercontent.com/linuxserver/docker-librespeed/${br}/.github/workflows/package_trigger.yml > /dev/null 2>&1; then
|
||||
echo "**** Workflow exists. Triggering package trigger workflow for branch ${br}. ****"
|
||||
triggered_branches="${triggered_branches}${br} "
|
||||
curl -iX POST \
|
||||
-H "Authorization: token ${{ secrets.CR_PAT }}" \
|
||||
-H "Accept: application/vnd.github.v3+json" \
|
||||
-d "{\"ref\":\"refs/heads/${br}\"}" \
|
||||
https://api.github.com/repos/linuxserver/docker-librespeed/actions/workflows/package_trigger.yml/dispatches
|
||||
sleep 30
|
||||
if [[ "${br}" == "HEAD" ]]; then
|
||||
printf "\nSkipping %s.\n" ${br} >> $GITHUB_STEP_SUMMARY
|
||||
continue
|
||||
fi
|
||||
printf "\n## Evaluating \`%s\`\n\n" ${br} >> $GITHUB_STEP_SUMMARY
|
||||
JENKINS_VARS=$(curl -sX GET https://raw.githubusercontent.com/linuxserver/docker-librespeed/${br}/jenkins-vars.yml)
|
||||
if ! curl -sfX GET https://raw.githubusercontent.com/linuxserver/docker-librespeed/${br}/Jenkinsfile >/dev/null 2>&1; then
|
||||
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
||||
echo "> No Jenkinsfile found. Branch is either deprecated or is an early dev branch." >> $GITHUB_STEP_SUMMARY
|
||||
skipped_branches="${skipped_branches}${br} "
|
||||
elif [[ "${br}" == $(yq -r '.ls_branch' <<< "${JENKINS_VARS}") ]]; then
|
||||
echo "Branch appears to be live; checking workflow." >> $GITHUB_STEP_SUMMARY
|
||||
README_VARS=$(curl -sX GET https://raw.githubusercontent.com/linuxserver/docker-librespeed/${br}/readme-vars.yml)
|
||||
if [[ $(yq -r '.project_deprecation_status' <<< "${README_VARS}") == "true" ]]; then
|
||||
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
||||
echo "> Branch appears to be deprecated; skipping trigger." >> $GITHUB_STEP_SUMMARY
|
||||
skipped_branches="${skipped_branches}${br} "
|
||||
elif [[ $(yq -r '.skip_package_check' <<< "${JENKINS_VARS}") == "true" ]]; then
|
||||
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
||||
echo "> Skipping branch ${br} due to \`skip_package_check\` being set in \`jenkins-vars.yml\`." >> $GITHUB_STEP_SUMMARY
|
||||
skipped_branches="${skipped_branches}${br} "
|
||||
elif grep -q "^librespeed_${br}" <<< "${SKIP_PACKAGE_TRIGGER}"; then
|
||||
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
||||
echo "> Github organizational variable \`SKIP_PACKAGE_TRIGGER\` contains \`librespeed_${br}\`; skipping trigger." >> $GITHUB_STEP_SUMMARY
|
||||
skipped_branches="${skipped_branches}${br} "
|
||||
elif [ $(curl -s https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-librespeed/job/${br}/lastBuild/api/json | jq -r '.building' 2>/dev/null) == "true" ]; then
|
||||
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
||||
echo "> There already seems to be an active build on Jenkins; skipping package trigger for ${br}" >> $GITHUB_STEP_SUMMARY
|
||||
skipped_branches="${skipped_branches}${br} "
|
||||
else
|
||||
echo "**** Workflow doesn't exist; skipping trigger. ****"
|
||||
echo "> [!NOTE]" >> $GITHUB_STEP_SUMMARY
|
||||
echo "> Triggering package trigger for branch ${br}" >> $GITHUB_STEP_SUMMARY
|
||||
printf "> To disable, add \`librespeed_%s\` into the Github organizational variable \`SKIP_PACKAGE_TRIGGER\`.\n\n" "${br}" >> $GITHUB_STEP_SUMMARY
|
||||
triggered_branches="${triggered_branches}${br} "
|
||||
response=$(curl -iX POST \
|
||||
https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-librespeed/job/${br}/buildWithParameters?PACKAGE_CHECK=true \
|
||||
--user ${{ secrets.JENKINS_USER }}:${{ secrets.JENKINS_TOKEN }} | grep -i location | sed "s|^[L|l]ocation: \(.*\)|\1|")
|
||||
if [[ -z "${response}" ]]; then
|
||||
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
||||
echo "> Jenkins build could not be triggered. Skipping branch."
|
||||
continue
|
||||
fi
|
||||
echo "Jenkins [job queue url](${response%$'\r'})" >> $GITHUB_STEP_SUMMARY
|
||||
echo "Sleeping 10 seconds until job starts" >> $GITHUB_STEP_SUMMARY
|
||||
sleep 10
|
||||
buildurl=$(curl -s "${response%$'\r'}api/json" | jq -r '.executable.url')
|
||||
buildurl="${buildurl%$'\r'}"
|
||||
echo "Jenkins job [build url](${buildurl})" >> $GITHUB_STEP_SUMMARY
|
||||
echo "Attempting to change the Jenkins job description" >> $GITHUB_STEP_SUMMARY
|
||||
if ! curl -ifX POST \
|
||||
"${buildurl}submitDescription" \
|
||||
--user ${{ secrets.JENKINS_USER }}:${{ secrets.JENKINS_TOKEN }} \
|
||||
--data-urlencode "description=GHA package trigger https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" \
|
||||
--data-urlencode "Submit=Submit"; then
|
||||
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
||||
echo "> Unable to change the Jenkins job description."
|
||||
fi
|
||||
sleep 20
|
||||
fi
|
||||
else
|
||||
echo "**** ${br} appears to be a dev branch; skipping trigger. ****"
|
||||
echo "Skipping branch ${br} due to being detected as dev branch." >> $GITHUB_STEP_SUMMARY
|
||||
fi
|
||||
done
|
||||
echo "**** Package check build(s) triggered for branch(es): ${triggered_branches} ****"
|
||||
echo "**** Notifying Discord ****"
|
||||
curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://cdn.discordapp.com/avatars/354986384542662657/df91181b3f1cf0ef1592fbe18e0962d7.png","embeds": [{"color": 9802903,
|
||||
"description": "**Package Check Build(s) Triggered for librespeed** \n**Branch(es):** '"${triggered_branches}"' \n**Build URL:** '"https://ci.linuxserver.io/blue/organizations/jenkins/Docker-Pipeline-Builders%2Fdocker-librespeed/activity/"' \n"}],
|
||||
"username": "Github Actions"}' ${{ secrets.DISCORD_WEBHOOK }}
|
||||
if [[ -n "${triggered_branches}" ]] || [[ -n "${skipped_branches}" ]]; then
|
||||
if [[ -n "${triggered_branches}" ]]; then
|
||||
NOTIFY_BRANCHES="**Triggered:** ${triggered_branches} \n"
|
||||
NOTIFY_BUILD_URL="**Build URL:** https://ci.linuxserver.io/blue/organizations/jenkins/Docker-Pipeline-Builders%2Fdocker-librespeed/activity/ \n"
|
||||
echo "**** Package check build(s) triggered for branch(es): ${triggered_branches} ****"
|
||||
fi
|
||||
if [[ -n "${skipped_branches}" ]]; then
|
||||
NOTIFY_BRANCHES="${NOTIFY_BRANCHES}**Skipped:** ${skipped_branches} \n"
|
||||
fi
|
||||
echo "**** Notifying Discord ****"
|
||||
curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://cdn.discordapp.com/avatars/354986384542662657/df91181b3f1cf0ef1592fbe18e0962d7.png","embeds": [{"color": 9802903,
|
||||
"description": "**Package Check Build(s) for librespeed** \n'"${NOTIFY_BRANCHES}"''"${NOTIFY_BUILD_URL}"'"}],
|
||||
"username": "Github Actions"}' ${{ secrets.DISCORD_WEBHOOK }}
|
||||
fi
|
||||
|
||||
12
.github/workflows/permissions.yml
vendored
Normal file
12
.github/workflows/permissions.yml
vendored
Normal file
@ -0,0 +1,12 @@
|
||||
name: Permission check
|
||||
on:
|
||||
pull_request_target:
|
||||
paths:
|
||||
- '**/run'
|
||||
- '**/finish'
|
||||
- '**/check'
|
||||
- 'root/migrations/*'
|
||||
|
||||
jobs:
|
||||
permission_check:
|
||||
uses: linuxserver/github-workflows/.github/workflows/init-svc-executable-permissions.yml@v1
|
||||
23
.github/workflows/stale.yml
vendored
23
.github/workflows/stale.yml
vendored
@ -1,23 +0,0 @@
|
||||
name: Mark stale issues and pull requests
|
||||
|
||||
on:
|
||||
schedule:
|
||||
- cron: "30 1 * * *"
|
||||
|
||||
jobs:
|
||||
stale:
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/stale@v1
|
||||
with:
|
||||
stale-issue-message: "This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions."
|
||||
stale-pr-message: "This pull request has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions."
|
||||
stale-issue-label: 'no-issue-activity'
|
||||
stale-pr-label: 'no-pr-activity'
|
||||
days-before-stale: 30
|
||||
days-before-close: 365
|
||||
exempt-issue-labels: 'awaiting-approval,work-in-progress'
|
||||
exempt-pr-labels: 'awaiting-approval,work-in-progress'
|
||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
1
.gitignore
vendored
1
.gitignore
vendored
@ -41,3 +41,4 @@ $RECYCLE.BIN/
|
||||
Network Trash Folder
|
||||
Temporary Items
|
||||
.apdisk
|
||||
.jenkins-external
|
||||
|
||||
52
Dockerfile
52
Dockerfile
@ -1,4 +1,6 @@
|
||||
FROM ghcr.io/linuxserver/baseimage-alpine-nginx:3.12
|
||||
# syntax=docker/dockerfile:1
|
||||
|
||||
FROM ghcr.io/linuxserver/baseimage-alpine-nginx:3.22
|
||||
|
||||
# set version label
|
||||
ARG BUILD_DATE
|
||||
@ -8,33 +10,33 @@ LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DA
|
||||
LABEL maintainer="aptalca"
|
||||
|
||||
RUN \
|
||||
echo "**** install packages ****" && \
|
||||
apk add --no-cache \
|
||||
curl \
|
||||
php7-gd \
|
||||
php7-mysqli \
|
||||
php7-pdo_pgsql \
|
||||
php7-pdo_sqlite && \
|
||||
echo "**** install librespeed ****" && \
|
||||
if [ -z ${LIBRESPEED_RELEASE+x} ]; then \
|
||||
LIBRESPEED_RELEASE=$(curl -sX GET "https://api.github.com/repos/librespeed/speedtest/releases/latest" \
|
||||
| awk '/tag_name/{print $4;exit}' FS='[""]'); \
|
||||
fi && \
|
||||
mkdir -p \
|
||||
/usr/share/webapps/librespeed && \
|
||||
curl -o \
|
||||
/tmp/librespeed.tar.gz -L \
|
||||
"https://github.com/librespeed/speedtest/archive/${LIBRESPEED_RELEASE}.tar.gz" && \
|
||||
tar xf \
|
||||
/tmp/librespeed.tar.gz -C \
|
||||
/usr/share/webapps/librespeed --strip-components=1 && \
|
||||
echo "**** cleanup ****" && \
|
||||
rm -rf \
|
||||
/tmp/*
|
||||
echo "**** install packages ****" && \
|
||||
apk add --no-cache \
|
||||
php84-gd \
|
||||
php84-pdo_mysql \
|
||||
php84-pdo_pgsql \
|
||||
php84-pdo_sqlite && \
|
||||
echo "**** install librespeed ****" && \
|
||||
if [ -z ${LIBRESPEED_RELEASE+x} ]; then \
|
||||
LIBRESPEED_RELEASE=$(curl -sX GET "https://api.github.com/repos/librespeed/speedtest/releases/latest" \
|
||||
| awk '/tag_name/{print $4;exit}' FS='[""]'); \
|
||||
fi && \
|
||||
mkdir -p \
|
||||
/app/www/public && \
|
||||
curl -o \
|
||||
/tmp/librespeed.tar.gz -L \
|
||||
"https://github.com/librespeed/speedtest/archive/${LIBRESPEED_RELEASE}.tar.gz" && \
|
||||
tar xf \
|
||||
/tmp/librespeed.tar.gz -C \
|
||||
/app/www/public --strip-components=1 && \
|
||||
printf "Linuxserver.io version: ${VERSION}\nBuild-date: ${BUILD_DATE}" > /build_version && \
|
||||
echo "**** cleanup ****" && \
|
||||
rm -rf \
|
||||
/tmp/*
|
||||
|
||||
# add local files
|
||||
COPY root/ /
|
||||
|
||||
# ports and volumes
|
||||
EXPOSE 80
|
||||
EXPOSE 80 443
|
||||
VOLUME /config
|
||||
|
||||
@ -1,4 +1,6 @@
|
||||
FROM ghcr.io/linuxserver/baseimage-alpine-nginx:arm64v8-3.12
|
||||
# syntax=docker/dockerfile:1
|
||||
|
||||
FROM ghcr.io/linuxserver/baseimage-alpine-nginx:arm64v8-3.22
|
||||
|
||||
# set version label
|
||||
ARG BUILD_DATE
|
||||
@ -8,33 +10,33 @@ LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DA
|
||||
LABEL maintainer="aptalca"
|
||||
|
||||
RUN \
|
||||
echo "**** install packages ****" && \
|
||||
apk add --no-cache \
|
||||
curl \
|
||||
php7-gd \
|
||||
php7-mysqli \
|
||||
php7-pdo_pgsql \
|
||||
php7-pdo_sqlite && \
|
||||
echo "**** install librespeed ****" && \
|
||||
if [ -z ${LIBRESPEED_RELEASE+x} ]; then \
|
||||
LIBRESPEED_RELEASE=$(curl -sX GET "https://api.github.com/repos/librespeed/speedtest/releases/latest" \
|
||||
| awk '/tag_name/{print $4;exit}' FS='[""]'); \
|
||||
fi && \
|
||||
mkdir -p \
|
||||
/usr/share/webapps/librespeed && \
|
||||
curl -o \
|
||||
/tmp/librespeed.tar.gz -L \
|
||||
"https://github.com/librespeed/speedtest/archive/${LIBRESPEED_RELEASE}.tar.gz" && \
|
||||
tar xf \
|
||||
/tmp/librespeed.tar.gz -C \
|
||||
/usr/share/webapps/librespeed --strip-components=1 && \
|
||||
echo "**** cleanup ****" && \
|
||||
rm -rf \
|
||||
/tmp/*
|
||||
echo "**** install packages ****" && \
|
||||
apk add --no-cache \
|
||||
php84-gd \
|
||||
php84-pdo_mysql \
|
||||
php84-pdo_pgsql \
|
||||
php84-pdo_sqlite && \
|
||||
echo "**** install librespeed ****" && \
|
||||
if [ -z ${LIBRESPEED_RELEASE+x} ]; then \
|
||||
LIBRESPEED_RELEASE=$(curl -sX GET "https://api.github.com/repos/librespeed/speedtest/releases/latest" \
|
||||
| awk '/tag_name/{print $4;exit}' FS='[""]'); \
|
||||
fi && \
|
||||
mkdir -p \
|
||||
/app/www/public && \
|
||||
curl -o \
|
||||
/tmp/librespeed.tar.gz -L \
|
||||
"https://github.com/librespeed/speedtest/archive/${LIBRESPEED_RELEASE}.tar.gz" && \
|
||||
tar xf \
|
||||
/tmp/librespeed.tar.gz -C \
|
||||
/app/www/public --strip-components=1 && \
|
||||
printf "Linuxserver.io version: ${VERSION}\nBuild-date: ${BUILD_DATE}" > /build_version && \
|
||||
echo "**** cleanup ****" && \
|
||||
rm -rf \
|
||||
/tmp/*
|
||||
|
||||
# add local files
|
||||
COPY root/ /
|
||||
|
||||
# ports and volumes
|
||||
EXPOSE 80
|
||||
EXPOSE 80 443
|
||||
VOLUME /config
|
||||
|
||||
@ -1,40 +0,0 @@
|
||||
FROM ghcr.io/linuxserver/baseimage-alpine-nginx:arm32v7-3.12
|
||||
|
||||
# set version label
|
||||
ARG BUILD_DATE
|
||||
ARG VERSION
|
||||
ARG LIBRESPEED_RELEASE
|
||||
LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DATE}"
|
||||
LABEL maintainer="aptalca"
|
||||
|
||||
RUN \
|
||||
echo "**** install packages ****" && \
|
||||
apk add --no-cache \
|
||||
curl \
|
||||
php7-gd \
|
||||
php7-mysqli \
|
||||
php7-pdo_pgsql \
|
||||
php7-pdo_sqlite && \
|
||||
echo "**** install librespeed ****" && \
|
||||
if [ -z ${LIBRESPEED_RELEASE+x} ]; then \
|
||||
LIBRESPEED_RELEASE=$(curl -sX GET "https://api.github.com/repos/librespeed/speedtest/releases/latest" \
|
||||
| awk '/tag_name/{print $4;exit}' FS='[""]'); \
|
||||
fi && \
|
||||
mkdir -p \
|
||||
/usr/share/webapps/librespeed && \
|
||||
curl -o \
|
||||
/tmp/librespeed.tar.gz -L \
|
||||
"https://github.com/librespeed/speedtest/archive/${LIBRESPEED_RELEASE}.tar.gz" && \
|
||||
tar xf \
|
||||
/tmp/librespeed.tar.gz -C \
|
||||
/usr/share/webapps/librespeed --strip-components=1 && \
|
||||
echo "**** cleanup ****" && \
|
||||
rm -rf \
|
||||
/tmp/*
|
||||
|
||||
# add local files
|
||||
COPY root/ /
|
||||
|
||||
# ports and volumes
|
||||
EXPOSE 80
|
||||
VOLUME /config
|
||||
1040
Jenkinsfile
vendored
1040
Jenkinsfile
vendored
File diff suppressed because it is too large
Load Diff
262
README.md
262
README.md
@ -1,136 +1,151 @@
|
||||
<!-- DO NOT EDIT THIS FILE MANUALLY -->
|
||||
<!-- Please read the CONTRIBUTING.md -->
|
||||
|
||||
<!-- DO NOT EDIT THIS FILE MANUALLY -->
|
||||
<!-- Please read https://github.com/linuxserver/docker-librespeed/blob/master/.github/CONTRIBUTING.md -->
|
||||
[](https://linuxserver.io)
|
||||
|
||||
[](https://blog.linuxserver.io "all the things you can do with our containers including How-To guides, opinions and much more!")
|
||||
[](https://discord.gg/YWrKVTn "realtime support / chat with the community and the team.")
|
||||
[](https://linuxserver.io/discord "realtime support / chat with the community and the team.")
|
||||
[](https://discourse.linuxserver.io "post on our community forum.")
|
||||
[](https://fleet.linuxserver.io "an online web interface which displays all of our maintained images.")
|
||||
[](https://github.com/linuxserver "view the source for all of our repositories.")
|
||||
[](https://opencollective.com/linuxserver "please consider helping us by either donating or contributing to our budget")
|
||||
|
||||
The [LinuxServer.io](https://linuxserver.io) team brings you another container release featuring:
|
||||
|
||||
* regular and timely application updates
|
||||
* easy user mappings (PGID, PUID)
|
||||
* custom base image with s6 overlay
|
||||
* weekly base OS updates with common layers across the entire LinuxServer.io ecosystem to minimise space usage, down time and bandwidth
|
||||
* regular security updates
|
||||
* regular and timely application updates
|
||||
* easy user mappings (PGID, PUID)
|
||||
* custom base image with s6 overlay
|
||||
* weekly base OS updates with common layers across the entire LinuxServer.io ecosystem to minimise space usage, down time and bandwidth
|
||||
* regular security updates
|
||||
|
||||
Find us at:
|
||||
|
||||
* [Blog](https://blog.linuxserver.io) - all the things you can do with our containers including How-To guides, opinions and much more!
|
||||
* [Discord](https://discord.gg/YWrKVTn) - realtime support / chat with the community and the team.
|
||||
* [Discord](https://linuxserver.io/discord) - realtime support / chat with the community and the team.
|
||||
* [Discourse](https://discourse.linuxserver.io) - post on our community forum.
|
||||
* [Fleet](https://fleet.linuxserver.io) - an online web interface which displays all of our maintained images.
|
||||
* [GitHub](https://github.com/linuxserver) - view the source for all of our repositories.
|
||||
* [Open Collective](https://opencollective.com/linuxserver) - please consider helping us by either donating or contributing to our budget
|
||||
|
||||
# [linuxserver/librespeed](https://github.com/linuxserver/docker-librespeed)
|
||||
|
||||
[](https://scarf.sh)
|
||||
[](https://github.com/linuxserver/docker-librespeed)
|
||||
[](https://github.com/linuxserver/docker-librespeed/releases)
|
||||
[](https://github.com/linuxserver/docker-librespeed/packages)
|
||||
[](https://gitlab.com/linuxserver.io/docker-librespeed/container_registry)
|
||||
[](https://microbadger.com/images/linuxserver/librespeed "Get your own version badge on microbadger.com")
|
||||
[](https://quay.io/repository/linuxserver.io/librespeed)
|
||||
[](https://hub.docker.com/r/linuxserver/librespeed)
|
||||
[](https://hub.docker.com/r/linuxserver/librespeed)
|
||||
[](https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-librespeed/job/master/)
|
||||
[](https://ci-tests.linuxserver.io/linuxserver/librespeed/latest/index.html)
|
||||
|
||||
[Librespeed](https://github.com/librespeed/speedtest) is a very lightweight Speedtest implemented in Javascript, using XMLHttpRequest and Web Workers.
|
||||
|
||||
No Flash, No Java, No Websocket, No Bullshit.
|
||||
|
||||
[](https://github.com/librespeed/speedtest)
|
||||
|
||||
## Supported Architectures
|
||||
|
||||
Our images support multiple architectures such as `x86-64`, `arm64` and `armhf`. We utilise the docker manifest for multi-platform awareness. More information is available from docker [here](https://github.com/docker/distribution/blob/master/docs/spec/manifest-v2-2.md#manifest-list) and our announcement [here](https://blog.linuxserver.io/2019/02/21/the-lsio-pipeline-project/).
|
||||
We utilise the docker manifest for multi-platform awareness. More information is available from docker [here](https://distribution.github.io/distribution/spec/manifest-v2-2/#manifest-list) and our announcement [here](https://blog.linuxserver.io/2019/02/21/the-lsio-pipeline-project/).
|
||||
|
||||
Simply pulling `ghcr.io/linuxserver/librespeed` should retrieve the correct image for your arch, but you can also pull specific arch images via tags.
|
||||
Simply pulling `lscr.io/linuxserver/librespeed:latest` should retrieve the correct image for your arch, but you can also pull specific arch images via tags.
|
||||
|
||||
The architectures supported by this image are:
|
||||
|
||||
| Architecture | Tag |
|
||||
| :----: | --- |
|
||||
| x86-64 | amd64-latest |
|
||||
| arm64 | arm64v8-latest |
|
||||
| armhf | arm32v7-latest |
|
||||
| Architecture | Available | Tag |
|
||||
| :----: | :----: | ---- |
|
||||
| x86-64 | ✅ | amd64-\<version tag\> |
|
||||
| arm64 | ✅ | arm64v8-\<version tag\> |
|
||||
|
||||
## Application Setup
|
||||
|
||||
Access the speedtest webui at `http://SERVERIP`. The results database can be accessed at `http://SERVERIP/results/stats.php` with the password set.
|
||||
The default template used is based on `example-singleServer-full.html`. However, all templates are provided for reference at `/config/www/`. Feel free to customize `/config/www/index.html` as you like. Delete the file and restart to go back to the image default.
|
||||
|
||||
You can optionally place customized `speedtest.js` and `speedtest_worker.js` files under `/config/www` and they will supersede the defaults after a container start. Keep in mind that once you do so, they will no longer be updated. You can delete them and recreate the container to go back to the image defaults.
|
||||
|
||||
If you are setting up a mysql or postgresql database, you first need to import the tables into your database as described at the following link
|
||||
https://github.com/librespeed/speedtest/blob/master/doc.md#creating-the-database
|
||||
|
||||
To enable a custom results page set the environment variable `CUSTOM_RESULTS=true` and start (or restart) the container at least once for `/config/www/results/index.php` to be created and modify this file to your liking.
|
||||
|
||||
## Usage
|
||||
|
||||
Here are some example snippets to help you get started creating a container.
|
||||
To help you get started creating a container from this image you can either use docker-compose or the docker cli.
|
||||
|
||||
### docker-compose ([recommended](https://docs.linuxserver.io/general/docker-compose))
|
||||
>[!NOTE]
|
||||
>Unless a parameter is flaged as 'optional', it is *mandatory* and a value must be provided.
|
||||
|
||||
Compatible with docker-compose v2 schemas.
|
||||
### docker-compose (recommended, [click here for more info](https://docs.linuxserver.io/general/docker-compose))
|
||||
|
||||
```yaml
|
||||
---
|
||||
version: "2.1"
|
||||
services:
|
||||
librespeed:
|
||||
image: ghcr.io/linuxserver/librespeed
|
||||
image: lscr.io/linuxserver/librespeed:latest
|
||||
container_name: librespeed
|
||||
environment:
|
||||
- PUID=1000
|
||||
- PGID=1000
|
||||
- TZ=Europe/London
|
||||
- TZ=Etc/UTC
|
||||
- PASSWORD=PASSWORD
|
||||
- CUSTOM_RESULTS=true #optional
|
||||
- CUSTOM_RESULTS=false #optional
|
||||
- DB_TYPE=sqlite #optional
|
||||
- DB_NAME=DB_NAME #optional
|
||||
- DB_HOSTNAME=DB_HOSTNAME #optional
|
||||
- DB_USERNAME=DB_USERNAME #optional
|
||||
- DB_PASSWORD=DB_PASSWORD #optional
|
||||
- DB_PORT=DB_PORT #optional
|
||||
- IPINFO_APIKEY=ACCESS_TOKEN #optional
|
||||
volumes:
|
||||
- /path/to/appdata/config:/config
|
||||
- /path/to/librespeed/config:/config
|
||||
ports:
|
||||
- 80:80
|
||||
restart: unless-stopped
|
||||
```
|
||||
|
||||
### docker cli
|
||||
### docker cli ([click here for more info](https://docs.docker.com/engine/reference/commandline/cli/))
|
||||
|
||||
```
|
||||
```bash
|
||||
docker run -d \
|
||||
--name=librespeed \
|
||||
-e PUID=1000 \
|
||||
-e PGID=1000 \
|
||||
-e TZ=Europe/London \
|
||||
-e TZ=Etc/UTC \
|
||||
-e PASSWORD=PASSWORD \
|
||||
-e CUSTOM_RESULTS=true `#optional` \
|
||||
-e CUSTOM_RESULTS=false `#optional` \
|
||||
-e DB_TYPE=sqlite `#optional` \
|
||||
-e DB_NAME=DB_NAME `#optional` \
|
||||
-e DB_HOSTNAME=DB_HOSTNAME `#optional` \
|
||||
-e DB_USERNAME=DB_USERNAME `#optional` \
|
||||
-e DB_PASSWORD=DB_PASSWORD `#optional` \
|
||||
-e DB_PORT=DB_PORT `#optional` \
|
||||
-e IPINFO_APIKEY=ACCESS_TOKEN `#optional` \
|
||||
-p 80:80 \
|
||||
-v /path/to/appdata/config:/config \
|
||||
-v /path/to/librespeed/config:/config \
|
||||
--restart unless-stopped \
|
||||
ghcr.io/linuxserver/librespeed
|
||||
lscr.io/linuxserver/librespeed:latest
|
||||
```
|
||||
|
||||
|
||||
## Parameters
|
||||
|
||||
Container images are configured using parameters passed at runtime (such as those above). These parameters are separated by a colon and indicate `<external>:<internal>` respectively. For example, `-p 8080:80` would expose port `80` from inside the container to be accessible from the host's IP on port `8080` outside the container.
|
||||
Containers are configured using parameters passed at runtime (such as those above). These parameters are separated by a colon and indicate `<external>:<internal>` respectively. For example, `-p 8080:80` would expose port `80` from inside the container to be accessible from the host's IP on port `8080` outside the container.
|
||||
|
||||
| Parameter | Function |
|
||||
| :----: | --- |
|
||||
| `-p 80` | web gui |
|
||||
| `-p 80:80` | web gui |
|
||||
| `-e PUID=1000` | for UserID - see below for explanation |
|
||||
| `-e PGID=1000` | for GroupID - see below for explanation |
|
||||
| `-e TZ=Europe/London` | Specify a timezone to use EG Europe/London |
|
||||
| `-e TZ=Etc/UTC` | specify a timezone to use, see this [list](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones#List). |
|
||||
| `-e PASSWORD=PASSWORD` | Set the password for the results database. |
|
||||
| `-e CUSTOM_RESULTS=true` | (optional) enables custom results page in `/config/www/results/index.php`. |
|
||||
| `-e CUSTOM_RESULTS=false` | (optional) set to `true` to enable custom results page in `/config/www/results/index.php`. |
|
||||
| `-e DB_TYPE=sqlite` | Defaults to `sqlite`, can also be set to `mysql` or `postgresql`. |
|
||||
| `-e DB_NAME=DB_NAME` | Database name. Required for mysql and pgsql. |
|
||||
| `-e DB_HOSTNAME=DB_HOSTNAME` | Database address. Required for mysql and pgsql. |
|
||||
| `-e DB_USERNAME=DB_USERNAME` | Database username. Required for mysql and pgsql. |
|
||||
| `-e DB_PASSWORD=DB_PASSWORD` | Database password. Required for mysql and pgsql. |
|
||||
| `-v /config` | Contains all relevant configuration files. |
|
||||
| `-e DB_PORT=DB_PORT` | Database port. Required for mysql. |
|
||||
| `-e IPINFO_APIKEY=ACCESS_TOKEN` | Access token from ipinfo.io. Required for detailed IP information. |
|
||||
| `-v /config` | Persistent config files |
|
||||
|
||||
## Environment variables from files (Docker secrets)
|
||||
|
||||
@ -138,11 +153,11 @@ You can set any environment variable from a file by using a special prepend `FIL
|
||||
|
||||
As an example:
|
||||
|
||||
```
|
||||
-e FILE__PASSWORD=/run/secrets/mysecretpassword
|
||||
```bash
|
||||
-e FILE__MYVAR=/run/secrets/mysecretvariable
|
||||
```
|
||||
|
||||
Will set the environment variable `PASSWORD` based on the contents of the `/run/secrets/mysecretpassword` file.
|
||||
Will set the environment variable `MYVAR` based on the contents of the `/run/secrets/mysecretvariable` file.
|
||||
|
||||
## Umask for running applications
|
||||
|
||||
@ -151,103 +166,160 @@ Keep in mind umask is not chmod it subtracts from permissions based on it's valu
|
||||
|
||||
## User / Group Identifiers
|
||||
|
||||
When using volumes (`-v` flags) permissions issues can arise between the host OS and the container, we avoid this issue by allowing you to specify the user `PUID` and group `PGID`.
|
||||
When using volumes (`-v` flags), permissions issues can arise between the host OS and the container, we avoid this issue by allowing you to specify the user `PUID` and group `PGID`.
|
||||
|
||||
Ensure any volume directories on the host are owned by the same user you specify and any permissions issues will vanish like magic.
|
||||
|
||||
In this instance `PUID=1000` and `PGID=1000`, to find yours use `id user` as below:
|
||||
In this instance `PUID=1000` and `PGID=1000`, to find yours use `id your_user` as below:
|
||||
|
||||
```
|
||||
$ id username
|
||||
uid=1000(dockeruser) gid=1000(dockergroup) groups=1000(dockergroup)
|
||||
```bash
|
||||
id your_user
|
||||
```
|
||||
|
||||
Example output:
|
||||
|
||||
|
||||
## Application Setup
|
||||
|
||||
Access the speedtest webui at `http://SERVERIP`. The results database can be accessed at `http://SERVERIP/results/stats.php` with the password set.
|
||||
The default template used is based on `example-singleServer-full.html`. However, all templates are provided for reference at `/config/www/`. Feel free to customize `/config/www/index.html` as you like. Delete the file and restart to go back to the image default.
|
||||
|
||||
You can optionally place customized `speedtest.js` and `speedtest_worker.js` files under `/config/www` and they will supersede the defaults after a container start. Keep in mind that once you do so, they will no longer be updated. You can delete them and recreate the container to go back to the image defaults.
|
||||
|
||||
If you are setting up a mysql or postgresql database, you first need to import the tables into your database as described at the following link
|
||||
https://github.com/librespeed/speedtest/blob/master/doc.md#creating-the-database
|
||||
|
||||
To enable a custom results page set the environment variable `CUSTOM_RESULTS=true` and start (or restart) the container at least once for `/config/www/results/index.php` to be created and modify this file to your liking.
|
||||
|
||||
```text
|
||||
uid=1000(your_user) gid=1000(your_user) groups=1000(your_user)
|
||||
```
|
||||
|
||||
## Docker Mods
|
||||
|
||||
[](https://mods.linuxserver.io/?mod=librespeed "view available mods for this container.") [](https://mods.linuxserver.io/?mod=universal "view available universal mods.")
|
||||
|
||||
We publish various [Docker Mods](https://github.com/linuxserver/docker-mods) to enable additional functionality within the containers. The list of Mods available for this image (if any) as well as universal mods that can be applied to any one of our images can be accessed via the dynamic badges above.
|
||||
|
||||
|
||||
## Support Info
|
||||
|
||||
* Shell access whilst the container is running: `docker exec -it librespeed /bin/bash`
|
||||
* To monitor the logs of the container in realtime: `docker logs -f librespeed`
|
||||
* container version number
|
||||
* `docker inspect -f '{{ index .Config.Labels "build_version" }}' librespeed`
|
||||
* image version number
|
||||
* `docker inspect -f '{{ index .Config.Labels "build_version" }}' ghcr.io/linuxserver/librespeed`
|
||||
* Shell access whilst the container is running:
|
||||
|
||||
```bash
|
||||
docker exec -it librespeed /bin/bash
|
||||
```
|
||||
|
||||
* To monitor the logs of the container in realtime:
|
||||
|
||||
```bash
|
||||
docker logs -f librespeed
|
||||
```
|
||||
|
||||
* Container version number:
|
||||
|
||||
```bash
|
||||
docker inspect -f '{{ index .Config.Labels "build_version" }}' librespeed
|
||||
```
|
||||
|
||||
* Image version number:
|
||||
|
||||
```bash
|
||||
docker inspect -f '{{ index .Config.Labels "build_version" }}' lscr.io/linuxserver/librespeed:latest
|
||||
```
|
||||
|
||||
## Updating Info
|
||||
|
||||
Most of our images are static, versioned, and require an image update and container recreation to update the app inside. With some exceptions (ie. nextcloud, plex), we do not recommend or support updating apps inside the container. Please consult the [Application Setup](#application-setup) section above to see if it is recommended for the image.
|
||||
Most of our images are static, versioned, and require an image update and container recreation to update the app inside. With some exceptions (noted in the relevant readme.md), we do not recommend or support updating apps inside the container. Please consult the [Application Setup](#application-setup) section above to see if it is recommended for the image.
|
||||
|
||||
Below are the instructions for updating containers:
|
||||
|
||||
### Via Docker Compose
|
||||
* Update all images: `docker-compose pull`
|
||||
* or update a single image: `docker-compose pull librespeed`
|
||||
* Let compose update all containers as necessary: `docker-compose up -d`
|
||||
* or update a single container: `docker-compose up -d librespeed`
|
||||
* You can also remove the old dangling images: `docker image prune`
|
||||
|
||||
* Update images:
|
||||
* All images:
|
||||
|
||||
```bash
|
||||
docker-compose pull
|
||||
```
|
||||
|
||||
* Single image:
|
||||
|
||||
```bash
|
||||
docker-compose pull librespeed
|
||||
```
|
||||
|
||||
* Update containers:
|
||||
* All containers:
|
||||
|
||||
```bash
|
||||
docker-compose up -d
|
||||
```
|
||||
|
||||
* Single container:
|
||||
|
||||
```bash
|
||||
docker-compose up -d librespeed
|
||||
```
|
||||
|
||||
* You can also remove the old dangling images:
|
||||
|
||||
```bash
|
||||
docker image prune
|
||||
```
|
||||
|
||||
### Via Docker Run
|
||||
* Update the image: `docker pull ghcr.io/linuxserver/librespeed`
|
||||
* Stop the running container: `docker stop librespeed`
|
||||
* Delete the container: `docker rm librespeed`
|
||||
|
||||
* Update the image:
|
||||
|
||||
```bash
|
||||
docker pull lscr.io/linuxserver/librespeed:latest
|
||||
```
|
||||
|
||||
* Stop the running container:
|
||||
|
||||
```bash
|
||||
docker stop librespeed
|
||||
```
|
||||
|
||||
* Delete the container:
|
||||
|
||||
```bash
|
||||
docker rm librespeed
|
||||
```
|
||||
|
||||
* Recreate a new container with the same docker run parameters as instructed above (if mapped correctly to a host folder, your `/config` folder and settings will be preserved)
|
||||
* You can also remove the old dangling images: `docker image prune`
|
||||
* You can also remove the old dangling images:
|
||||
|
||||
### Via Watchtower auto-updater (only use if you don't remember the original parameters)
|
||||
* Pull the latest image at its tag and replace it with the same env variables in one run:
|
||||
```
|
||||
docker run --rm \
|
||||
-v /var/run/docker.sock:/var/run/docker.sock \
|
||||
containrrr/watchtower \
|
||||
--run-once librespeed
|
||||
```
|
||||
* You can also remove the old dangling images: `docker image prune`
|
||||
|
||||
**Note:** We do not endorse the use of Watchtower as a solution to automated updates of existing Docker containers. In fact we generally discourage automated updates. However, this is a useful tool for one-time manual updates of containers where you have forgotten the original parameters. In the long term, we highly recommend using [Docker Compose](https://docs.linuxserver.io/general/docker-compose).
|
||||
```bash
|
||||
docker image prune
|
||||
```
|
||||
|
||||
### Image Update Notifications - Diun (Docker Image Update Notifier)
|
||||
* We recommend [Diun](https://crazymax.dev/diun/) for update notifications. Other tools that automatically update containers unattended are not recommended or supported.
|
||||
|
||||
>[!TIP]
|
||||
>We recommend [Diun](https://crazymax.dev/diun/) for update notifications. Other tools that automatically update containers unattended are not recommended or supported.
|
||||
|
||||
## Building locally
|
||||
|
||||
If you want to make local modifications to these images for development purposes or just to customize the logic:
|
||||
```
|
||||
|
||||
```bash
|
||||
git clone https://github.com/linuxserver/docker-librespeed.git
|
||||
cd docker-librespeed
|
||||
docker build \
|
||||
--no-cache \
|
||||
--pull \
|
||||
-t ghcr.io/linuxserver/librespeed:latest .
|
||||
-t lscr.io/linuxserver/librespeed:latest .
|
||||
```
|
||||
|
||||
The ARM variants can be built on x86_64 hardware using `multiarch/qemu-user-static`
|
||||
```
|
||||
docker run --rm --privileged multiarch/qemu-user-static:register --reset
|
||||
The ARM variants can be built on x86_64 hardware and vice versa using `lscr.io/linuxserver/qemu-static`
|
||||
|
||||
```bash
|
||||
docker run --rm --privileged lscr.io/linuxserver/qemu-static --reset
|
||||
```
|
||||
|
||||
Once registered you can define the dockerfile to use with `-f Dockerfile.aarch64`.
|
||||
|
||||
## Versions
|
||||
|
||||
* **27.07.25:** - Rebase to Alpine 3.22.
|
||||
* **27.06.24:** - Rebase to Alpine 3.20. Existing users should update their nginx confs to avoid http2 deprecation warnings.
|
||||
* **23.12.23:** - Rebase to Alpine 3.19 with php 8.3.
|
||||
* **06.12.23:** - Replace php mysqli with php pdo_pgsql.
|
||||
* **25.05.23:** - Rebase to Alpine 3.18, deprecate armhf.
|
||||
* **14.05.23:** - Added support for ipinfo.io
|
||||
* **20.01.23:** - Rebase to alpine 3.17 with php8.1.
|
||||
* **20.08.22:** - Rebasing to alpine 3.15 with php8. Restructure nginx configs ([see changes announcement](https://info.linuxserver.io/issues/2022-08-20-nginx-base)).
|
||||
* **01.03.21:** - Fix up database settings. Make sure `index.html` is recreated.
|
||||
* **28.02.21:** - Added php7-ctype.
|
||||
* **23.01.21:** - Rebasing to alpine 3.13.
|
||||
* **01.06.20:** - Rebasing to alpine 3.12.
|
||||
* **29.04.20:** - Add donation links for LibreSpeed to Github sponsor button and container log.
|
||||
* **09.01.20:** - Initial Release.
|
||||
|
||||
@ -24,8 +24,8 @@ repo_vars:
|
||||
- CI_PORT='80'
|
||||
- CI_SSL='false'
|
||||
- CI_DELAY='120'
|
||||
- CI_DOCKERENV='TZ=US/Pacific'
|
||||
- CI_AUTH='user:password'
|
||||
- CI_DOCKERENV=''
|
||||
- CI_AUTH=''
|
||||
- CI_WEBPATH=''
|
||||
sponsor_links:
|
||||
- { name: "LibreSpeed (Liberapay)", url: "https://liberapay.com/fdossena/donate" }
|
||||
|
||||
@ -1,90 +1,116 @@
|
||||
alpine-baselayout-3.2.0-r7
|
||||
alpine-keys-2.2-r0
|
||||
apache2-utils-2.4.46-r1
|
||||
apk-tools-2.10.5-r1
|
||||
apr-1.7.0-r0
|
||||
apr-util-1.6.1-r6
|
||||
argon2-libs-20190702-r1
|
||||
bash-5.0.17-r0
|
||||
brotli-libs-1.0.9-r1
|
||||
busybox-1.31.1-r19
|
||||
ca-certificates-20191127-r4
|
||||
ca-certificates-bundle-20191127-r4
|
||||
coreutils-8.32-r0
|
||||
curl-7.69.1-r3
|
||||
db-5.3.28-r1
|
||||
expat-2.2.9-r1
|
||||
freetype-2.10.4-r0
|
||||
git-2.26.2-r0
|
||||
libacl-2.2.53-r0
|
||||
libattr-2.4.48-r0
|
||||
libbsd-0.10.0-r0
|
||||
libbz2-1.0.8-r1
|
||||
libc-utils-0.7.2-r3
|
||||
libcrypto1.1-1.1.1i-r0
|
||||
libcurl-7.69.1-r3
|
||||
libedit-20191231.3.1-r0
|
||||
libice-1.0.10-r0
|
||||
libintl-0.20.2-r0
|
||||
libjpeg-turbo-2.0.5-r0
|
||||
libldap-2.4.50-r1
|
||||
libmagic-5.38-r0
|
||||
libpng-1.6.37-r1
|
||||
libpq-12.5-r0
|
||||
libproc-3.3.16-r0
|
||||
libressl3.1-libcrypto-3.1.2-r0
|
||||
libressl3.1-libssl-3.1.2-r0
|
||||
libsasl-2.1.27-r6
|
||||
libsm-1.2.3-r0
|
||||
libssl1.1-1.1.1i-r0
|
||||
libtls-standalone-2.9.1-r1
|
||||
libuuid-2.35.2-r0
|
||||
libwebp-1.1.0-r0
|
||||
libx11-1.6.12-r0
|
||||
libxau-1.0.9-r0
|
||||
libxcb-1.14-r1
|
||||
libxdmcp-1.1.3-r0
|
||||
libxext-1.3.4-r0
|
||||
libxml2-2.9.10-r5
|
||||
libxpm-3.5.13-r0
|
||||
libxt-1.2.0-r0
|
||||
linux-pam-1.3.1-r4
|
||||
logrotate-3.16.0-r0
|
||||
musl-1.1.24-r10
|
||||
musl-utils-1.1.24-r10
|
||||
nano-4.9.3-r0
|
||||
ncurses-libs-6.2_p20200523-r0
|
||||
ncurses-terminfo-base-6.2_p20200523-r0
|
||||
nghttp2-libs-1.41.0-r0
|
||||
nginx-1.18.0-r1
|
||||
openssl-1.1.1i-r0
|
||||
pcre-8.44-r0
|
||||
pcre2-10.35-r0
|
||||
php7-7.3.25-r0
|
||||
php7-common-7.3.25-r0
|
||||
php7-fileinfo-7.3.25-r0
|
||||
php7-fpm-7.3.25-r0
|
||||
php7-gd-7.3.25-r0
|
||||
php7-json-7.3.25-r0
|
||||
php7-mbstring-7.3.25-r0
|
||||
php7-mysqli-7.3.25-r0
|
||||
php7-mysqlnd-7.3.25-r0
|
||||
php7-openssl-7.3.25-r0
|
||||
php7-pdo-7.3.25-r0
|
||||
php7-pdo_pgsql-7.3.25-r0
|
||||
php7-pdo_sqlite-7.3.25-r0
|
||||
php7-session-7.3.25-r0
|
||||
php7-simplexml-7.3.25-r0
|
||||
php7-xml-7.3.25-r0
|
||||
php7-xmlwriter-7.3.25-r0
|
||||
popt-1.16-r7
|
||||
procps-3.3.16-r0
|
||||
readline-8.0.4-r0
|
||||
scanelf-1.2.6-r0
|
||||
shadow-4.8.1-r0
|
||||
sqlite-libs-3.32.1-r0
|
||||
ssl_client-1.31.1-r19
|
||||
tzdata-2020c-r1
|
||||
xz-5.2.5-r0
|
||||
xz-libs-5.2.5-r0
|
||||
zlib-1.2.11-r3
|
||||
NAME VERSION TYPE
|
||||
acl-libs 2.3.2-r1 apk
|
||||
alpine-baselayout 3.7.0-r0 apk
|
||||
alpine-baselayout-data 3.7.0-r0 apk
|
||||
alpine-keys 2.5-r0 apk
|
||||
alpine-release 3.22.2-r0 apk
|
||||
aom-libs 3.12.1-r0 apk
|
||||
apache2-utils 2.4.66-r0 apk
|
||||
apk-tools 2.14.9-r3 apk
|
||||
apr 1.7.5-r0 apk
|
||||
apr-util 1.6.3-r1 apk
|
||||
argon2-libs 20190702-r5 apk
|
||||
bash 5.2.37-r0 apk
|
||||
brotli-libs 1.1.0-r2 apk
|
||||
busybox 1.37.0-r20 apk
|
||||
busybox-binsh 1.37.0-r20 apk
|
||||
c-ares 1.34.6-r0 apk
|
||||
ca-certificates 20250911-r0 apk
|
||||
ca-certificates-bundle 20250911-r0 apk
|
||||
catatonit 0.2.1-r0 apk
|
||||
composer 2.9.5 binary
|
||||
coreutils 9.7-r1 apk
|
||||
coreutils-env 9.7-r1 apk
|
||||
coreutils-fmt 9.7-r1 apk
|
||||
coreutils-sha512sum 9.7-r1 apk
|
||||
curl 8.14.1-r2 apk
|
||||
findutils 4.10.0-r0 apk
|
||||
freetype 2.13.3-r0 apk
|
||||
git 2.49.1-r0 apk
|
||||
git-init-template 2.49.1-r0 apk
|
||||
jq 1.8.1-r0 apk
|
||||
libapk2 2.14.9-r3 apk
|
||||
libattr 2.5.2-r2 apk
|
||||
libavif 1.3.0-r0 apk
|
||||
libbsd 0.12.2-r0 apk
|
||||
libbz2 1.0.8-r6 apk
|
||||
libcrypto3 3.5.5-r0 apk
|
||||
libcurl 8.14.1-r2 apk
|
||||
libdav1d 1.5.1-r0 apk
|
||||
libedit 20250104.3.1-r1 apk
|
||||
libexpat 2.7.3-r0 apk
|
||||
libgcc 14.2.0-r6 apk
|
||||
libice 1.1.2-r0 apk
|
||||
libidn2 2.3.7-r0 apk
|
||||
libintl 0.24.1-r0 apk
|
||||
libjpeg-turbo 3.1.0-r0 apk
|
||||
libmd 1.1.0-r0 apk
|
||||
libncursesw 6.5_p20250503-r0 apk
|
||||
libpng 1.6.54-r0 apk
|
||||
libpq 17.7-r0 apk
|
||||
libproc2 4.0.4-r3 apk
|
||||
libpsl 0.21.5-r3 apk
|
||||
librespeed-speedtest 5.5.1 npm
|
||||
libsharpyuv 1.5.0-r0 apk
|
||||
libsm 1.2.5-r0 apk
|
||||
libssl3 3.5.5-r0 apk
|
||||
libstdc++ 14.2.0-r6 apk
|
||||
libunistring 1.3-r0 apk
|
||||
libuuid 2.41-r9 apk
|
||||
libwebp 1.5.0-r0 apk
|
||||
libx11 1.8.11-r0 apk
|
||||
libxau 1.0.12-r0 apk
|
||||
libxcb 1.17.0-r0 apk
|
||||
libxdmcp 1.1.5-r1 apk
|
||||
libxext 1.3.6-r2 apk
|
||||
libxml2 2.13.9-r0 apk
|
||||
libxpm 3.5.17-r0 apk
|
||||
libxt 1.3.1-r0 apk
|
||||
libyuv 0.0.1887.20251502-r1 apk
|
||||
libzip 1.11.4-r0 apk
|
||||
linux-pam 1.7.0-r4 apk
|
||||
logrotate 3.21.0-r1 apk
|
||||
musl 1.2.5-r10 apk
|
||||
musl-utils 1.2.5-r10 apk
|
||||
nano 8.4-r0 apk
|
||||
ncurses-terminfo-base 6.5_p20250503-r0 apk
|
||||
netcat-openbsd 1.229.1-r0 apk
|
||||
nghttp2-libs 1.65.0-r0 apk
|
||||
nginx 1.28.0-r3 apk
|
||||
oniguruma 6.9.10-r0 apk
|
||||
openssl 3.5.5-r0 apk
|
||||
pcre2 10.46-r0 apk
|
||||
php84 8.4.16-r0 apk
|
||||
php84-common 8.4.16-r0 apk
|
||||
php84-ctype 8.4.16-r0 apk
|
||||
php84-curl 8.4.16-r0 apk
|
||||
php84-fileinfo 8.4.16-r0 apk
|
||||
php84-fpm 8.4.16-r0 apk
|
||||
php84-gd 8.4.16-r0 apk
|
||||
php84-iconv 8.4.16-r0 apk
|
||||
php84-mbstring 8.4.16-r0 apk
|
||||
php84-mysqlnd 8.4.16-r0 apk
|
||||
php84-openssl 8.4.16-r0 apk
|
||||
php84-pdo 8.4.16-r0 apk
|
||||
php84-pdo_mysql 8.4.16-r0 apk
|
||||
php84-pdo_pgsql 8.4.16-r0 apk
|
||||
php84-pdo_sqlite 8.4.16-r0 apk
|
||||
php84-phar 8.4.16-r0 apk
|
||||
php84-session 8.4.16-r0 apk
|
||||
php84-simplexml 8.4.16-r0 apk
|
||||
php84-xml 8.4.16-r0 apk
|
||||
php84-xmlwriter 8.4.16-r0 apk
|
||||
php84-zip 8.4.16-r0 apk
|
||||
popt 1.19-r4 apk
|
||||
procps-ng 4.0.4-r3 apk
|
||||
readline 8.2.13-r1 apk
|
||||
scanelf 1.3.8-r1 apk
|
||||
shadow 4.17.3-r0 apk
|
||||
skalibs-libs 2.14.4.0-r0 apk
|
||||
sqlite-libs 3.49.2-r1 apk
|
||||
ssl_client 1.37.0-r20 apk
|
||||
tzdata 2025c-r0 apk
|
||||
utmps-libs 0.1.3.1-r0 apk
|
||||
xz-libs 5.8.1-r0 apk
|
||||
zlib 1.3.1-r2 apk
|
||||
zstd-libs 1.5.7-r0 apk
|
||||
|
||||
128
readme-vars.yml
128
readme-vars.yml
@ -4,64 +4,116 @@
|
||||
project_name: librespeed
|
||||
project_url: "https://github.com/librespeed/speedtest"
|
||||
project_logo: "https://raw.githubusercontent.com/librespeed/speedtest/master/.logo/logo3.png"
|
||||
project_blurb: "[{{ project_name|capitalize }}]({{ project_url }}) is a very lightweight Speedtest implemented in Javascript, using XMLHttpRequest and Web Workers.
|
||||
|
||||
No Flash, No Java, No Websocket, No Bullshit."
|
||||
project_lsio_github_repo_url: "https://github.com/linuxserver/docker-{{ project_name }}"
|
||||
project_blurb: |
|
||||
[{{ project_name|capitalize }}]({{ project_url }}) is a very lightweight Speedtest implemented in Javascript, using XMLHttpRequest and Web Workers.
|
||||
|
||||
No Flash, No Java, No Websocket, No Bullshit.
|
||||
project_lsio_github_repo_url: "https://github.com/linuxserver/docker-{{ project_name }}"
|
||||
project_categories: "Monitoring"
|
||||
# supported architectures
|
||||
available_architectures:
|
||||
- { arch: "{{ arch_x86_64 }}", tag: "amd64-latest"}
|
||||
- { arch: "{{ arch_arm64 }}", tag: "arm64v8-latest"}
|
||||
- { arch: "{{ arch_armhf }}", tag: "arm32v7-latest"}
|
||||
|
||||
# development version
|
||||
development_versions: false
|
||||
development_versions_items:
|
||||
- { tag: "latest", desc: "Stable releases" }
|
||||
|
||||
- {arch: "{{ arch_x86_64 }}", tag: "amd64-latest"}
|
||||
- {arch: "{{ arch_arm64 }}", tag: "arm64v8-latest"}
|
||||
# container parameters
|
||||
common_param_env_vars_enabled: true
|
||||
param_container_name: "{{ project_name }}"
|
||||
param_usage_include_vols: true
|
||||
param_volumes:
|
||||
- { vol_path: "/config", vol_host_path: "/path/to/appdata/config", desc: "Contains all relevant configuration files." }
|
||||
- {vol_path: "/config", vol_host_path: "/path/to/{{ project_name }}/config", desc: "Persistent config files"}
|
||||
param_usage_include_ports: true
|
||||
param_ports:
|
||||
- { external_port: "80", internal_port: "80", port_desc: "web gui" }
|
||||
- {external_port: "80", internal_port: "80", port_desc: "web gui"}
|
||||
param_usage_include_env: true
|
||||
param_env_vars:
|
||||
- { env_var: "TZ", env_value: "Europe/London", desc: "Specify a timezone to use EG Europe/London"}
|
||||
- { env_var: "PASSWORD", env_value: "PASSWORD", desc: "Set the password for the results database."}
|
||||
|
||||
- {env_var: "PASSWORD", env_value: "PASSWORD", desc: "Set the password for the results database."}
|
||||
# optional container parameters
|
||||
opt_param_usage_include_env: true
|
||||
opt_param_env_vars:
|
||||
- { env_var: "CUSTOM_RESULTS", env_value: "true", desc: "(optional) enables custom results page in `/config/www/results/index.php`."}
|
||||
- { env_var: "DB_TYPE", env_value: "sqlite", desc: "Defaults to `sqlite`, can also be set to `mysql` or `postgresql`."}
|
||||
- { env_var: "DB_NAME", env_value: "DB_NAME", desc: "Database name. Required for mysql and pgsql."}
|
||||
- { env_var: "DB_HOSTNAME", env_value: "DB_HOSTNAME", desc: "Database address. Required for mysql and pgsql."}
|
||||
- { env_var: "DB_USERNAME", env_value: "DB_USERNAME", desc: "Database username. Required for mysql and pgsql."}
|
||||
- { env_var: "DB_PASSWORD", env_value: "DB_PASSWORD", desc: "Database password. Required for mysql and pgsql."}
|
||||
|
||||
optional_block_1: false
|
||||
optional_block_1_items: ""
|
||||
|
||||
- {env_var: "CUSTOM_RESULTS", env_value: "false", desc: "(optional) set to `true` to enable custom results page in `/config/www/results/index.php`."}
|
||||
- {env_var: "DB_TYPE", env_value: "sqlite", desc: "Defaults to `sqlite`, can also be set to `mysql` or `postgresql`."}
|
||||
- {env_var: "DB_NAME", env_value: "DB_NAME", desc: "Database name. Required for mysql and pgsql."}
|
||||
- {env_var: "DB_HOSTNAME", env_value: "DB_HOSTNAME", desc: "Database address. Required for mysql and pgsql."}
|
||||
- {env_var: "DB_USERNAME", env_value: "DB_USERNAME", desc: "Database username. Required for mysql and pgsql."}
|
||||
- {env_var: "DB_PASSWORD", env_value: "DB_PASSWORD", desc: "Database password. Required for mysql and pgsql."}
|
||||
- {env_var: "DB_PORT", env_value: "DB_PORT", desc: "Database port. Required for mysql."}
|
||||
- {env_var: "IPINFO_APIKEY", env_value: "ACCESS_TOKEN", desc: "Access token from ipinfo.io. Required for detailed IP information."}
|
||||
# application setup block
|
||||
app_setup_block_enabled: true
|
||||
app_setup_block: |
|
||||
Access the speedtest webui at `http://SERVERIP`. The results database can be accessed at `http://SERVERIP/results/stats.php` with the password set.
|
||||
The default template used is based on `example-singleServer-full.html`. However, all templates are provided for reference at `/config/www/`. Feel free to customize `/config/www/index.html` as you like. Delete the file and restart to go back to the image default.
|
||||
|
||||
You can optionally place customized `speedtest.js` and `speedtest_worker.js` files under `/config/www` and they will supersede the defaults after a container start. Keep in mind that once you do so, they will no longer be updated. You can delete them and recreate the container to go back to the image defaults.
|
||||
|
||||
If you are setting up a mysql or postgresql database, you first need to import the tables into your database as described at the following link
|
||||
Access the speedtest webui at `http://SERVERIP`. The results database can be accessed at `http://SERVERIP/results/stats.php` with the password set.
|
||||
The default template used is based on `example-singleServer-full.html`. However, all templates are provided for reference at `/config/www/`. Feel free to customize `/config/www/index.html` as you like. Delete the file and restart to go back to the image default.
|
||||
|
||||
You can optionally place customized `speedtest.js` and `speedtest_worker.js` files under `/config/www` and they will supersede the defaults after a container start. Keep in mind that once you do so, they will no longer be updated. You can delete them and recreate the container to go back to the image defaults.
|
||||
|
||||
If you are setting up a mysql or postgresql database, you first need to import the tables into your database as described at the following link
|
||||
https://github.com/librespeed/speedtest/blob/master/doc.md#creating-the-database
|
||||
|
||||
To enable a custom results page set the environment variable `CUSTOM_RESULTS=true` and start (or restart) the container at least once for `/config/www/results/index.php` to be created and modify this file to your liking.
|
||||
|
||||
# init diagram
|
||||
init_diagram: |
|
||||
"librespeed:latest": {
|
||||
docker-mods
|
||||
base {
|
||||
fix-attr +\nlegacy cont-init
|
||||
}
|
||||
docker-mods -> base
|
||||
legacy-services
|
||||
custom services
|
||||
init-services -> legacy-services
|
||||
init-services -> custom services
|
||||
custom services -> legacy-services
|
||||
legacy-services -> ci-service-check
|
||||
init-migrations -> init-adduser
|
||||
init-nginx-end -> init-config
|
||||
init-os-end -> init-config
|
||||
init-config -> init-config-end
|
||||
init-crontab-config -> init-config-end
|
||||
init-librespeed-config -> init-config-end
|
||||
init-config -> init-crontab-config
|
||||
init-mods-end -> init-custom-files
|
||||
init-adduser -> init-device-perms
|
||||
base -> init-envfile
|
||||
init-os-end -> init-folders
|
||||
init-php -> init-keygen
|
||||
init-nginx-end -> init-librespeed-config
|
||||
base -> init-migrations
|
||||
init-config-end -> init-mods
|
||||
init-mods-package-install -> init-mods-end
|
||||
init-mods -> init-mods-package-install
|
||||
init-samples -> init-nginx
|
||||
init-version-checks -> init-nginx-end
|
||||
init-adduser -> init-os-end
|
||||
init-device-perms -> init-os-end
|
||||
init-envfile -> init-os-end
|
||||
init-keygen -> init-permissions
|
||||
init-nginx -> init-php
|
||||
init-folders -> init-samples
|
||||
init-custom-files -> init-services
|
||||
init-permissions -> init-version-checks
|
||||
init-services -> svc-cron
|
||||
svc-cron -> legacy-services
|
||||
init-services -> svc-nginx
|
||||
svc-nginx -> legacy-services
|
||||
init-services -> svc-php-fpm
|
||||
svc-php-fpm -> legacy-services
|
||||
}
|
||||
Base Images: {
|
||||
"baseimage-alpine-nginx:3.22" <- "baseimage-alpine:3.22"
|
||||
}
|
||||
"librespeed:latest" <- Base Images
|
||||
# changelog
|
||||
changelogs:
|
||||
- { date: "01.06.20:", desc: "Rebasing to alpine 3.12." }
|
||||
- { date: "29.04.20:", desc: "Add donation links for LibreSpeed to Github sponsor button and container log." }
|
||||
- { date: "09.01.20:", desc: "Initial Release." }
|
||||
- {date: "27.07.25:", desc: "Rebase to Alpine 3.22."}
|
||||
- {date: "27.06.24:", desc: "Rebase to Alpine 3.20. Existing users should update their nginx confs to avoid http2 deprecation warnings."}
|
||||
- {date: "23.12.23:", desc: "Rebase to Alpine 3.19 with php 8.3."}
|
||||
- {date: "06.12.23:", desc: "Replace php mysqli with php pdo_pgsql."}
|
||||
- {date: "25.05.23:", desc: "Rebase to Alpine 3.18, deprecate armhf."}
|
||||
- {date: "14.05.23:", desc: "Added support for ipinfo.io"}
|
||||
- {date: "20.01.23:", desc: "Rebase to alpine 3.17 with php8.1."}
|
||||
- {date: "20.08.22:", desc: "Rebasing to alpine 3.15 with php8. Restructure nginx configs ([see changes announcement](https://info.linuxserver.io/issues/2022-08-20-nginx-base))."}
|
||||
- {date: "01.03.21:", desc: "Fix up database settings. Make sure `index.html` is recreated."}
|
||||
- {date: "28.02.21:", desc: "Added php7-ctype."}
|
||||
- {date: "23.01.21:", desc: "Rebasing to alpine 3.13."}
|
||||
- {date: "01.06.20:", desc: "Rebasing to alpine 3.12."}
|
||||
- {date: "29.04.20:", desc: "Add donation links for LibreSpeed to Github sponsor button and container log."}
|
||||
- {date: "09.01.20:", desc: "Initial Release."}
|
||||
|
||||
@ -1,31 +0,0 @@
|
||||
## Version 2020/01/06 - Changelog: https://github.com/linuxserver/docker-librespeed/commits/master/root/defaults/default
|
||||
|
||||
server {
|
||||
listen 80 default_server;
|
||||
|
||||
listen 443 ssl;
|
||||
|
||||
root /usr/share/webapps/librespeed;
|
||||
index index.php index.html index.htm;
|
||||
|
||||
real_ip_header X-Forwarded-For;
|
||||
set_real_ip_from 172.17.0.0/16;
|
||||
|
||||
server_name _;
|
||||
|
||||
ssl_certificate /config/keys/cert.crt;
|
||||
ssl_certificate_key /config/keys/cert.key;
|
||||
|
||||
client_max_body_size 0;
|
||||
|
||||
location / {
|
||||
try_files $uri $uri/ /index.html;
|
||||
}
|
||||
|
||||
location ~ \.php$ {
|
||||
fastcgi_split_path_info ^(.+\.php)(/.+)$;
|
||||
fastcgi_pass 127.0.0.1:9000;
|
||||
fastcgi_index index.php;
|
||||
include /etc/nginx/fastcgi_params;
|
||||
}
|
||||
}
|
||||
@ -349,4 +349,4 @@ function initUI(){
|
||||
</div>
|
||||
<script type="text/javascript">setTimeout(function(){initUI()},100);</script>
|
||||
</body>
|
||||
</html>
|
||||
</html>
|
||||
@ -1,61 +0,0 @@
|
||||
#!/usr/bin/with-contenv bash
|
||||
|
||||
# make our folders
|
||||
mkdir -p \
|
||||
/config/www \
|
||||
/config/www/img
|
||||
|
||||
# create symlink to index.html
|
||||
[[ ! -L /usr/share/webapps/librespeed/index.html ]] && \
|
||||
ln -s /config/www/index.html /usr/share/webapps/librespeed/index.html
|
||||
|
||||
# update templates
|
||||
cp /usr/share/webapps/librespeed/example*.html /config/www/
|
||||
|
||||
# use custom js files if exist
|
||||
[[ -f /config/www/speedtest.js ]] && \
|
||||
cp /config/www/speedtest.js /usr/share/webapps/librespeed/speedtest.js
|
||||
[[ -f /config/www/speedtest_worker.js ]] && \
|
||||
cp /config/www/speedtest_worker.js /usr/share/webapps/librespeed/speedtest_worker.js
|
||||
|
||||
# enables custom results page
|
||||
if "$CUSTOM_RESULTS"; then
|
||||
echo "custom results"
|
||||
[[ ! -e "/config/www/results/index.php" ]] && \
|
||||
mkdir -p /config/www/results/ && \
|
||||
mv /usr/share/webapps/librespeed/results/index.php /config/www/results/index.php
|
||||
ln -sf /config/www/results/index.php /usr/share/webapps/librespeed/results/index.php
|
||||
fi
|
||||
|
||||
# configure app settings
|
||||
sed -i "\
|
||||
s|\$Sqlite_db_file = \"../../speedtest_telemetry.sql\";|\$Sqlite_db_file = \"/config/speedtest_telemetry.sql\";|g; \
|
||||
s|\$enable_id_obfuscation=false;|\$enable_id_obfuscation=true;|g;
|
||||
s|\$stats_password=\"PASSWORD\";|\$stats_password=\"${PASSWORD}\";|g" \
|
||||
/usr/share/webapps/librespeed/results/telemetry_settings.php
|
||||
if [ "$DB_TYPE" = "postgresql" ]; then
|
||||
sed -i "\
|
||||
s|\$db_type=\"mysql\";|\$db_type=\"${DB_TYPE}\";|g \
|
||||
s|\$PostgreSql_username=\"USERNAME\";|\$PostgreSql_username=\"${DB_USERNAME}\";|g; \
|
||||
s|\$PostgreSql_password=\"PASSWORD\";|\$PostgreSql_password=\"${DB_PASSWORD}\";|g; \
|
||||
s|\$PostgreSql_hostname=\"DB_HOSTNAME\";|\$PostgreSql_hostname=\"${DB_HOSTNAME}\";|g; \
|
||||
s|\$PostgreSql_databasename=\"DB_NAME\";|\$PostgreSql_databasename=\"${DB_NAME}\";|g" \
|
||||
/usr/share/webapps/librespeed/results/telemetry_settings.php
|
||||
elif [ "$DB_TYPE" = "mysql" ]; then
|
||||
sed -i "\
|
||||
s|\$MySql_username=\"USERNAME\";|\$MySql_username=\"${DB_USERNAME}\";|g; \
|
||||
s|\$MySql_password=\"PASSWORD\";|\$MySql_password=\"${DB_PASSWORD}\";|g; \
|
||||
s|\$MySql_hostname=\"DB_HOSTNAME\";|\$MySql_hostname=\"${DB_HOSTNAME}\";|g; \
|
||||
s|\$MySql_databasename=\"DB_NAME\";|\$MySql_databasename=\"${DB_NAME}\";|g" \
|
||||
/usr/share/webapps/librespeed/results/telemetry_settings.php
|
||||
else
|
||||
sed -i \
|
||||
"s|\$db_type=\"mysql\";|\$db_type=\"sqlite\";|g" \
|
||||
/usr/share/webapps/librespeed/results/telemetry_settings.php
|
||||
fi
|
||||
|
||||
# permissions
|
||||
echo "Setting permissions"
|
||||
chown -R abc:abc \
|
||||
/usr/share/webapps/librespeed \
|
||||
/config
|
||||
70
root/etc/s6-overlay/s6-rc.d/init-librespeed-config/run
Executable file
70
root/etc/s6-overlay/s6-rc.d/init-librespeed-config/run
Executable file
@ -0,0 +1,70 @@
|
||||
#!/usr/bin/with-contenv bash
|
||||
# shellcheck shell=bash
|
||||
|
||||
# make our folders
|
||||
mkdir -p \
|
||||
/config/www/img
|
||||
|
||||
# create symlink to index.html
|
||||
if [[ ! -L /app/www/public/index.html ]]; then
|
||||
ln -sf /config/www/index.html /app/www/public/index.html
|
||||
fi
|
||||
|
||||
# update templates
|
||||
cp /app/www/public/examples/example*.html /config/www/
|
||||
|
||||
# use custom js files if exist
|
||||
if [[ -f /config/www/speedtest.js ]]; then
|
||||
cp /config/www/speedtest.js /app/www/public/speedtest.js
|
||||
fi
|
||||
if [[ -f /config/www/speedtest_worker.js ]]; then
|
||||
cp /config/www/speedtest_worker.js /app/www/public/speedtest_worker.js
|
||||
fi
|
||||
|
||||
# sets apikey for ipinfo.io, if it exists
|
||||
if [ -n "$IPINFO_APIKEY" ]; then
|
||||
sed -i "s/\$IPINFO_APIKEY = .*/\$IPINFO_APIKEY = '${IPINFO_APIKEY:-}';/g" \
|
||||
/app/www/public/backend/getIP_ipInfo_apikey.php
|
||||
fi
|
||||
|
||||
# enables custom results page
|
||||
if [ "$CUSTOM_RESULTS" == "true" ]; then
|
||||
echo "custom results"
|
||||
if [[ ! -e "/config/www/results/index.php" ]]; then
|
||||
mkdir -p /config/www/results/
|
||||
mv /app/www/public/results/index.php /config/www/results/index.php
|
||||
fi
|
||||
ln -sf /config/www/results/index.php /app/www/public/results/index.php
|
||||
fi
|
||||
|
||||
# configure app settings
|
||||
sed -i "\
|
||||
s|\$Sqlite_db_file.*|\$Sqlite_db_file = \'/config/speedtest_telemetry.sql\';|g; \
|
||||
s|\$enable_id_obfuscation.*|\$enable_id_obfuscation = true;|g;
|
||||
s|\$stats_password.*|\$stats_password = \'${PASSWORD}\';|g" \
|
||||
/app/www/public/results/telemetry_settings.php
|
||||
if [ "$DB_TYPE" = "postgresql" ]; then
|
||||
sed -i "\
|
||||
s|\$db_type.*|\$db_type = \'${DB_TYPE}\';|g; \
|
||||
s|\$PostgreSql_username.*|\$PostgreSql_username = \'${DB_USERNAME}\';|g; \
|
||||
s|\$PostgreSql_password.*|\$PostgreSql_password = \'${DB_PASSWORD}\';|g; \
|
||||
s|\$PostgreSql_hostname.*|\$PostgreSql_hostname = \'${DB_HOSTNAME}\';|g; \
|
||||
s|\$PostgreSql_databasename.*|\$PostgreSql_databasename = \'${DB_NAME}\';|g" \
|
||||
/app/www/public/results/telemetry_settings.php
|
||||
elif [ "$DB_TYPE" = "mysql" ]; then
|
||||
sed -i "\
|
||||
s|\$MySql_username.*|\$MySql_username = \'${DB_USERNAME}\';|g; \
|
||||
s|\$MySql_password.*|\$MySql_password = \'${DB_PASSWORD}\';|g; \
|
||||
s|\$MySql_hostname.*|\$MySql_hostname = \'${DB_HOSTNAME}\';|g; \
|
||||
s|\$MySql_databasename.*|\$MySql_databasename = \'${DB_NAME}\';|g; \
|
||||
s|\$MySql_port.*|\$MySql_port = \'${DB_PORT:-3306}\';|g" \
|
||||
/app/www/public/results/telemetry_settings.php
|
||||
else
|
||||
sed -i \
|
||||
"s|\$db_type.*|\$db_type = \'sqlite\';|g" \
|
||||
/app/www/public/results/telemetry_settings.php
|
||||
fi
|
||||
|
||||
# permissions
|
||||
lsiown -R abc:abc \
|
||||
/config
|
||||
1
root/etc/s6-overlay/s6-rc.d/init-librespeed-config/type
Normal file
1
root/etc/s6-overlay/s6-rc.d/init-librespeed-config/type
Normal file
@ -0,0 +1 @@
|
||||
oneshot
|
||||
1
root/etc/s6-overlay/s6-rc.d/init-librespeed-config/up
Normal file
1
root/etc/s6-overlay/s6-rc.d/init-librespeed-config/up
Normal file
@ -0,0 +1 @@
|
||||
/etc/s6-overlay/s6-rc.d/init-librespeed-config/run
|
||||
11
root/migrations/02-default-location
Executable file
11
root/migrations/02-default-location
Executable file
@ -0,0 +1,11 @@
|
||||
#!/usr/bin/with-contenv bash
|
||||
# shellcheck shell=bash
|
||||
|
||||
DEFAULT_CONF="/config/nginx/site-confs/default.conf"
|
||||
OLD_ROOT="root /usr/share/webapps/librespeed;"
|
||||
NEW_ROOT="root /app/www/public;"
|
||||
|
||||
if [[ -f "${DEFAULT_CONF}" ]] && grep -q "${OLD_ROOT}" "${DEFAULT_CONF}" 2>/dev/null; then
|
||||
echo "updating root in ${DEFAULT_CONF}"
|
||||
sed -i "s|${OLD_ROOT}|${NEW_ROOT}|" "${DEFAULT_CONF}"
|
||||
fi
|
||||
40
root/usr/share/webapps/librespeed/index.html
Normal file
40
root/usr/share/webapps/librespeed/index.html
Normal file
@ -0,0 +1,40 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>Upgrade Required!</title>
|
||||
<style>
|
||||
body{
|
||||
font-family: Helvetica, Arial, sans-serif;
|
||||
}
|
||||
.message{
|
||||
width:440px;
|
||||
padding:20px 40px;
|
||||
margin:0 auto;
|
||||
background-color:#f9f9f9;
|
||||
border:1px solid #ddd;
|
||||
color: #1e3d62;
|
||||
}
|
||||
center{
|
||||
margin:40px 0;
|
||||
}
|
||||
h1{
|
||||
font-size: 18px;
|
||||
line-height: 26px;
|
||||
}
|
||||
p{
|
||||
font-size: 12px;
|
||||
}
|
||||
a{
|
||||
color: rgb(207, 48, 139);
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="message">
|
||||
<h1>Upgrade Required!</h1>
|
||||
<p>The application inside this image has been moved to a new folder.</p>
|
||||
<p>You will need to update your <strong>/config/nginx/nginx.conf</strong> and <strong>/config/nginx/site-confs/default.conf</strong> in order for the application to work.</p>
|
||||
<p>New config samples are located at <strong>/config/nginx/nginx.conf.sample</strong> and <strong>/config/nginx/site-confs/default.conf.sample</strong></p>
|
||||
<p>Please review our announcement: <a target="_blank" href="https://info.linuxserver.io/issues/2022-08-20-nginx-base/">Significant changes to nginx based images</a></p>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
Loading…
x
Reference in New Issue
Block a user