mirror of
https://github.com/linuxserver/docker-pyload-ng.git
synced 2026-03-09 00:08:04 +08:00
Compare commits
164 Commits
main
...
develop-69
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
3f5416cfc8 | ||
|
|
5193e6880e | ||
|
|
43ede02456 | ||
|
|
839e39902f | ||
|
|
0eae77c7a7 | ||
|
|
5095789fd2 | ||
|
|
64650966f3 | ||
|
|
bfc8cc2908 | ||
|
|
7d5cb47fad | ||
|
|
c18c96f44a | ||
|
|
9b392fe5a9 | ||
|
|
546d20039d | ||
|
|
eff1f69ba9 | ||
|
|
a604bba084 | ||
|
|
3d79e61f4f | ||
|
|
292d6d4f75 | ||
|
|
6f19d8f916 | ||
|
|
8f6cfa1834 | ||
|
|
c4da6dad7a | ||
|
|
47dfc8fd46 | ||
|
|
f39447b6ee | ||
|
|
64c8cca21d | ||
|
|
5207b4f9d0 | ||
|
|
bbe558d9d4 | ||
|
|
bfacd874b1 | ||
|
|
d207695c27 | ||
|
|
7ef56f8874 | ||
|
|
c37fadb3d0 | ||
|
|
cabde22029 | ||
|
|
7d614e4322 | ||
|
|
752e712781 | ||
|
|
c386926b2b | ||
|
|
45c8e60670 | ||
|
|
41aed8c33b | ||
|
|
d78bf490e5 | ||
|
|
50ee8069e7 | ||
|
|
4f94522d09 | ||
|
|
12c5b882c1 | ||
|
|
05d667d951 | ||
|
|
79e528a115 | ||
|
|
da3bfcbba5 | ||
|
|
b508c2eaff | ||
|
|
9f9744c8c4 | ||
|
|
3a0dbfbb08 | ||
|
|
722b3d9a0f | ||
|
|
ec499e203f | ||
|
|
d1e25faac8 | ||
|
|
9f5f289da9 | ||
|
|
8dbac7b648 | ||
|
|
9c5220ce09 | ||
|
|
ed0f20525a | ||
|
|
05b1c9bf1b | ||
|
|
5b05d85cdf | ||
|
|
a856733aa0 | ||
|
|
8df0253045 | ||
|
|
c28eec4066 | ||
|
|
360ac1e7c2 | ||
|
|
5feb3a5eca | ||
|
|
03b70fd5ae | ||
|
|
1a2e650498 | ||
|
|
af30fd2972 | ||
|
|
865b9aabb7 | ||
|
|
fabb73eb8a | ||
|
|
3c39ba092b | ||
|
|
62f193293c | ||
|
|
59e5c27aa9 | ||
|
|
2e8d67443a | ||
|
|
bfced7d98c | ||
|
|
4898c968d8 | ||
|
|
a0c16fbb3b | ||
|
|
c96a00ad8e | ||
|
|
5dc7401afb | ||
|
|
da21b9f28d | ||
|
|
96eb0285fc | ||
|
|
d0dd079b63 | ||
|
|
de22bfdee5 | ||
|
|
cb600f8c8b | ||
|
|
1427eec17d | ||
|
|
c186897ad2 | ||
|
|
37f89838fb | ||
|
|
476a8a98f5 | ||
|
|
dd0de3f09d | ||
|
|
9ab82d98e9 | ||
|
|
8501987990 | ||
|
|
9f7749809d | ||
|
|
6c5b2fdb11 | ||
|
|
f26b16bbb3 | ||
|
|
b97035dc26 | ||
|
|
aefe2425ab | ||
|
|
801e85be2f | ||
|
|
7b0f11d146 | ||
|
|
8595a7ff99 | ||
|
|
6f12035ae5 | ||
|
|
7a919206ed | ||
|
|
7ce23b6992 | ||
|
|
71d777c171 | ||
|
|
5a599c5c1d | ||
|
|
59729f5890 | ||
|
|
bedbb45375 | ||
|
|
95a520c79b | ||
|
|
a15760c23c | ||
|
|
aee499798b | ||
|
|
3fa5049563 | ||
|
|
9f631a1235 | ||
|
|
adaaefcb60 | ||
|
|
b6dae6cca0 | ||
|
|
db741fe766 | ||
|
|
3bd4cd4799 | ||
|
|
0cea5bdbbd | ||
|
|
de32b2cd89 | ||
|
|
f13b23aed4 | ||
|
|
d1781f4542 | ||
|
|
32ea7f2b70 | ||
|
|
94a7327114 | ||
|
|
f9348eb6e8 | ||
|
|
7673b2de3c | ||
|
|
880f051725 | ||
|
|
5530284c35 | ||
|
|
1277309e6a | ||
|
|
5f608766bf | ||
|
|
e93ec89a10 | ||
|
|
560aa28b60 | ||
|
|
3746a0faae | ||
|
|
87783064c9 | ||
|
|
8d607f1dc5 | ||
|
|
e51f1faa96 | ||
|
|
84f5a928c8 | ||
|
|
6cbc28b088 | ||
|
|
aa943418a2 | ||
|
|
7fc6527d1d | ||
|
|
2aead8e1a3 | ||
|
|
363c1cc01e | ||
|
|
d11fff1c16 | ||
|
|
a88c34c656 | ||
|
|
8f9c3b3602 | ||
|
|
d999fef2a3 | ||
|
|
0f9934c6f4 | ||
|
|
a1fa5a844d | ||
|
|
e6a54abdc5 | ||
|
|
6848804bd8 | ||
|
|
fa8aaeda6c | ||
|
|
e88d359416 | ||
|
|
0388d62f80 | ||
|
|
c9b209fe46 | ||
|
|
35ea513bc4 | ||
|
|
5a6cf191ed | ||
|
|
c010364a8e | ||
|
|
f3cae9a9cc | ||
|
|
282046b730 | ||
|
|
c3e1334175 | ||
|
|
7ddf36add8 | ||
|
|
83cb34048a | ||
|
|
28b5e46a87 | ||
|
|
88261eef17 | ||
|
|
99636278e8 | ||
|
|
0719a1d9d1 | ||
|
|
e3b3242356 | ||
|
|
5b876a5e2d | ||
|
|
2ac5ea2ae3 | ||
|
|
a6f5e3493c | ||
|
|
b1b05f0455 | ||
|
|
cd276ffaae | ||
|
|
5597b4c218 | ||
|
|
479dfa16fa |
@ -15,6 +15,6 @@ trim_trailing_whitespace = false
|
|||||||
indent_style = space
|
indent_style = space
|
||||||
indent_size = 2
|
indent_size = 2
|
||||||
|
|
||||||
[{**.sh,root/etc/cont-init.d/**,root/etc/services.d/**}]
|
[{**.sh,root/etc/s6-overlay/s6-rc.d/**,root/etc/cont-init.d/**,root/etc/services.d/**}]
|
||||||
indent_style = space
|
indent_style = space
|
||||||
indent_size = 4
|
indent_size = 4
|
||||||
|
|||||||
4
.github/CONTRIBUTING.md
vendored
4
.github/CONTRIBUTING.md
vendored
@ -24,7 +24,7 @@
|
|||||||
## Readme
|
## Readme
|
||||||
|
|
||||||
If you would like to change our readme, please __**do not**__ directly edit the readme, as it is auto-generated on each commit.
|
If you would like to change our readme, please __**do not**__ directly edit the readme, as it is auto-generated on each commit.
|
||||||
Instead edit the [readme-vars.yml](https://github.com/linuxserver/docker-pyload-ng/edit/main/readme-vars.yml).
|
Instead edit the [readme-vars.yml](https://github.com/linuxserver/docker-pyload-ng/edit/develop/readme-vars.yml).
|
||||||
|
|
||||||
These variables are used in a template for our [Jenkins Builder](https://github.com/linuxserver/docker-jenkins-builder) as part of an ansible play.
|
These variables are used in a template for our [Jenkins Builder](https://github.com/linuxserver/docker-jenkins-builder) as part of an ansible play.
|
||||||
Most of these variables are also carried over to [docs.linuxserver.io](https://docs.linuxserver.io/images/docker-pyload-ng)
|
Most of these variables are also carried over to [docs.linuxserver.io](https://docs.linuxserver.io/images/docker-pyload-ng)
|
||||||
@ -115,7 +115,7 @@ Once registered you can define the dockerfile to use with `-f Dockerfile.aarch64
|
|||||||
|
|
||||||
## Update the changelog
|
## Update the changelog
|
||||||
|
|
||||||
If you are modifying the Dockerfiles or any of the startup scripts in [root](https://github.com/linuxserver/docker-pyload-ng/tree/main/root), add an entry to the changelog
|
If you are modifying the Dockerfiles or any of the startup scripts in [root](https://github.com/linuxserver/docker-pyload-ng/tree/develop/root), add an entry to the changelog
|
||||||
|
|
||||||
```yml
|
```yml
|
||||||
changelogs:
|
changelogs:
|
||||||
|
|||||||
1
.github/FUNDING.yml
vendored
1
.github/FUNDING.yml
vendored
@ -1,2 +1,3 @@
|
|||||||
github: linuxserver
|
github: linuxserver
|
||||||
open_collective: linuxserver
|
open_collective: linuxserver
|
||||||
|
custom: ["https://PayPal.Me/nitzo2001/0usd",]
|
||||||
|
|||||||
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 pyload-ng" -->
|
|
||||||
76
.github/ISSUE_TEMPLATE/issue.bug.yml
vendored
Executable file
76
.github/ISSUE_TEMPLATE/issue.bug.yml
vendored
Executable 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 linuxserver.io"
|
||||||
|
label: Container logs
|
||||||
|
placeholder: |
|
||||||
|
Output of `docker logs linuxserver.io`
|
||||||
|
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
Executable file
31
.github/ISSUE_TEMPLATE/issue.feature.yml
vendored
Executable 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
@ -21,7 +21,7 @@
|
|||||||
|
|
||||||
------------------------------
|
------------------------------
|
||||||
|
|
||||||
- [ ] I have read the [contributing](https://github.com/linuxserver/docker-pyload-ng/blob/main/.github/CONTRIBUTING.md) guideline and understand that I have made the correct modifications
|
- [ ] I have read the [contributing](https://github.com/linuxserver/docker-pyload-ng/blob/develop/.github/CONTRIBUTING.md) guideline and understand that I have made the correct modifications
|
||||||
|
|
||||||
------------------------------
|
------------------------------
|
||||||
|
|
||||||
|
|||||||
16
.github/workflows/call_issue_pr_tracker.yml
vendored
Executable file
16
.github/workflows/call_issue_pr_tracker.yml
vendored
Executable file
@ -0,0 +1,16 @@
|
|||||||
|
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]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
manage-project:
|
||||||
|
permissions:
|
||||||
|
issues: write
|
||||||
|
uses: linuxserver/github-workflows/.github/workflows/issue-pr-tracker.yml@v1
|
||||||
|
secrets: inherit
|
||||||
13
.github/workflows/call_issues_cron.yml
vendored
Executable file
13
.github/workflows/call_issues_cron.yml
vendored
Executable file
@ -0,0 +1,13 @@
|
|||||||
|
name: Mark stale issues and pull requests
|
||||||
|
on:
|
||||||
|
schedule:
|
||||||
|
- cron: '23 14 * * *'
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
stale:
|
||||||
|
permissions:
|
||||||
|
issues: write
|
||||||
|
pull-requests: write
|
||||||
|
uses: linuxserver/github-workflows/.github/workflows/issues-cron.yml@v1
|
||||||
|
secrets: inherit
|
||||||
42
.github/workflows/external_trigger.yml
vendored
42
.github/workflows/external_trigger.yml
vendored
@ -4,24 +4,26 @@ on:
|
|||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
external-trigger-main:
|
external-trigger-develop:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2.3.3
|
- uses: actions/checkout@v3.1.0
|
||||||
|
|
||||||
- name: External Trigger
|
- name: External Trigger
|
||||||
if: github.ref == 'refs/heads/main'
|
if: github.ref == 'refs/heads/develop'
|
||||||
run: |
|
run: |
|
||||||
if [ -n "${{ secrets.PAUSE_EXTERNAL_TRIGGER_PYLOAD_NG_MAIN }}" ]; then
|
if [ -n "${{ secrets.PAUSE_EXTERNAL_TRIGGER_PYLOAD_NG_DEVELOP }}" ]; then
|
||||||
echo "**** Github secret PAUSE_EXTERNAL_TRIGGER_PYLOAD_NG_MAIN is set; skipping trigger. ****"
|
echo "**** Github secret PAUSE_EXTERNAL_TRIGGER_PYLOAD_NG_DEVELOP is set; skipping trigger. ****"
|
||||||
|
echo "Github secret \`PAUSE_EXTERNAL_TRIGGER_PYLOAD_NG_DEVELOP\` is set; skipping trigger." >> $GITHUB_STEP_SUMMARY
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
fi
|
||||||
echo "**** External trigger running off of main branch. To disable this trigger, set a Github secret named \"PAUSE_EXTERNAL_TRIGGER_PYLOAD_NG_MAIN\". ****"
|
echo "**** External trigger running off of develop branch. To disable this trigger, set a Github secret named \"PAUSE_EXTERNAL_TRIGGER_PYLOAD_NG_DEVELOP\". ****"
|
||||||
|
echo "External trigger running off of develop branch. To disable this trigger, set a Github secret named \`PAUSE_EXTERNAL_TRIGGER_PYLOAD_NG_DEVELOP\`" >> $GITHUB_STEP_SUMMARY
|
||||||
echo "**** Retrieving external version ****"
|
echo "**** Retrieving external version ****"
|
||||||
EXT_RELEASE=$(curl -sL "https://pypi.python.org/pypi/pyload-ng/json" |jq -r '. | .info.version')
|
EXT_RELEASE=$(curl -u "${{ secrets.CR_USER }}:${{ secrets.CR_PAT }}" -sX GET "https://api.github.com/repos/pyload/pyload/commits/develop" | jq -r '. | .sha' | cut -c1-8)
|
||||||
if [ -z "${EXT_RELEASE}" ] || [ "${EXT_RELEASE}" == "null" ]; then
|
if [ -z "${EXT_RELEASE}" ] || [ "${EXT_RELEASE}" == "null" ]; then
|
||||||
echo "**** Can't retrieve external version, exiting ****"
|
echo "**** Can't retrieve external version, exiting ****"
|
||||||
FAILURE_REASON="Can't retrieve external version for pyload-ng branch main"
|
FAILURE_REASON="Can't retrieve external version for pyload-ng branch develop"
|
||||||
GHA_TRIGGER_URL="https://github.com/linuxserver/docker-pyload-ng/actions/runs/${{ github.run_id }}"
|
GHA_TRIGGER_URL="https://github.com/linuxserver/docker-pyload-ng/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,
|
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**Trigger URL:** '"${GHA_TRIGGER_URL}"' \n"}],
|
"description": "**Trigger Failed** \n**Reason:** '"${FAILURE_REASON}"' \n**Trigger URL:** '"${GHA_TRIGGER_URL}"' \n"}],
|
||||||
@ -30,9 +32,10 @@ jobs:
|
|||||||
fi
|
fi
|
||||||
EXT_RELEASE=$(echo ${EXT_RELEASE} | sed 's/[~,%@+;:/]//g')
|
EXT_RELEASE=$(echo ${EXT_RELEASE} | sed 's/[~,%@+;:/]//g')
|
||||||
echo "**** External version: ${EXT_RELEASE} ****"
|
echo "**** External version: ${EXT_RELEASE} ****"
|
||||||
|
echo "External version: ${EXT_RELEASE}" >> $GITHUB_STEP_SUMMARY
|
||||||
echo "**** Retrieving last pushed version ****"
|
echo "**** Retrieving last pushed version ****"
|
||||||
image="linuxserver/pyload-ng"
|
image="linuxserver/pyload-ng"
|
||||||
tag="latest"
|
tag="develop"
|
||||||
token=$(curl -sX GET \
|
token=$(curl -sX GET \
|
||||||
"https://ghcr.io/token?scope=repository%3Alinuxserver%2Fpyload-ng%3Apull" \
|
"https://ghcr.io/token?scope=repository%3Alinuxserver%2Fpyload-ng%3Apull" \
|
||||||
| jq -r '.token')
|
| jq -r '.token')
|
||||||
@ -48,29 +51,37 @@ jobs:
|
|||||||
| jq -r '.config.digest')
|
| jq -r '.config.digest')
|
||||||
image_info=$(curl -sL \
|
image_info=$(curl -sL \
|
||||||
--header "Authorization: Bearer ${token}" \
|
--header "Authorization: Bearer ${token}" \
|
||||||
"https://ghcr.io/v2/${image}/blobs/${digest}" \
|
"https://ghcr.io/v2/${image}/blobs/${digest}")
|
||||||
| jq -r '.container_config')
|
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_RELEASE=$(echo ${image_info} | jq -r '.Labels.build_version' | awk '{print $3}')
|
||||||
IMAGE_VERSION=$(echo ${IMAGE_RELEASE} | awk -F'-ls' '{print $1}')
|
IMAGE_VERSION=$(echo ${IMAGE_RELEASE} | awk -F'-ls' '{print $1}')
|
||||||
if [ -z "${IMAGE_VERSION}" ]; then
|
if [ -z "${IMAGE_VERSION}" ]; then
|
||||||
echo "**** Can't retrieve last pushed version, exiting ****"
|
echo "**** Can't retrieve last pushed version, exiting ****"
|
||||||
FAILURE_REASON="Can't retrieve last pushed version for pyload-ng tag latest"
|
FAILURE_REASON="Can't retrieve last pushed version for pyload-ng tag develop"
|
||||||
curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://cdn.discordapp.com/avatars/354986384542662657/df91181b3f1cf0ef1592fbe18e0962d7.png","embeds": [{"color": 16711680,
|
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"}],
|
||||||
"username": "Github Actions"}' ${{ secrets.DISCORD_WEBHOOK }}
|
"username": "Github Actions"}' ${{ secrets.DISCORD_WEBHOOK }}
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
echo "**** Last pushed version: ${IMAGE_VERSION} ****"
|
echo "**** Last pushed version: ${IMAGE_VERSION} ****"
|
||||||
|
echo "Last pushed version: ${IMAGE_VERSION}" >> $GITHUB_STEP_SUMMARY
|
||||||
if [ "${EXT_RELEASE}" == "${IMAGE_VERSION}" ]; then
|
if [ "${EXT_RELEASE}" == "${IMAGE_VERSION}" ]; then
|
||||||
echo "**** Version ${EXT_RELEASE} already pushed, exiting ****"
|
echo "**** Version ${EXT_RELEASE} already pushed, exiting ****"
|
||||||
|
echo "Version ${EXT_RELEASE} already pushed, exiting" >> $GITHUB_STEP_SUMMARY
|
||||||
exit 0
|
exit 0
|
||||||
elif [ $(curl -s https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-pyload-ng/job/main/lastBuild/api/json | jq -r '.building') == "true" ]; then
|
elif [ $(curl -s https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-pyload-ng/job/develop/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 ****"
|
||||||
|
echo "New version ${EXT_RELEASE} found; but there already seems to be an active build on Jenkins; exiting" >> $GITHUB_STEP_SUMMARY
|
||||||
exit 0
|
exit 0
|
||||||
else
|
else
|
||||||
echo "**** New version ${EXT_RELEASE} found; old version was ${IMAGE_VERSION}. Triggering new build ****"
|
echo "**** New version ${EXT_RELEASE} found; old version was ${IMAGE_VERSION}. Triggering new build ****"
|
||||||
|
echo "New version ${EXT_RELEASE} found; old version was ${IMAGE_VERSION}. Triggering new build" >> $GITHUB_STEP_SUMMARY
|
||||||
response=$(curl -iX POST \
|
response=$(curl -iX POST \
|
||||||
https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-pyload-ng/job/main/buildWithParameters?PACKAGE_CHECK=false \
|
https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-pyload-ng/job/develop/buildWithParameters?PACKAGE_CHECK=false \
|
||||||
--user ${{ secrets.JENKINS_USER }}:${{ secrets.JENKINS_TOKEN }} | grep -i location | sed "s|^[L|l]ocation: \(.*\)|\1|")
|
--user ${{ secrets.JENKINS_USER }}:${{ secrets.JENKINS_TOKEN }} | grep -i location | sed "s|^[L|l]ocation: \(.*\)|\1|")
|
||||||
echo "**** Jenkins job queue url: ${response%$'\r'} ****"
|
echo "**** Jenkins job queue url: ${response%$'\r'} ****"
|
||||||
echo "**** Sleeping 10 seconds until job starts ****"
|
echo "**** Sleeping 10 seconds until job starts ****"
|
||||||
@ -78,6 +89,7 @@ jobs:
|
|||||||
buildurl=$(curl -s "${response%$'\r'}api/json" | jq -r '.executable.url')
|
buildurl=$(curl -s "${response%$'\r'}api/json" | jq -r '.executable.url')
|
||||||
buildurl="${buildurl%$'\r'}"
|
buildurl="${buildurl%$'\r'}"
|
||||||
echo "**** Jenkins job build url: ${buildurl} ****"
|
echo "**** Jenkins job build url: ${buildurl} ****"
|
||||||
|
echo "Jenkins job build url: ${buildurl}" >> $GITHUB_STEP_SUMMARY
|
||||||
echo "**** Attempting to change the Jenkins job description ****"
|
echo "**** Attempting to change the Jenkins job description ****"
|
||||||
curl -iX POST \
|
curl -iX POST \
|
||||||
"${buildurl}submitDescription" \
|
"${buildurl}submitDescription" \
|
||||||
@ -85,7 +97,7 @@ jobs:
|
|||||||
--data-urlencode "description=GHA external trigger https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" \
|
--data-urlencode "description=GHA external trigger https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" \
|
||||||
--data-urlencode "Submit=Submit"
|
--data-urlencode "Submit=Submit"
|
||||||
echo "**** Notifying Discord ****"
|
echo "**** Notifying Discord ****"
|
||||||
TRIGGER_REASON="A version change was detected for pyload-ng tag latest. Old version:${IMAGE_VERSION} New version:${EXT_RELEASE}"
|
TRIGGER_REASON="A version change was detected for pyload-ng tag develop. 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,
|
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"}],
|
"description": "**Build Triggered** \n**Reason:** '"${TRIGGER_REASON}"' \n**Build URL:** '"${buildurl}display/redirect"' \n"}],
|
||||||
"username": "Github Actions"}' ${{ secrets.DISCORD_WEBHOOK }}
|
"username": "Github Actions"}' ${{ secrets.DISCORD_WEBHOOK }}
|
||||||
|
|||||||
20
.github/workflows/external_trigger_scheduler.yml
vendored
20
.github/workflows/external_trigger_scheduler.yml
vendored
@ -2,14 +2,14 @@ name: External Trigger Scheduler
|
|||||||
|
|
||||||
on:
|
on:
|
||||||
schedule:
|
schedule:
|
||||||
- cron: '54 * * * *'
|
- cron: '59 * * * *'
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
external-trigger-scheduler:
|
external-trigger-scheduler:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2.3.3
|
- uses: actions/checkout@v3.1.0
|
||||||
with:
|
with:
|
||||||
fetch-depth: '0'
|
fetch-depth: '0'
|
||||||
|
|
||||||
@ -17,18 +17,18 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
echo "**** Branches found: ****"
|
echo "**** Branches found: ****"
|
||||||
git for-each-ref --format='%(refname:short)' refs/remotes
|
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)
|
for br in $(git for-each-ref --format='%(refname:short)' refs/remotes)
|
||||||
do
|
do
|
||||||
br=$(echo "$br" | sed 's|origin/||g')
|
br=$(echo "$br" | sed 's|origin/||g')
|
||||||
echo "**** Evaluating branch ${br} ****"
|
echo "**** Evaluating branch ${br} ****"
|
||||||
ls_branch=$(curl -sX GET https://raw.githubusercontent.com/linuxserver/docker-pyload-ng/${br}/jenkins-vars.yml \
|
ls_jenkins_vars=$(curl -sX GET https://raw.githubusercontent.com/linuxserver/docker-pyload-ng/${br}/jenkins-vars.yml)
|
||||||
| docker run --rm -i --entrypoint yq ghcr.io/linuxserver/yq -r .ls_branch)
|
ls_branch=$(echo "${ls_jenkins_vars}" | yq -r '.ls_branch')
|
||||||
if [ "$br" == "$ls_branch" ]; then
|
ls_trigger=$(echo "${ls_jenkins_vars}" | yq -r '.external_type')
|
||||||
echo "**** Branch ${br} appears to be live; checking workflow. ****"
|
if [[ "${br}" == "${ls_branch}" ]] && [[ "${ls_trigger}" != "os" ]]; then
|
||||||
|
echo "**** Branch ${br} appears to be live and trigger is not os; checking workflow. ****"
|
||||||
if curl -sfX GET https://raw.githubusercontent.com/linuxserver/docker-pyload-ng/${br}/.github/workflows/external_trigger.yml > /dev/null 2>&1; then
|
if curl -sfX GET https://raw.githubusercontent.com/linuxserver/docker-pyload-ng/${br}/.github/workflows/external_trigger.yml > /dev/null 2>&1; then
|
||||||
echo "**** Workflow exists. Triggering external trigger workflow for branch ${br} ****."
|
echo "**** Workflow exists. Triggering external trigger workflow for branch ${br} ****."
|
||||||
|
echo "Triggering external trigger workflow for branch ${br}" >> $GITHUB_STEP_SUMMARY
|
||||||
curl -iX POST \
|
curl -iX POST \
|
||||||
-H "Authorization: token ${{ secrets.CR_PAT }}" \
|
-H "Authorization: token ${{ secrets.CR_PAT }}" \
|
||||||
-H "Accept: application/vnd.github.v3+json" \
|
-H "Accept: application/vnd.github.v3+json" \
|
||||||
@ -36,8 +36,10 @@ jobs:
|
|||||||
https://api.github.com/repos/linuxserver/docker-pyload-ng/actions/workflows/external_trigger.yml/dispatches
|
https://api.github.com/repos/linuxserver/docker-pyload-ng/actions/workflows/external_trigger.yml/dispatches
|
||||||
else
|
else
|
||||||
echo "**** Workflow doesn't exist; skipping trigger. ****"
|
echo "**** Workflow doesn't exist; skipping trigger. ****"
|
||||||
|
echo "Skipping branch ${br} due to no external trigger workflow present." >> $GITHUB_STEP_SUMMARY
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
echo "**** ${br} appears to be a dev branch; skipping trigger. ****"
|
echo "**** ${br} is either a dev branch, or has no external version; skipping trigger. ****"
|
||||||
|
echo "Skipping branch ${br} due to being detected as dev branch or having no external version." >> $GITHUB_STEP_SUMMARY
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|||||||
4
.github/workflows/greetings.yml
vendored
4
.github/workflows/greetings.yml
vendored
@ -8,6 +8,6 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- uses: actions/first-interaction@v1
|
- uses: actions/first-interaction@v1
|
||||||
with:
|
with:
|
||||||
issue-message: 'Thanks for opening your first issue here! Be sure to follow the [bug](https://github.com/linuxserver/docker-pyload-ng/blob/main/.github/ISSUE_TEMPLATE/issue.bug.md) or [feature](https://github.com/linuxserver/docker-pyload-ng/blob/main/.github/ISSUE_TEMPLATE/issue.feature.md) issue templates!'
|
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-pyload-ng/blob/main/.github/PULL_REQUEST_TEMPLATE.md)!'
|
pr-message: 'Thanks for opening this pull request! Be sure to follow the [pull request template](https://github.com/linuxserver/docker-pyload-ng/blob/develop/.github/PULL_REQUEST_TEMPLATE.md)!'
|
||||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|||||||
20
.github/workflows/package_trigger.yml
vendored
20
.github/workflows/package_trigger.yml
vendored
@ -4,25 +4,28 @@ on:
|
|||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
package-trigger-main:
|
package-trigger-develop:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2.3.3
|
- uses: actions/checkout@v3.1.0
|
||||||
|
|
||||||
- name: Package Trigger
|
- name: Package Trigger
|
||||||
if: github.ref == 'refs/heads/main'
|
if: github.ref == 'refs/heads/develop'
|
||||||
run: |
|
run: |
|
||||||
if [ -n "${{ secrets.PAUSE_PACKAGE_TRIGGER_PYLOAD_NG_MAIN }}" ]; then
|
if [ -n "${{ secrets.PAUSE_PACKAGE_TRIGGER_PYLOAD_NG_DEVELOP }}" ]; then
|
||||||
echo "**** Github secret PAUSE_PACKAGE_TRIGGER_PYLOAD_NG_MAIN is set; skipping trigger. ****"
|
echo "**** Github secret PAUSE_PACKAGE_TRIGGER_PYLOAD_NG_DEVELOP is set; skipping trigger. ****"
|
||||||
|
echo "Github secret \`PAUSE_PACKAGE_TRIGGER_PYLOAD_NG_DEVELOP\` is set; skipping trigger." >> $GITHUB_STEP_SUMMARY
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
fi
|
||||||
if [ $(curl -s https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-pyload-ng/job/main/lastBuild/api/json | jq -r '.building') == "true" ]; then
|
if [ $(curl -s https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-pyload-ng/job/develop/lastBuild/api/json | jq -r '.building') == "true" ]; then
|
||||||
echo "**** There already seems to be an active build on Jenkins; skipping package trigger ****"
|
echo "**** There already seems to be an active build on Jenkins; skipping package trigger ****"
|
||||||
|
echo "There already seems to be an active build on Jenkins; skipping package trigger" >> $GITHUB_STEP_SUMMARY
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
fi
|
||||||
echo "**** Package trigger running off of main branch. To disable, set a Github secret named \"PAUSE_PACKAGE_TRIGGER_PYLOAD_NG_MAIN\". ****"
|
echo "**** Package trigger running off of develop branch. To disable, set a Github secret named \"PAUSE_PACKAGE_TRIGGER_PYLOAD_NG_DEVELOP\". ****"
|
||||||
|
echo "Package trigger running off of develop branch. To disable, set a Github secret named \`PAUSE_PACKAGE_TRIGGER_PYLOAD_NG_DEVELOP\`" >> $GITHUB_STEP_SUMMARY
|
||||||
response=$(curl -iX POST \
|
response=$(curl -iX POST \
|
||||||
https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-pyload-ng/job/main/buildWithParameters?PACKAGE_CHECK=true \
|
https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-pyload-ng/job/develop/buildWithParameters?PACKAGE_CHECK=true \
|
||||||
--user ${{ secrets.JENKINS_USER }}:${{ secrets.JENKINS_TOKEN }} | grep -i location | sed "s|^[L|l]ocation: \(.*\)|\1|")
|
--user ${{ secrets.JENKINS_USER }}:${{ secrets.JENKINS_TOKEN }} | grep -i location | sed "s|^[L|l]ocation: \(.*\)|\1|")
|
||||||
echo "**** Jenkins job queue url: ${response%$'\r'} ****"
|
echo "**** Jenkins job queue url: ${response%$'\r'} ****"
|
||||||
echo "**** Sleeping 10 seconds until job starts ****"
|
echo "**** Sleeping 10 seconds until job starts ****"
|
||||||
@ -30,6 +33,7 @@ jobs:
|
|||||||
buildurl=$(curl -s "${response%$'\r'}api/json" | jq -r '.executable.url')
|
buildurl=$(curl -s "${response%$'\r'}api/json" | jq -r '.executable.url')
|
||||||
buildurl="${buildurl%$'\r'}"
|
buildurl="${buildurl%$'\r'}"
|
||||||
echo "**** Jenkins job build url: ${buildurl} ****"
|
echo "**** Jenkins job build url: ${buildurl} ****"
|
||||||
|
echo "Jenkins job build url: ${buildurl}" >> $GITHUB_STEP_SUMMARY
|
||||||
echo "**** Attempting to change the Jenkins job description ****"
|
echo "**** Attempting to change the Jenkins job description ****"
|
||||||
curl -iX POST \
|
curl -iX POST \
|
||||||
"${buildurl}submitDescription" \
|
"${buildurl}submitDescription" \
|
||||||
|
|||||||
12
.github/workflows/package_trigger_scheduler.yml
vendored
12
.github/workflows/package_trigger_scheduler.yml
vendored
@ -2,14 +2,14 @@ name: Package Trigger Scheduler
|
|||||||
|
|
||||||
on:
|
on:
|
||||||
schedule:
|
schedule:
|
||||||
- cron: '44 14 * * 2'
|
- cron: '9 19 * * 5'
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
package-trigger-scheduler:
|
package-trigger-scheduler:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2.3.3
|
- uses: actions/checkout@v3.1.0
|
||||||
with:
|
with:
|
||||||
fetch-depth: '0'
|
fetch-depth: '0'
|
||||||
|
|
||||||
@ -17,18 +17,16 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
echo "**** Branches found: ****"
|
echo "**** Branches found: ****"
|
||||||
git for-each-ref --format='%(refname:short)' refs/remotes
|
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)
|
for br in $(git for-each-ref --format='%(refname:short)' refs/remotes)
|
||||||
do
|
do
|
||||||
br=$(echo "$br" | sed 's|origin/||g')
|
br=$(echo "$br" | sed 's|origin/||g')
|
||||||
echo "**** Evaluating branch ${br} ****"
|
echo "**** Evaluating branch ${br} ****"
|
||||||
ls_branch=$(curl -sX GET https://raw.githubusercontent.com/linuxserver/docker-pyload-ng/${br}/jenkins-vars.yml \
|
ls_branch=$(curl -sX GET https://raw.githubusercontent.com/linuxserver/docker-pyload-ng/${br}/jenkins-vars.yml | yq -r '.ls_branch')
|
||||||
| docker run --rm -i --entrypoint yq ghcr.io/linuxserver/yq -r .ls_branch)
|
|
||||||
if [ "${br}" == "${ls_branch}" ]; then
|
if [ "${br}" == "${ls_branch}" ]; then
|
||||||
echo "**** Branch ${br} appears to be live; checking workflow. ****"
|
echo "**** Branch ${br} appears to be live; checking workflow. ****"
|
||||||
if curl -sfX GET https://raw.githubusercontent.com/linuxserver/docker-pyload-ng/${br}/.github/workflows/package_trigger.yml > /dev/null 2>&1; then
|
if curl -sfX GET https://raw.githubusercontent.com/linuxserver/docker-pyload-ng/${br}/.github/workflows/package_trigger.yml > /dev/null 2>&1; then
|
||||||
echo "**** Workflow exists. Triggering package trigger workflow for branch ${br}. ****"
|
echo "**** Workflow exists. Triggering package trigger workflow for branch ${br}. ****"
|
||||||
|
echo "Triggering package trigger workflow for branch ${br}" >> $GITHUB_STEP_SUMMARY
|
||||||
triggered_branches="${triggered_branches}${br} "
|
triggered_branches="${triggered_branches}${br} "
|
||||||
curl -iX POST \
|
curl -iX POST \
|
||||||
-H "Authorization: token ${{ secrets.CR_PAT }}" \
|
-H "Authorization: token ${{ secrets.CR_PAT }}" \
|
||||||
@ -38,9 +36,11 @@ jobs:
|
|||||||
sleep 30
|
sleep 30
|
||||||
else
|
else
|
||||||
echo "**** Workflow doesn't exist; skipping trigger. ****"
|
echo "**** Workflow doesn't exist; skipping trigger. ****"
|
||||||
|
echo "Skipping branch ${br} due to no package trigger workflow present." >> $GITHUB_STEP_SUMMARY
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
echo "**** ${br} appears to be a dev branch; skipping trigger. ****"
|
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
|
fi
|
||||||
done
|
done
|
||||||
echo "**** Package check build(s) triggered for branch(es): ${triggered_branches} ****"
|
echo "**** Package check build(s) triggered for branch(es): ${triggered_branches} ****"
|
||||||
|
|||||||
10
.github/workflows/permissions.yml
vendored
Executable file
10
.github/workflows/permissions.yml
vendored
Executable file
@ -0,0 +1,10 @@
|
|||||||
|
name: Permission check
|
||||||
|
on:
|
||||||
|
pull_request_target:
|
||||||
|
paths:
|
||||||
|
- '**/run'
|
||||||
|
- '**/finish'
|
||||||
|
- '**/check'
|
||||||
|
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@v3
|
|
||||||
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 }}
|
|
||||||
42
Dockerfile
42
Dockerfile
@ -1,9 +1,12 @@
|
|||||||
FROM ghcr.io/linuxserver/baseimage-alpine:3.15
|
# syntax=docker/dockerfile:1
|
||||||
|
|
||||||
|
FROM ghcr.io/linuxserver/baseimage-alpine:3.18
|
||||||
|
|
||||||
# set version label
|
# set version label
|
||||||
|
ARG UNRAR_VERSION=6.2.10
|
||||||
ARG BUILD_DATE
|
ARG BUILD_DATE
|
||||||
ARG VERSION
|
ARG VERSION
|
||||||
ARG PYLOAD_VERSION
|
ARG PYLOAD_COMMIT
|
||||||
LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DATE}"
|
LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DATE}"
|
||||||
LABEL maintainer="aptalca"
|
LABEL maintainer="aptalca"
|
||||||
|
|
||||||
@ -15,6 +18,7 @@ RUN \
|
|||||||
build-base \
|
build-base \
|
||||||
cargo \
|
cargo \
|
||||||
curl-dev \
|
curl-dev \
|
||||||
|
git \
|
||||||
libffi-dev \
|
libffi-dev \
|
||||||
libjpeg-turbo-dev \
|
libjpeg-turbo-dev \
|
||||||
openssl-dev \
|
openssl-dev \
|
||||||
@ -22,32 +26,34 @@ RUN \
|
|||||||
zlib-dev && \
|
zlib-dev && \
|
||||||
echo "**** install packages ****" && \
|
echo "**** install packages ****" && \
|
||||||
apk add --no-cache \
|
apk add --no-cache \
|
||||||
curl \
|
ffmpeg \
|
||||||
libjpeg-turbo \
|
libjpeg-turbo \
|
||||||
py3-pip \
|
7zip \
|
||||||
python3 \
|
python3 \
|
||||||
sqlite \
|
sqlite \
|
||||||
tesseract-ocr && \
|
tesseract-ocr && \
|
||||||
echo "**** install unrar ****" && \
|
echo "**** install unrar from source ****" && \
|
||||||
mkdir /tmp/unrar && \
|
mkdir /tmp/unrar && \
|
||||||
curl -o /tmp/unrar.tar.gz \
|
curl -o \
|
||||||
-L "https://www.rarlab.com/rar/unrarsrc-6.1.4.tar.gz" && \
|
/tmp/unrar.tar.gz -L \
|
||||||
tar xf /tmp/unrar.tar.gz -C \
|
"https://www.rarlab.com/rar/unrarsrc-${UNRAR_VERSION}.tar.gz" && \
|
||||||
|
tar xf \
|
||||||
|
/tmp/unrar.tar.gz -C \
|
||||||
/tmp/unrar --strip-components=1 && \
|
/tmp/unrar --strip-components=1 && \
|
||||||
cd /tmp/unrar && \
|
cd /tmp/unrar && \
|
||||||
make && \
|
make && \
|
||||||
make install && \
|
install -v -m755 unrar /usr/local/bin && \
|
||||||
mkdir -p /usr/share/licenses/unrar && \
|
|
||||||
mv license.txt /usr/share/licenses/unrar/ && \
|
|
||||||
echo "**** install pyload ****" && \
|
echo "**** install pyload ****" && \
|
||||||
if [ -z ${PYLOAD_VERSION+x} ]; then \
|
if [ -z ${PYLOAD_COMMIT+x} ]; then \
|
||||||
PYLOAD="pyload-ng[all]"; \
|
PYLOAD_COMMIT=$(curl -sX GET "https://api.github.com/repos/pyload/pyload/branches/develop" \
|
||||||
else \
|
| awk '/sha/{print $4;exit}' FS='[""]'); \
|
||||||
PYLOAD="pyload-ng[all]==${PYLOAD_VERSION}"; \
|
|
||||||
fi && \
|
fi && \
|
||||||
pip3 install -U pip setuptools wheel && \
|
python3 -m venv /lsiopy && \
|
||||||
pip install -U --find-links https://wheel-index.linuxserver.io/alpine-3.15/ \
|
pip install -U --no-cache-dir \
|
||||||
"${PYLOAD}" && \
|
pip \
|
||||||
|
wheel && \
|
||||||
|
pip install -U --no-cache-dir --find-links https://wheel-index.linuxserver.io/alpine-3.18/ \
|
||||||
|
"git+https://github.com/pyload/pyload.git@${PYLOAD_COMMIT}" && \
|
||||||
echo "**** cleanup ****" && \
|
echo "**** cleanup ****" && \
|
||||||
apk del --purge \
|
apk del --purge \
|
||||||
build-dependencies && \
|
build-dependencies && \
|
||||||
|
|||||||
@ -1,9 +1,12 @@
|
|||||||
FROM ghcr.io/linuxserver/baseimage-alpine:arm64v8-3.15
|
# syntax=docker/dockerfile:1
|
||||||
|
|
||||||
|
FROM ghcr.io/linuxserver/baseimage-alpine:arm64v8-3.18
|
||||||
|
|
||||||
# set version label
|
# set version label
|
||||||
|
ARG UNRAR_VERSION=6.2.10
|
||||||
ARG BUILD_DATE
|
ARG BUILD_DATE
|
||||||
ARG VERSION
|
ARG VERSION
|
||||||
ARG PYLOAD_VERSION
|
ARG PYLOAD_COMMIT
|
||||||
LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DATE}"
|
LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DATE}"
|
||||||
LABEL maintainer="aptalca"
|
LABEL maintainer="aptalca"
|
||||||
|
|
||||||
@ -15,6 +18,7 @@ RUN \
|
|||||||
build-base \
|
build-base \
|
||||||
cargo \
|
cargo \
|
||||||
curl-dev \
|
curl-dev \
|
||||||
|
git \
|
||||||
libffi-dev \
|
libffi-dev \
|
||||||
libjpeg-turbo-dev \
|
libjpeg-turbo-dev \
|
||||||
openssl-dev \
|
openssl-dev \
|
||||||
@ -22,32 +26,34 @@ RUN \
|
|||||||
zlib-dev && \
|
zlib-dev && \
|
||||||
echo "**** install packages ****" && \
|
echo "**** install packages ****" && \
|
||||||
apk add --no-cache \
|
apk add --no-cache \
|
||||||
curl \
|
ffmpeg \
|
||||||
libjpeg-turbo \
|
libjpeg-turbo \
|
||||||
py3-pip \
|
7zip \
|
||||||
python3 \
|
python3 \
|
||||||
sqlite \
|
sqlite \
|
||||||
tesseract-ocr && \
|
tesseract-ocr && \
|
||||||
echo "**** install unrar ****" && \
|
echo "**** install unrar from source ****" && \
|
||||||
mkdir /tmp/unrar && \
|
mkdir /tmp/unrar && \
|
||||||
curl -o /tmp/unrar.tar.gz \
|
curl -o \
|
||||||
-L "https://www.rarlab.com/rar/unrarsrc-6.1.4.tar.gz" && \
|
/tmp/unrar.tar.gz -L \
|
||||||
tar xf /tmp/unrar.tar.gz -C \
|
"https://www.rarlab.com/rar/unrarsrc-${UNRAR_VERSION}.tar.gz" && \
|
||||||
|
tar xf \
|
||||||
|
/tmp/unrar.tar.gz -C \
|
||||||
/tmp/unrar --strip-components=1 && \
|
/tmp/unrar --strip-components=1 && \
|
||||||
cd /tmp/unrar && \
|
cd /tmp/unrar && \
|
||||||
make && \
|
make && \
|
||||||
make install && \
|
install -v -m755 unrar /usr/local/bin && \
|
||||||
mkdir -p /usr/share/licenses/unrar && \
|
|
||||||
mv license.txt /usr/share/licenses/unrar/ && \
|
|
||||||
echo "**** install pyload ****" && \
|
echo "**** install pyload ****" && \
|
||||||
if [ -z ${PYLOAD_VERSION+x} ]; then \
|
if [ -z ${PYLOAD_COMMIT+x} ]; then \
|
||||||
PYLOAD="pyload-ng[all]"; \
|
PYLOAD_COMMIT=$(curl -sX GET "https://api.github.com/repos/pyload/pyload/branches/develop" \
|
||||||
else \
|
| awk '/sha/{print $4;exit}' FS='[""]'); \
|
||||||
PYLOAD="pyload-ng[all]==${PYLOAD_VERSION}"; \
|
|
||||||
fi && \
|
fi && \
|
||||||
pip3 install -U pip setuptools wheel && \
|
python3 -m venv /lsiopy && \
|
||||||
pip install -U --find-links https://wheel-index.linuxserver.io/alpine-3.15/ \
|
pip install -U --no-cache-dir \
|
||||||
"${PYLOAD}" && \
|
pip \
|
||||||
|
wheel && \
|
||||||
|
pip install -U --no-cache-dir --find-links https://wheel-index.linuxserver.io/alpine-3.18/ \
|
||||||
|
"git+https://github.com/pyload/pyload.git@${PYLOAD_COMMIT}" && \
|
||||||
echo "**** cleanup ****" && \
|
echo "**** cleanup ****" && \
|
||||||
apk del --purge \
|
apk del --purge \
|
||||||
build-dependencies && \
|
build-dependencies && \
|
||||||
|
|||||||
@ -1,64 +0,0 @@
|
|||||||
FROM ghcr.io/linuxserver/baseimage-alpine:arm32v7-3.15
|
|
||||||
|
|
||||||
# set version label
|
|
||||||
ARG BUILD_DATE
|
|
||||||
ARG VERSION
|
|
||||||
ARG PYLOAD_VERSION
|
|
||||||
LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DATE}"
|
|
||||||
LABEL maintainer="aptalca"
|
|
||||||
|
|
||||||
ENV HOME="/config"
|
|
||||||
|
|
||||||
RUN \
|
|
||||||
echo "**** install build packages ****" && \
|
|
||||||
apk add --no-cache --virtual=build-dependencies \
|
|
||||||
build-base \
|
|
||||||
cargo \
|
|
||||||
curl-dev \
|
|
||||||
libffi-dev \
|
|
||||||
libjpeg-turbo-dev \
|
|
||||||
openssl-dev \
|
|
||||||
python3-dev \
|
|
||||||
zlib-dev && \
|
|
||||||
echo "**** install packages ****" && \
|
|
||||||
apk add --no-cache \
|
|
||||||
curl \
|
|
||||||
libjpeg-turbo \
|
|
||||||
py3-pip \
|
|
||||||
python3 \
|
|
||||||
sqlite \
|
|
||||||
tesseract-ocr && \
|
|
||||||
echo "**** install unrar ****" && \
|
|
||||||
mkdir /tmp/unrar && \
|
|
||||||
curl -o /tmp/unrar.tar.gz \
|
|
||||||
-L "https://www.rarlab.com/rar/unrarsrc-6.1.4.tar.gz" && \
|
|
||||||
tar xf /tmp/unrar.tar.gz -C \
|
|
||||||
/tmp/unrar --strip-components=1 && \
|
|
||||||
cd /tmp/unrar && \
|
|
||||||
make && \
|
|
||||||
make install && \
|
|
||||||
mkdir -p /usr/share/licenses/unrar && \
|
|
||||||
mv license.txt /usr/share/licenses/unrar/ && \
|
|
||||||
echo "**** install pyload ****" && \
|
|
||||||
if [ -z ${PYLOAD_VERSION+x} ]; then \
|
|
||||||
PYLOAD="pyload-ng[all]"; \
|
|
||||||
else \
|
|
||||||
PYLOAD="pyload-ng[all]==${PYLOAD_VERSION}"; \
|
|
||||||
fi && \
|
|
||||||
pip3 install -U pip setuptools wheel && \
|
|
||||||
pip install -U --find-links https://wheel-index.linuxserver.io/alpine-3.15/ \
|
|
||||||
"${PYLOAD}" && \
|
|
||||||
echo "**** cleanup ****" && \
|
|
||||||
apk del --purge \
|
|
||||||
build-dependencies && \
|
|
||||||
rm -rf \
|
|
||||||
/tmp/* \
|
|
||||||
${HOME}/.cache \
|
|
||||||
${HOME}/.cargo
|
|
||||||
|
|
||||||
# add local files
|
|
||||||
COPY root/ /
|
|
||||||
|
|
||||||
# ports and volumes
|
|
||||||
EXPOSE 8000
|
|
||||||
VOLUME /config
|
|
||||||
460
Jenkinsfile
vendored
460
Jenkinsfile
vendored
@ -17,14 +17,16 @@ pipeline {
|
|||||||
GITLAB_TOKEN=credentials('b6f0f1dd-6952-4cf6-95d1-9c06380283f0')
|
GITLAB_TOKEN=credentials('b6f0f1dd-6952-4cf6-95d1-9c06380283f0')
|
||||||
GITLAB_NAMESPACE=credentials('gitlab-namespace-id')
|
GITLAB_NAMESPACE=credentials('gitlab-namespace-id')
|
||||||
SCARF_TOKEN=credentials('scarf_api_key')
|
SCARF_TOKEN=credentials('scarf_api_key')
|
||||||
EXT_PIP = 'pyload-ng'
|
EXT_GIT_BRANCH = 'develop'
|
||||||
BUILD_VERSION_ARG = 'PYLOAD_VERSION'
|
EXT_USER = 'pyload'
|
||||||
|
EXT_REPO = 'pyload'
|
||||||
|
BUILD_VERSION_ARG = 'PYLOAD_COMMIT'
|
||||||
LS_USER = 'linuxserver'
|
LS_USER = 'linuxserver'
|
||||||
LS_REPO = 'docker-pyload'
|
LS_REPO = 'docker-pyload-ng'
|
||||||
CONTAINER_NAME = 'pyload'
|
CONTAINER_NAME = 'pyload-ng'
|
||||||
DOCKERHUB_IMAGE = 'linuxserver/pyload'
|
DOCKERHUB_IMAGE = 'linuxserver/pyload-ng'
|
||||||
DEV_DOCKERHUB_IMAGE = 'lsiodev/pyload'
|
DEV_DOCKERHUB_IMAGE = 'lsiodev/pyload-ng'
|
||||||
PR_DOCKERHUB_IMAGE = 'lspipepr/pyload'
|
PR_DOCKERHUB_IMAGE = 'lspipepr/pyload-ng'
|
||||||
DIST_IMAGE = 'alpine'
|
DIST_IMAGE = 'alpine'
|
||||||
MULTIARCH='true'
|
MULTIARCH='true'
|
||||||
CI='true'
|
CI='true'
|
||||||
@ -40,10 +42,16 @@ pipeline {
|
|||||||
// Setup all the basic environment variables needed for the build
|
// Setup all the basic environment variables needed for the build
|
||||||
stage("Set ENV Variables base"){
|
stage("Set ENV Variables base"){
|
||||||
steps{
|
steps{
|
||||||
|
sh '''#! /bin/bash
|
||||||
|
containers=$(docker ps -aq)
|
||||||
|
if [[ -n "${containers}" ]]; then
|
||||||
|
docker stop ${containers}
|
||||||
|
fi
|
||||||
|
docker system prune -af --volumes || : '''
|
||||||
script{
|
script{
|
||||||
env.EXIT_STATUS = ''
|
env.EXIT_STATUS = ''
|
||||||
env.LS_RELEASE = sh(
|
env.LS_RELEASE = sh(
|
||||||
script: '''docker run --rm ghcr.io/linuxserver/alexeiled-skopeo sh -c 'skopeo inspect docker://docker.io/'${DOCKERHUB_IMAGE}':latest 2>/dev/null' | jq -r '.Labels.build_version' | awk '{print $3}' | grep '\\-ls' || : ''',
|
script: '''docker run --rm quay.io/skopeo/stable:v1 inspect docker://ghcr.io/${LS_USER}/${CONTAINER_NAME}:develop 2>/dev/null | jq -r '.Labels.build_version' | awk '{print $3}' | grep '\\-ls' || : ''',
|
||||||
returnStdout: true).trim()
|
returnStdout: true).trim()
|
||||||
env.LS_RELEASE_NOTES = sh(
|
env.LS_RELEASE_NOTES = sh(
|
||||||
script: '''cat readme-vars.yml | awk -F \\" '/date: "[0-9][0-9].[0-9][0-9].[0-9][0-9]:/ {print $4;exit;}' | sed -E ':a;N;$!ba;s/\\r{0,1}\\n/\\\\n/g' ''',
|
script: '''cat readme-vars.yml | awk -F \\" '/date: "[0-9][0-9].[0-9][0-9].[0-9][0-9]:/ {print $4;exit;}' | sed -E ':a;N;$!ba;s/\\r{0,1}\\n/\\\\n/g' ''',
|
||||||
@ -57,7 +65,7 @@ pipeline {
|
|||||||
env.CODE_URL = 'https://github.com/' + env.LS_USER + '/' + env.LS_REPO + '/commit/' + env.GIT_COMMIT
|
env.CODE_URL = 'https://github.com/' + env.LS_USER + '/' + env.LS_REPO + '/commit/' + env.GIT_COMMIT
|
||||||
env.DOCKERHUB_LINK = 'https://hub.docker.com/r/' + env.DOCKERHUB_IMAGE + '/tags/'
|
env.DOCKERHUB_LINK = 'https://hub.docker.com/r/' + env.DOCKERHUB_IMAGE + '/tags/'
|
||||||
env.PULL_REQUEST = env.CHANGE_ID
|
env.PULL_REQUEST = env.CHANGE_ID
|
||||||
env.TEMPLATED_FILES = 'Jenkinsfile README.md LICENSE .editorconfig ./.github/CONTRIBUTING.md ./.github/FUNDING.yml ./.github/ISSUE_TEMPLATE/config.yml ./.github/ISSUE_TEMPLATE/issue.bug.md ./.github/ISSUE_TEMPLATE/issue.feature.md ./.github/PULL_REQUEST_TEMPLATE.md ./.github/workflows/external_trigger_scheduler.yml ./.github/workflows/greetings.yml ./.github/workflows/package_trigger_scheduler.yml ./.github/workflows/stale.yml ./.github/workflows/external_trigger.yml ./.github/workflows/package_trigger.yml'
|
env.TEMPLATED_FILES = 'Jenkinsfile README.md LICENSE .editorconfig ./.github/CONTRIBUTING.md ./.github/FUNDING.yml ./.github/ISSUE_TEMPLATE/config.yml ./.github/ISSUE_TEMPLATE/issue.bug.yml ./.github/ISSUE_TEMPLATE/issue.feature.yml ./.github/PULL_REQUEST_TEMPLATE.md ./.github/workflows/external_trigger_scheduler.yml ./.github/workflows/greetings.yml ./.github/workflows/package_trigger_scheduler.yml ./.github/workflows/call_issue_pr_tracker.yml ./.github/workflows/call_issues_cron.yml ./.github/workflows/permissions.yml ./.github/workflows/external_trigger.yml ./.github/workflows/package_trigger.yml ./root/donate.txt'
|
||||||
}
|
}
|
||||||
script{
|
script{
|
||||||
env.LS_RELEASE_NUMBER = sh(
|
env.LS_RELEASE_NUMBER = sh(
|
||||||
@ -67,7 +75,7 @@ pipeline {
|
|||||||
script{
|
script{
|
||||||
env.LS_TAG_NUMBER = sh(
|
env.LS_TAG_NUMBER = sh(
|
||||||
script: '''#! /bin/bash
|
script: '''#! /bin/bash
|
||||||
tagsha=$(git rev-list -n 1 ${LS_RELEASE} 2>/dev/null)
|
tagsha=$(git rev-list -n 1 develop-${LS_RELEASE} 2>/dev/null)
|
||||||
if [ "${tagsha}" == "${COMMIT_SHA}" ]; then
|
if [ "${tagsha}" == "${COMMIT_SHA}" ]; then
|
||||||
echo ${LS_RELEASE_NUMBER}
|
echo ${LS_RELEASE_NUMBER}
|
||||||
elif [ -z "${GIT_COMMIT}" ]; then
|
elif [ -z "${GIT_COMMIT}" ]; then
|
||||||
@ -100,17 +108,25 @@ pipeline {
|
|||||||
/* ########################
|
/* ########################
|
||||||
External Release Tagging
|
External Release Tagging
|
||||||
######################## */
|
######################## */
|
||||||
// If this is a pip release set the external tag to the pip version
|
// If this is a github commit trigger determine the current commit at head
|
||||||
stage("Set ENV pip_version"){
|
stage("Set ENV github_commit"){
|
||||||
steps{
|
steps{
|
||||||
script{
|
script{
|
||||||
env.EXT_RELEASE = sh(
|
env.EXT_RELEASE = sh(
|
||||||
script: '''curl -sL https://pypi.python.org/pypi/${EXT_PIP}/json |jq -r '. | .info.version' ''',
|
script: '''curl -H "Authorization: token ${GITHUB_TOKEN}" -s https://api.github.com/repos/${EXT_USER}/${EXT_REPO}/commits/${EXT_GIT_BRANCH} | jq -r '. | .sha' | cut -c1-8 ''',
|
||||||
returnStdout: true).trim()
|
returnStdout: true).trim()
|
||||||
env.RELEASE_LINK = 'https://pypi.python.org/pypi/' + env.EXT_PIP
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} // Sanitize the release tag and strip illegal docker or github characters
|
// If this is a github commit trigger Set the external release link
|
||||||
|
stage("Set ENV commit_link"){
|
||||||
|
steps{
|
||||||
|
script{
|
||||||
|
env.RELEASE_LINK = 'https://github.com/' + env.EXT_USER + '/' + env.EXT_REPO + '/commit/' + env.EXT_RELEASE
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// Sanitize the release tag and strip illegal docker or github characters
|
||||||
stage("Sanitize tag"){
|
stage("Sanitize tag"){
|
||||||
steps{
|
steps{
|
||||||
script{
|
script{
|
||||||
@ -144,10 +160,10 @@ pipeline {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// If this is a main build use live docker endpoints
|
// If this is a develop build use live docker endpoints
|
||||||
stage("Set ENV live build"){
|
stage("Set ENV live build"){
|
||||||
when {
|
when {
|
||||||
branch "main"
|
branch "develop"
|
||||||
environment name: 'CHANGE_ID', value: ''
|
environment name: 'CHANGE_ID', value: ''
|
||||||
}
|
}
|
||||||
steps {
|
steps {
|
||||||
@ -157,20 +173,20 @@ pipeline {
|
|||||||
env.GITLABIMAGE = 'registry.gitlab.com/linuxserver.io/' + env.LS_REPO + '/' + env.CONTAINER_NAME
|
env.GITLABIMAGE = 'registry.gitlab.com/linuxserver.io/' + env.LS_REPO + '/' + env.CONTAINER_NAME
|
||||||
env.QUAYIMAGE = 'quay.io/linuxserver.io/' + env.CONTAINER_NAME
|
env.QUAYIMAGE = 'quay.io/linuxserver.io/' + env.CONTAINER_NAME
|
||||||
if (env.MULTIARCH == 'true') {
|
if (env.MULTIARCH == 'true') {
|
||||||
env.CI_TAGS = 'amd64-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER + '|arm32v7-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER + '|arm64v8-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER
|
env.CI_TAGS = 'amd64-develop-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER + '|arm64v8-develop-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER
|
||||||
} else {
|
} else {
|
||||||
env.CI_TAGS = env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER
|
env.CI_TAGS = 'develop-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER
|
||||||
}
|
}
|
||||||
env.VERSION_TAG = env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER
|
env.VERSION_TAG = env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER
|
||||||
env.META_TAG = env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER
|
env.META_TAG = 'develop-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER
|
||||||
env.EXT_RELEASE_TAG = 'version-' + env.EXT_RELEASE_CLEAN
|
env.EXT_RELEASE_TAG = 'develop-version-' + env.EXT_RELEASE_CLEAN
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// If this is a dev build use dev docker endpoints
|
// If this is a dev build use dev docker endpoints
|
||||||
stage("Set ENV dev build"){
|
stage("Set ENV dev build"){
|
||||||
when {
|
when {
|
||||||
not {branch "main"}
|
not {branch "develop"}
|
||||||
environment name: 'CHANGE_ID', value: ''
|
environment name: 'CHANGE_ID', value: ''
|
||||||
}
|
}
|
||||||
steps {
|
steps {
|
||||||
@ -180,13 +196,13 @@ pipeline {
|
|||||||
env.GITLABIMAGE = 'registry.gitlab.com/linuxserver.io/' + env.LS_REPO + '/lsiodev-' + env.CONTAINER_NAME
|
env.GITLABIMAGE = 'registry.gitlab.com/linuxserver.io/' + env.LS_REPO + '/lsiodev-' + env.CONTAINER_NAME
|
||||||
env.QUAYIMAGE = 'quay.io/linuxserver.io/lsiodev-' + env.CONTAINER_NAME
|
env.QUAYIMAGE = 'quay.io/linuxserver.io/lsiodev-' + env.CONTAINER_NAME
|
||||||
if (env.MULTIARCH == 'true') {
|
if (env.MULTIARCH == 'true') {
|
||||||
env.CI_TAGS = 'amd64-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA + '|arm32v7-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA + '|arm64v8-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA
|
env.CI_TAGS = 'amd64-develop-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA + '|arm64v8-develop-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA
|
||||||
} else {
|
} else {
|
||||||
env.CI_TAGS = env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA
|
env.CI_TAGS = 'develop-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA
|
||||||
}
|
}
|
||||||
env.VERSION_TAG = env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA
|
env.VERSION_TAG = env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA
|
||||||
env.META_TAG = env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA
|
env.META_TAG = 'develop-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA
|
||||||
env.EXT_RELEASE_TAG = 'version-' + env.EXT_RELEASE_CLEAN
|
env.EXT_RELEASE_TAG = 'develop-version-' + env.EXT_RELEASE_CLEAN
|
||||||
env.DOCKERHUB_LINK = 'https://hub.docker.com/r/' + env.DEV_DOCKERHUB_IMAGE + '/tags/'
|
env.DOCKERHUB_LINK = 'https://hub.docker.com/r/' + env.DEV_DOCKERHUB_IMAGE + '/tags/'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -203,13 +219,13 @@ pipeline {
|
|||||||
env.GITLABIMAGE = 'registry.gitlab.com/linuxserver.io/' + env.LS_REPO + '/lspipepr-' + env.CONTAINER_NAME
|
env.GITLABIMAGE = 'registry.gitlab.com/linuxserver.io/' + env.LS_REPO + '/lspipepr-' + env.CONTAINER_NAME
|
||||||
env.QUAYIMAGE = 'quay.io/linuxserver.io/lspipepr-' + env.CONTAINER_NAME
|
env.QUAYIMAGE = 'quay.io/linuxserver.io/lspipepr-' + env.CONTAINER_NAME
|
||||||
if (env.MULTIARCH == 'true') {
|
if (env.MULTIARCH == 'true') {
|
||||||
env.CI_TAGS = 'amd64-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-pr-' + env.PULL_REQUEST + '|arm32v7-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-pr-' + env.PULL_REQUEST + '|arm64v8-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-pr-' + env.PULL_REQUEST
|
env.CI_TAGS = 'amd64-develop-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA + '-pr-' + env.PULL_REQUEST + '|arm64v8-develop-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA + '-pr-' + env.PULL_REQUEST
|
||||||
} else {
|
} else {
|
||||||
env.CI_TAGS = env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-pr-' + env.PULL_REQUEST
|
env.CI_TAGS = 'develop-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA + '-pr-' + env.PULL_REQUEST
|
||||||
}
|
}
|
||||||
env.VERSION_TAG = env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-pr-' + env.PULL_REQUEST
|
env.VERSION_TAG = env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA + '-pr-' + env.PULL_REQUEST
|
||||||
env.META_TAG = env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-pr-' + env.PULL_REQUEST
|
env.META_TAG = 'develop-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA + '-pr-' + env.PULL_REQUEST
|
||||||
env.EXT_RELEASE_TAG = 'version-' + env.EXT_RELEASE_CLEAN
|
env.EXT_RELEASE_TAG = 'develop-version-' + env.EXT_RELEASE_CLEAN
|
||||||
env.CODE_URL = 'https://github.com/' + env.LS_USER + '/' + env.LS_REPO + '/pull/' + env.PULL_REQUEST
|
env.CODE_URL = 'https://github.com/' + env.LS_USER + '/' + env.LS_REPO + '/pull/' + env.PULL_REQUEST
|
||||||
env.DOCKERHUB_LINK = 'https://hub.docker.com/r/' + env.PR_DOCKERHUB_IMAGE + '/tags/'
|
env.DOCKERHUB_LINK = 'https://hub.docker.com/r/' + env.PR_DOCKERHUB_IMAGE + '/tags/'
|
||||||
}
|
}
|
||||||
@ -228,26 +244,23 @@ pipeline {
|
|||||||
script{
|
script{
|
||||||
env.SHELLCHECK_URL = 'https://ci-tests.linuxserver.io/' + env.IMAGE + '/' + env.META_TAG + '/shellcheck-result.xml'
|
env.SHELLCHECK_URL = 'https://ci-tests.linuxserver.io/' + env.IMAGE + '/' + env.META_TAG + '/shellcheck-result.xml'
|
||||||
}
|
}
|
||||||
sh '''curl -sL https://raw.githubusercontent.com/linuxserver/docker-shellcheck/master/checkrun.sh | /bin/bash'''
|
sh '''curl -sL https://raw.githubusercontent.com/linuxserver/docker-jenkins-builder/master/checkrun.sh | /bin/bash'''
|
||||||
sh '''#! /bin/bash
|
sh '''#! /bin/bash
|
||||||
set -e
|
|
||||||
docker pull ghcr.io/linuxserver/lsiodev-spaces-file-upload:latest
|
|
||||||
docker run --rm \
|
docker run --rm \
|
||||||
-e DESTINATION=\"${IMAGE}/${META_TAG}/shellcheck-result.xml\" \
|
-v ${WORKSPACE}:/mnt \
|
||||||
-e FILE_NAME="shellcheck-result.xml" \
|
-e AWS_ACCESS_KEY_ID=\"${S3_KEY}\" \
|
||||||
-e MIMETYPE="text/xml" \
|
-e AWS_SECRET_ACCESS_KEY=\"${S3_SECRET}\" \
|
||||||
-v ${WORKSPACE}:/mnt \
|
ghcr.io/linuxserver/baseimage-alpine:3.17 s6-envdir -fn -- /var/run/s6/container_environment /bin/bash -c "\
|
||||||
-e SECRET_KEY=\"${S3_SECRET}\" \
|
apk add --no-cache py3-pip && \
|
||||||
-e ACCESS_KEY=\"${S3_KEY}\" \
|
pip install s3cmd && \
|
||||||
-t ghcr.io/linuxserver/lsiodev-spaces-file-upload:latest \
|
s3cmd put --no-preserve --acl-public -m text/xml /mnt/shellcheck-result.xml s3://ci-tests.linuxserver.io/${IMAGE}/${META_TAG}/shellcheck-result.xml" || :'''
|
||||||
python /upload.py'''
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// Use helper containers to render templated files
|
// Use helper containers to render templated files
|
||||||
stage('Update-Templates') {
|
stage('Update-Templates') {
|
||||||
when {
|
when {
|
||||||
branch "main"
|
branch "develop"
|
||||||
environment name: 'CHANGE_ID', value: ''
|
environment name: 'CHANGE_ID', value: ''
|
||||||
expression {
|
expression {
|
||||||
env.CONTAINER_NAME != null
|
env.CONTAINER_NAME != null
|
||||||
@ -258,13 +271,13 @@ pipeline {
|
|||||||
set -e
|
set -e
|
||||||
TEMPDIR=$(mktemp -d)
|
TEMPDIR=$(mktemp -d)
|
||||||
docker pull ghcr.io/linuxserver/jenkins-builder:latest
|
docker pull ghcr.io/linuxserver/jenkins-builder:latest
|
||||||
docker run --rm -e CONTAINER_NAME=${CONTAINER_NAME} -e GITHUB_BRANCH=main -v ${TEMPDIR}:/ansible/jenkins ghcr.io/linuxserver/jenkins-builder:latest
|
docker run --rm -e CONTAINER_NAME=${CONTAINER_NAME} -e GITHUB_BRANCH=develop -v ${TEMPDIR}:/ansible/jenkins ghcr.io/linuxserver/jenkins-builder:latest
|
||||||
# Stage 1 - Jenkinsfile update
|
# Stage 1 - Jenkinsfile update
|
||||||
if [[ "$(md5sum Jenkinsfile | awk '{ print $1 }')" != "$(md5sum ${TEMPDIR}/docker-${CONTAINER_NAME}/Jenkinsfile | awk '{ print $1 }')" ]]; then
|
if [[ "$(md5sum Jenkinsfile | awk '{ print $1 }')" != "$(md5sum ${TEMPDIR}/docker-${CONTAINER_NAME}/Jenkinsfile | awk '{ print $1 }')" ]]; then
|
||||||
mkdir -p ${TEMPDIR}/repo
|
mkdir -p ${TEMPDIR}/repo
|
||||||
git clone https://github.com/${LS_USER}/${LS_REPO}.git ${TEMPDIR}/repo/${LS_REPO}
|
git clone https://github.com/${LS_USER}/${LS_REPO}.git ${TEMPDIR}/repo/${LS_REPO}
|
||||||
cd ${TEMPDIR}/repo/${LS_REPO}
|
cd ${TEMPDIR}/repo/${LS_REPO}
|
||||||
git checkout -f main
|
git checkout -f develop
|
||||||
cp ${TEMPDIR}/docker-${CONTAINER_NAME}/Jenkinsfile ${TEMPDIR}/repo/${LS_REPO}/
|
cp ${TEMPDIR}/docker-${CONTAINER_NAME}/Jenkinsfile ${TEMPDIR}/repo/${LS_REPO}/
|
||||||
git add Jenkinsfile
|
git add Jenkinsfile
|
||||||
git commit -m 'Bot Updating Templated Files'
|
git commit -m 'Bot Updating Templated Files'
|
||||||
@ -277,7 +290,7 @@ pipeline {
|
|||||||
echo "Jenkinsfile is up to date."
|
echo "Jenkinsfile is up to date."
|
||||||
fi
|
fi
|
||||||
# Stage 2 - Delete old templates
|
# Stage 2 - Delete old templates
|
||||||
OLD_TEMPLATES=".github/ISSUE_TEMPLATE.md"
|
OLD_TEMPLATES=".github/ISSUE_TEMPLATE.md .github/ISSUE_TEMPLATE/issue.bug.md .github/ISSUE_TEMPLATE/issue.feature.md .github/workflows/call_invalid_helper.yml .github/workflows/stale.yml Dockerfile.armhf"
|
||||||
for i in ${OLD_TEMPLATES}; do
|
for i in ${OLD_TEMPLATES}; do
|
||||||
if [[ -f "${i}" ]]; then
|
if [[ -f "${i}" ]]; then
|
||||||
TEMPLATES_TO_DELETE="${i} ${TEMPLATES_TO_DELETE}"
|
TEMPLATES_TO_DELETE="${i} ${TEMPLATES_TO_DELETE}"
|
||||||
@ -287,14 +300,14 @@ pipeline {
|
|||||||
mkdir -p ${TEMPDIR}/repo
|
mkdir -p ${TEMPDIR}/repo
|
||||||
git clone https://github.com/${LS_USER}/${LS_REPO}.git ${TEMPDIR}/repo/${LS_REPO}
|
git clone https://github.com/${LS_USER}/${LS_REPO}.git ${TEMPDIR}/repo/${LS_REPO}
|
||||||
cd ${TEMPDIR}/repo/${LS_REPO}
|
cd ${TEMPDIR}/repo/${LS_REPO}
|
||||||
git checkout -f main
|
git checkout -f develop
|
||||||
for i in ${TEMPLATES_TO_DELETE}; do
|
for i in ${TEMPLATES_TO_DELETE}; do
|
||||||
git rm "${i}"
|
git rm "${i}"
|
||||||
done
|
done
|
||||||
git commit -m 'Bot Updating Templated Files'
|
git commit -m 'Bot Updating Templated Files'
|
||||||
git push https://LinuxServer-CI:${GITHUB_TOKEN}@github.com/${LS_USER}/${LS_REPO}.git --all
|
git push https://LinuxServer-CI:${GITHUB_TOKEN}@github.com/${LS_USER}/${LS_REPO}.git --all
|
||||||
echo "true" > /tmp/${COMMIT_SHA}-${BUILD_NUMBER}
|
echo "true" > /tmp/${COMMIT_SHA}-${BUILD_NUMBER}
|
||||||
echo "Deleting old templates"
|
echo "Deleting old and deprecated templates"
|
||||||
rm -Rf ${TEMPDIR}
|
rm -Rf ${TEMPDIR}
|
||||||
exit 0
|
exit 0
|
||||||
else
|
else
|
||||||
@ -308,17 +321,18 @@ pipeline {
|
|||||||
mkdir -p ${TEMPDIR}/repo
|
mkdir -p ${TEMPDIR}/repo
|
||||||
git clone https://github.com/${LS_USER}/${LS_REPO}.git ${TEMPDIR}/repo/${LS_REPO}
|
git clone https://github.com/${LS_USER}/${LS_REPO}.git ${TEMPDIR}/repo/${LS_REPO}
|
||||||
cd ${TEMPDIR}/repo/${LS_REPO}
|
cd ${TEMPDIR}/repo/${LS_REPO}
|
||||||
git checkout -f main
|
git checkout -f develop
|
||||||
cd ${TEMPDIR}/docker-${CONTAINER_NAME}
|
cd ${TEMPDIR}/docker-${CONTAINER_NAME}
|
||||||
mkdir -p ${TEMPDIR}/repo/${LS_REPO}/.github/workflows
|
mkdir -p ${TEMPDIR}/repo/${LS_REPO}/.github/workflows
|
||||||
mkdir -p ${TEMPDIR}/repo/${LS_REPO}/.github/ISSUE_TEMPLATE
|
mkdir -p ${TEMPDIR}/repo/${LS_REPO}/.github/ISSUE_TEMPLATE
|
||||||
cp --parents ${TEMPLATED_FILES} ${TEMPDIR}/repo/${LS_REPO}/ || :
|
cp --parents ${TEMPLATED_FILES} ${TEMPDIR}/repo/${LS_REPO}/ || :
|
||||||
|
cp --parents readme-vars.yml ${TEMPDIR}/repo/${LS_REPO}/ || :
|
||||||
cd ${TEMPDIR}/repo/${LS_REPO}/
|
cd ${TEMPDIR}/repo/${LS_REPO}/
|
||||||
if ! grep -q '.jenkins-external' .gitignore 2>/dev/null; then
|
if ! grep -q '.jenkins-external' .gitignore 2>/dev/null; then
|
||||||
echo ".jenkins-external" >> .gitignore
|
echo ".jenkins-external" >> .gitignore
|
||||||
git add .gitignore
|
git add .gitignore
|
||||||
fi
|
fi
|
||||||
git add ${TEMPLATED_FILES}
|
git add readme-vars.yml ${TEMPLATED_FILES}
|
||||||
git commit -m 'Bot Updating Templated Files'
|
git commit -m 'Bot Updating Templated Files'
|
||||||
git push https://LinuxServer-CI:${GITHUB_TOKEN}@github.com/${LS_USER}/${LS_REPO}.git --all
|
git push https://LinuxServer-CI:${GITHUB_TOKEN}@github.com/${LS_USER}/${LS_REPO}.git --all
|
||||||
echo "true" > /tmp/${COMMIT_SHA}-${BUILD_NUMBER}
|
echo "true" > /tmp/${COMMIT_SHA}-${BUILD_NUMBER}
|
||||||
@ -339,13 +353,17 @@ pipeline {
|
|||||||
git clone https://github.com/linuxserver/templates.git ${TEMPDIR}/unraid/templates
|
git clone https://github.com/linuxserver/templates.git ${TEMPDIR}/unraid/templates
|
||||||
if [[ -f ${TEMPDIR}/unraid/docker-templates/linuxserver.io/img/${CONTAINER_NAME}-logo.png ]]; then
|
if [[ -f ${TEMPDIR}/unraid/docker-templates/linuxserver.io/img/${CONTAINER_NAME}-logo.png ]]; then
|
||||||
sed -i "s|master/linuxserver.io/img/linuxserver-ls-logo.png|master/linuxserver.io/img/${CONTAINER_NAME}-logo.png|" ${TEMPDIR}/docker-${CONTAINER_NAME}/.jenkins-external/${CONTAINER_NAME}.xml
|
sed -i "s|master/linuxserver.io/img/linuxserver-ls-logo.png|master/linuxserver.io/img/${CONTAINER_NAME}-logo.png|" ${TEMPDIR}/docker-${CONTAINER_NAME}/.jenkins-external/${CONTAINER_NAME}.xml
|
||||||
|
elif [[ -f ${TEMPDIR}/unraid/docker-templates/linuxserver.io/img/${CONTAINER_NAME}-icon.png ]]; then
|
||||||
|
sed -i "s|master/linuxserver.io/img/linuxserver-ls-logo.png|master/linuxserver.io/img/${CONTAINER_NAME}-icon.png|" ${TEMPDIR}/docker-${CONTAINER_NAME}/.jenkins-external/${CONTAINER_NAME}.xml
|
||||||
fi
|
fi
|
||||||
if [[ ("${BRANCH_NAME}" == "master") || ("${BRANCH_NAME}" == "main") ]] && [[ (! -f ${TEMPDIR}/unraid/templates/unraid/${CONTAINER_NAME}.xml) || ("$(md5sum ${TEMPDIR}/unraid/templates/unraid/${CONTAINER_NAME}.xml | awk '{ print $1 }')" != "$(md5sum ${TEMPDIR}/docker-${CONTAINER_NAME}/.jenkins-external/${CONTAINER_NAME}.xml | awk '{ print $1 }')") ]]; then
|
if [[ ("${BRANCH_NAME}" == "master") || ("${BRANCH_NAME}" == "main") ]] && [[ (! -f ${TEMPDIR}/unraid/templates/unraid/${CONTAINER_NAME}.xml) || ("$(md5sum ${TEMPDIR}/unraid/templates/unraid/${CONTAINER_NAME}.xml | awk '{ print $1 }')" != "$(md5sum ${TEMPDIR}/docker-${CONTAINER_NAME}/.jenkins-external/${CONTAINER_NAME}.xml | awk '{ print $1 }')") ]]; then
|
||||||
cd ${TEMPDIR}/unraid/templates/
|
cd ${TEMPDIR}/unraid/templates/
|
||||||
if grep -wq "${CONTAINER_NAME}" ${TEMPDIR}/unraid/templates/unraid/ignore.list; then
|
if grep -wq "${CONTAINER_NAME}" ${TEMPDIR}/unraid/templates/unraid/ignore.list; then
|
||||||
echo "Image is on the ignore list, removing Unraid template"
|
echo "Image is on the ignore list, marking Unraid template as deprecated"
|
||||||
git rm unraid/${CONTAINER_NAME}.xml || :
|
cp ${TEMPDIR}/docker-${CONTAINER_NAME}/.jenkins-external/${CONTAINER_NAME}.xml ${TEMPDIR}/unraid/templates/unraid/
|
||||||
git commit -m 'Bot Removing Deprecated Unraid Template' || :
|
git add -u unraid/${CONTAINER_NAME}.xml
|
||||||
|
git mv unraid/${CONTAINER_NAME}.xml unraid/deprecated/${CONTAINER_NAME}.xml || :
|
||||||
|
git commit -m 'Bot Moving Deprecated Unraid Template' || :
|
||||||
else
|
else
|
||||||
cp ${TEMPDIR}/docker-${CONTAINER_NAME}/.jenkins-external/${CONTAINER_NAME}.xml ${TEMPDIR}/unraid/templates/unraid/
|
cp ${TEMPDIR}/docker-${CONTAINER_NAME}/.jenkins-external/${CONTAINER_NAME}.xml ${TEMPDIR}/unraid/templates/unraid/
|
||||||
git add unraid/${CONTAINER_NAME}.xml
|
git add unraid/${CONTAINER_NAME}.xml
|
||||||
@ -364,7 +382,7 @@ pipeline {
|
|||||||
// Exit the build if the Templated files were just updated
|
// Exit the build if the Templated files were just updated
|
||||||
stage('Template-exit') {
|
stage('Template-exit') {
|
||||||
when {
|
when {
|
||||||
branch "main"
|
branch "develop"
|
||||||
environment name: 'CHANGE_ID', value: ''
|
environment name: 'CHANGE_ID', value: ''
|
||||||
environment name: 'FILES_UPDATED', value: 'true'
|
environment name: 'FILES_UPDATED', value: 'true'
|
||||||
expression {
|
expression {
|
||||||
@ -377,6 +395,26 @@ pipeline {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// If this is a develop build check the S6 service file perms
|
||||||
|
stage("Check S6 Service file Permissions"){
|
||||||
|
when {
|
||||||
|
branch "develop"
|
||||||
|
environment name: 'CHANGE_ID', value: ''
|
||||||
|
environment name: 'EXIT_STATUS', value: ''
|
||||||
|
}
|
||||||
|
steps {
|
||||||
|
script{
|
||||||
|
sh '''#! /bin/bash
|
||||||
|
WRONG_PERM=$(find ./ -path "./.git" -prune -o \\( -name "run" -o -name "finish" -o -name "check" \\) -not -perm -u=x,g=x,o=x -print)
|
||||||
|
if [[ -n "${WRONG_PERM}" ]]; then
|
||||||
|
echo "The following S6 service files are missing the executable bit; canceling the faulty build: ${WRONG_PERM}"
|
||||||
|
exit 1
|
||||||
|
else
|
||||||
|
echo "S6 service file perms look good."
|
||||||
|
fi '''
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
/* #######################
|
/* #######################
|
||||||
GitLab Mirroring
|
GitLab Mirroring
|
||||||
####################### */
|
####################### */
|
||||||
@ -403,13 +441,12 @@ pipeline {
|
|||||||
// Add package to Scarf.sh and set permissions
|
// Add package to Scarf.sh and set permissions
|
||||||
stage("Scarf.sh package registry"){
|
stage("Scarf.sh package registry"){
|
||||||
when {
|
when {
|
||||||
branch "main"
|
branch "develop"
|
||||||
environment name: 'EXIT_STATUS', value: ''
|
environment name: 'EXIT_STATUS', value: ''
|
||||||
}
|
}
|
||||||
steps{
|
steps{
|
||||||
sh '''#! /bin/bash
|
sh '''#! /bin/bash
|
||||||
set -e
|
PACKAGE_UUID=$(curl -X GET -H "Authorization: Bearer ${SCARF_TOKEN}" https://scarf.sh/api/v1/organizations/linuxserver-ci/packages | jq -r '.[] | select(.name=="linuxserver/pyload-ng") | .uuid' || :)
|
||||||
PACKAGE_UUID=$(curl -X GET -H "Authorization: Bearer ${SCARF_TOKEN}" https://scarf.sh/api/v1/organizations/linuxserver-ci/packages | jq -r '.[] | select(.name=="linuxserver/pyload-ng") | .uuid')
|
|
||||||
if [ -z "${PACKAGE_UUID}" ]; then
|
if [ -z "${PACKAGE_UUID}" ]; then
|
||||||
echo "Adding package to Scarf.sh"
|
echo "Adding package to Scarf.sh"
|
||||||
curl -sX POST https://scarf.sh/api/v1/organizations/linuxserver-ci/packages \
|
curl -sX POST https://scarf.sh/api/v1/organizations/linuxserver-ci/packages \
|
||||||
@ -440,7 +477,8 @@ pipeline {
|
|||||||
}
|
}
|
||||||
steps {
|
steps {
|
||||||
echo "Running on node: ${NODE_NAME}"
|
echo "Running on node: ${NODE_NAME}"
|
||||||
sh "docker build \
|
sh "sed -r -i 's|(^FROM .*)|\\1\\n\\nENV LSIO_FIRST_PARTY=true|g' Dockerfile"
|
||||||
|
sh "docker buildx build \
|
||||||
--label \"org.opencontainers.image.created=${GITHUB_DATE}\" \
|
--label \"org.opencontainers.image.created=${GITHUB_DATE}\" \
|
||||||
--label \"org.opencontainers.image.authors=linuxserver.io\" \
|
--label \"org.opencontainers.image.authors=linuxserver.io\" \
|
||||||
--label \"org.opencontainers.image.url=https://github.com/linuxserver/docker-pyload-ng/packages\" \
|
--label \"org.opencontainers.image.url=https://github.com/linuxserver/docker-pyload-ng/packages\" \
|
||||||
@ -453,7 +491,7 @@ pipeline {
|
|||||||
--label \"org.opencontainers.image.ref.name=${COMMIT_SHA}\" \
|
--label \"org.opencontainers.image.ref.name=${COMMIT_SHA}\" \
|
||||||
--label \"org.opencontainers.image.title=Pyload-ng\" \
|
--label \"org.opencontainers.image.title=Pyload-ng\" \
|
||||||
--label \"org.opencontainers.image.description=[pyLoad](https://pyload.net/) is a Free and Open Source download manager written in Python and designed to be extremely lightweight, easily extensible and fully manageable via web.\" \
|
--label \"org.opencontainers.image.description=[pyLoad](https://pyload.net/) is a Free and Open Source download manager written in Python and designed to be extremely lightweight, easily extensible and fully manageable via web.\" \
|
||||||
--no-cache --pull -t ${IMAGE}:${META_TAG} \
|
--no-cache --pull -t ${IMAGE}:${META_TAG} --platform=linux/amd64 \
|
||||||
--build-arg ${BUILD_VERSION_ARG}=${EXT_RELEASE} --build-arg VERSION=\"${VERSION_TAG}\" --build-arg BUILD_DATE=${GITHUB_DATE} ."
|
--build-arg ${BUILD_VERSION_ARG}=${EXT_RELEASE} --build-arg VERSION=\"${VERSION_TAG}\" --build-arg BUILD_DATE=${GITHUB_DATE} ."
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -470,7 +508,8 @@ pipeline {
|
|||||||
stage('Build X86') {
|
stage('Build X86') {
|
||||||
steps {
|
steps {
|
||||||
echo "Running on node: ${NODE_NAME}"
|
echo "Running on node: ${NODE_NAME}"
|
||||||
sh "docker build \
|
sh "sed -r -i 's|(^FROM .*)|\\1\\n\\nENV LSIO_FIRST_PARTY=true|g' Dockerfile"
|
||||||
|
sh "docker buildx build \
|
||||||
--label \"org.opencontainers.image.created=${GITHUB_DATE}\" \
|
--label \"org.opencontainers.image.created=${GITHUB_DATE}\" \
|
||||||
--label \"org.opencontainers.image.authors=linuxserver.io\" \
|
--label \"org.opencontainers.image.authors=linuxserver.io\" \
|
||||||
--label \"org.opencontainers.image.url=https://github.com/linuxserver/docker-pyload-ng/packages\" \
|
--label \"org.opencontainers.image.url=https://github.com/linuxserver/docker-pyload-ng/packages\" \
|
||||||
@ -483,44 +522,10 @@ pipeline {
|
|||||||
--label \"org.opencontainers.image.ref.name=${COMMIT_SHA}\" \
|
--label \"org.opencontainers.image.ref.name=${COMMIT_SHA}\" \
|
||||||
--label \"org.opencontainers.image.title=Pyload-ng\" \
|
--label \"org.opencontainers.image.title=Pyload-ng\" \
|
||||||
--label \"org.opencontainers.image.description=[pyLoad](https://pyload.net/) is a Free and Open Source download manager written in Python and designed to be extremely lightweight, easily extensible and fully manageable via web.\" \
|
--label \"org.opencontainers.image.description=[pyLoad](https://pyload.net/) is a Free and Open Source download manager written in Python and designed to be extremely lightweight, easily extensible and fully manageable via web.\" \
|
||||||
--no-cache --pull -t ${IMAGE}:amd64-${META_TAG} \
|
--no-cache --pull -t ${IMAGE}:amd64-${META_TAG} --platform=linux/amd64 \
|
||||||
--build-arg ${BUILD_VERSION_ARG}=${EXT_RELEASE} --build-arg VERSION=\"${VERSION_TAG}\" --build-arg BUILD_DATE=${GITHUB_DATE} ."
|
--build-arg ${BUILD_VERSION_ARG}=${EXT_RELEASE} --build-arg VERSION=\"${VERSION_TAG}\" --build-arg BUILD_DATE=${GITHUB_DATE} ."
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
stage('Build ARMHF') {
|
|
||||||
agent {
|
|
||||||
label 'ARMHF'
|
|
||||||
}
|
|
||||||
steps {
|
|
||||||
echo "Running on node: ${NODE_NAME}"
|
|
||||||
echo 'Logging into Github'
|
|
||||||
sh '''#! /bin/bash
|
|
||||||
echo $GITHUB_TOKEN | docker login ghcr.io -u LinuxServer-CI --password-stdin
|
|
||||||
'''
|
|
||||||
sh "docker build \
|
|
||||||
--label \"org.opencontainers.image.created=${GITHUB_DATE}\" \
|
|
||||||
--label \"org.opencontainers.image.authors=linuxserver.io\" \
|
|
||||||
--label \"org.opencontainers.image.url=https://github.com/linuxserver/docker-pyload-ng/packages\" \
|
|
||||||
--label \"org.opencontainers.image.documentation=https://docs.linuxserver.io/images/docker-pyload-ng\" \
|
|
||||||
--label \"org.opencontainers.image.source=https://github.com/linuxserver/docker-pyload-ng\" \
|
|
||||||
--label \"org.opencontainers.image.version=${EXT_RELEASE_CLEAN}-ls${LS_TAG_NUMBER}\" \
|
|
||||||
--label \"org.opencontainers.image.revision=${COMMIT_SHA}\" \
|
|
||||||
--label \"org.opencontainers.image.vendor=linuxserver.io\" \
|
|
||||||
--label \"org.opencontainers.image.licenses=GPL-3.0-only\" \
|
|
||||||
--label \"org.opencontainers.image.ref.name=${COMMIT_SHA}\" \
|
|
||||||
--label \"org.opencontainers.image.title=Pyload-ng\" \
|
|
||||||
--label \"org.opencontainers.image.description=[pyLoad](https://pyload.net/) is a Free and Open Source download manager written in Python and designed to be extremely lightweight, easily extensible and fully manageable via web.\" \
|
|
||||||
--no-cache --pull -f Dockerfile.armhf -t ${IMAGE}:arm32v7-${META_TAG} \
|
|
||||||
--build-arg ${BUILD_VERSION_ARG}=${EXT_RELEASE} --build-arg VERSION=\"${VERSION_TAG}\" --build-arg BUILD_DATE=${GITHUB_DATE} ."
|
|
||||||
sh "docker tag ${IMAGE}:arm32v7-${META_TAG} ghcr.io/linuxserver/lsiodev-buildcache:arm32v7-${COMMIT_SHA}-${BUILD_NUMBER}"
|
|
||||||
retry(5) {
|
|
||||||
sh "docker push ghcr.io/linuxserver/lsiodev-buildcache:arm32v7-${COMMIT_SHA}-${BUILD_NUMBER}"
|
|
||||||
}
|
|
||||||
sh '''docker rmi \
|
|
||||||
${IMAGE}:arm32v7-${META_TAG} \
|
|
||||||
ghcr.io/linuxserver/lsiodev-buildcache:arm32v7-${COMMIT_SHA}-${BUILD_NUMBER} || :'''
|
|
||||||
}
|
|
||||||
}
|
|
||||||
stage('Build ARM64') {
|
stage('Build ARM64') {
|
||||||
agent {
|
agent {
|
||||||
label 'ARM64'
|
label 'ARM64'
|
||||||
@ -531,7 +536,8 @@ pipeline {
|
|||||||
sh '''#! /bin/bash
|
sh '''#! /bin/bash
|
||||||
echo $GITHUB_TOKEN | docker login ghcr.io -u LinuxServer-CI --password-stdin
|
echo $GITHUB_TOKEN | docker login ghcr.io -u LinuxServer-CI --password-stdin
|
||||||
'''
|
'''
|
||||||
sh "docker build \
|
sh "sed -r -i 's|(^FROM .*)|\\1\\n\\nENV LSIO_FIRST_PARTY=true|g' Dockerfile.aarch64"
|
||||||
|
sh "docker buildx build \
|
||||||
--label \"org.opencontainers.image.created=${GITHUB_DATE}\" \
|
--label \"org.opencontainers.image.created=${GITHUB_DATE}\" \
|
||||||
--label \"org.opencontainers.image.authors=linuxserver.io\" \
|
--label \"org.opencontainers.image.authors=linuxserver.io\" \
|
||||||
--label \"org.opencontainers.image.url=https://github.com/linuxserver/docker-pyload-ng/packages\" \
|
--label \"org.opencontainers.image.url=https://github.com/linuxserver/docker-pyload-ng/packages\" \
|
||||||
@ -544,15 +550,18 @@ pipeline {
|
|||||||
--label \"org.opencontainers.image.ref.name=${COMMIT_SHA}\" \
|
--label \"org.opencontainers.image.ref.name=${COMMIT_SHA}\" \
|
||||||
--label \"org.opencontainers.image.title=Pyload-ng\" \
|
--label \"org.opencontainers.image.title=Pyload-ng\" \
|
||||||
--label \"org.opencontainers.image.description=[pyLoad](https://pyload.net/) is a Free and Open Source download manager written in Python and designed to be extremely lightweight, easily extensible and fully manageable via web.\" \
|
--label \"org.opencontainers.image.description=[pyLoad](https://pyload.net/) is a Free and Open Source download manager written in Python and designed to be extremely lightweight, easily extensible and fully manageable via web.\" \
|
||||||
--no-cache --pull -f Dockerfile.aarch64 -t ${IMAGE}:arm64v8-${META_TAG} \
|
--no-cache --pull -f Dockerfile.aarch64 -t ${IMAGE}:arm64v8-${META_TAG} --platform=linux/arm64 \
|
||||||
--build-arg ${BUILD_VERSION_ARG}=${EXT_RELEASE} --build-arg VERSION=\"${VERSION_TAG}\" --build-arg BUILD_DATE=${GITHUB_DATE} ."
|
--build-arg ${BUILD_VERSION_ARG}=${EXT_RELEASE} --build-arg VERSION=\"${VERSION_TAG}\" --build-arg BUILD_DATE=${GITHUB_DATE} ."
|
||||||
sh "docker tag ${IMAGE}:arm64v8-${META_TAG} ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER}"
|
sh "docker tag ${IMAGE}:arm64v8-${META_TAG} ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER}"
|
||||||
retry(5) {
|
retry(5) {
|
||||||
sh "docker push ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER}"
|
sh "docker push ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER}"
|
||||||
}
|
}
|
||||||
sh '''docker rmi \
|
sh '''#! /bin/bash
|
||||||
${IMAGE}:arm64v8-${META_TAG} \
|
containers=$(docker ps -aq)
|
||||||
ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER} || :'''
|
if [[ -n "${containers}" ]]; then
|
||||||
|
docker stop ${containers}
|
||||||
|
fi
|
||||||
|
docker system prune -af --volumes || : '''
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -560,7 +569,7 @@ pipeline {
|
|||||||
// Take the image we just built and dump package versions for comparison
|
// Take the image we just built and dump package versions for comparison
|
||||||
stage('Update-packages') {
|
stage('Update-packages') {
|
||||||
when {
|
when {
|
||||||
branch "main"
|
branch "develop"
|
||||||
environment name: 'CHANGE_ID', value: ''
|
environment name: 'CHANGE_ID', value: ''
|
||||||
environment name: 'EXIT_STATUS', value: ''
|
environment name: 'EXIT_STATUS', value: ''
|
||||||
}
|
}
|
||||||
@ -573,31 +582,17 @@ pipeline {
|
|||||||
else
|
else
|
||||||
LOCAL_CONTAINER=${IMAGE}:${META_TAG}
|
LOCAL_CONTAINER=${IMAGE}:${META_TAG}
|
||||||
fi
|
fi
|
||||||
if [ "${DIST_IMAGE}" == "alpine" ]; then
|
touch ${TEMPDIR}/package_versions.txt
|
||||||
docker run --rm --entrypoint '/bin/sh' -v ${TEMPDIR}:/tmp ${LOCAL_CONTAINER} -c '\
|
docker run --rm \
|
||||||
apk info -v > /tmp/package_versions.txt && \
|
-v /var/run/docker.sock:/var/run/docker.sock:ro \
|
||||||
sort -o /tmp/package_versions.txt /tmp/package_versions.txt && \
|
-v ${TEMPDIR}:/tmp \
|
||||||
chmod 777 /tmp/package_versions.txt'
|
ghcr.io/anchore/syft:latest \
|
||||||
elif [ "${DIST_IMAGE}" == "ubuntu" ]; then
|
${LOCAL_CONTAINER} -o table=/tmp/package_versions.txt
|
||||||
docker run --rm --entrypoint '/bin/sh' -v ${TEMPDIR}:/tmp ${LOCAL_CONTAINER} -c '\
|
|
||||||
apt list -qq --installed | sed "s#/.*now ##g" | cut -d" " -f1 > /tmp/package_versions.txt && \
|
|
||||||
sort -o /tmp/package_versions.txt /tmp/package_versions.txt && \
|
|
||||||
chmod 777 /tmp/package_versions.txt'
|
|
||||||
elif [ "${DIST_IMAGE}" == "fedora" ]; then
|
|
||||||
docker run --rm --entrypoint '/bin/sh' -v ${TEMPDIR}:/tmp ${LOCAL_CONTAINER} -c '\
|
|
||||||
rpm -qa > /tmp/package_versions.txt && \
|
|
||||||
sort -o /tmp/package_versions.txt /tmp/package_versions.txt && \
|
|
||||||
chmod 777 /tmp/package_versions.txt'
|
|
||||||
elif [ "${DIST_IMAGE}" == "arch" ]; then
|
|
||||||
docker run --rm --entrypoint '/bin/sh' -v ${TEMPDIR}:/tmp ${LOCAL_CONTAINER} -c '\
|
|
||||||
pacman -Q > /tmp/package_versions.txt && \
|
|
||||||
chmod 777 /tmp/package_versions.txt'
|
|
||||||
fi
|
|
||||||
NEW_PACKAGE_TAG=$(md5sum ${TEMPDIR}/package_versions.txt | cut -c1-8 )
|
NEW_PACKAGE_TAG=$(md5sum ${TEMPDIR}/package_versions.txt | cut -c1-8 )
|
||||||
echo "Package tag sha from current packages in buit container is ${NEW_PACKAGE_TAG} comparing to old ${PACKAGE_TAG} from github"
|
echo "Package tag sha from current packages in buit container is ${NEW_PACKAGE_TAG} comparing to old ${PACKAGE_TAG} from github"
|
||||||
if [ "${NEW_PACKAGE_TAG}" != "${PACKAGE_TAG}" ]; then
|
if [ "${NEW_PACKAGE_TAG}" != "${PACKAGE_TAG}" ]; then
|
||||||
git clone https://github.com/${LS_USER}/${LS_REPO}.git ${TEMPDIR}/${LS_REPO}
|
git clone https://github.com/${LS_USER}/${LS_REPO}.git ${TEMPDIR}/${LS_REPO}
|
||||||
git --git-dir ${TEMPDIR}/${LS_REPO}/.git checkout -f main
|
git --git-dir ${TEMPDIR}/${LS_REPO}/.git checkout -f develop
|
||||||
cp ${TEMPDIR}/package_versions.txt ${TEMPDIR}/${LS_REPO}/
|
cp ${TEMPDIR}/package_versions.txt ${TEMPDIR}/${LS_REPO}/
|
||||||
cd ${TEMPDIR}/${LS_REPO}/
|
cd ${TEMPDIR}/${LS_REPO}/
|
||||||
wait
|
wait
|
||||||
@ -621,19 +616,12 @@ pipeline {
|
|||||||
// Exit the build if the package file was just updated
|
// Exit the build if the package file was just updated
|
||||||
stage('PACKAGE-exit') {
|
stage('PACKAGE-exit') {
|
||||||
when {
|
when {
|
||||||
branch "main"
|
branch "develop"
|
||||||
environment name: 'CHANGE_ID', value: ''
|
environment name: 'CHANGE_ID', value: ''
|
||||||
environment name: 'PACKAGE_UPDATED', value: 'true'
|
environment name: 'PACKAGE_UPDATED', value: 'true'
|
||||||
environment name: 'EXIT_STATUS', value: ''
|
environment name: 'EXIT_STATUS', value: ''
|
||||||
}
|
}
|
||||||
steps {
|
steps {
|
||||||
sh '''#! /bin/bash
|
|
||||||
echo "Packages were updated. Cleaning up the image and exiting."
|
|
||||||
if [ "${MULTIARCH}" == "true" ] && [ "${PACKAGE_CHECK}" == "false" ]; then
|
|
||||||
docker rmi ${IMAGE}:amd64-${META_TAG}
|
|
||||||
else
|
|
||||||
docker rmi ${IMAGE}:${META_TAG}
|
|
||||||
fi'''
|
|
||||||
script{
|
script{
|
||||||
env.EXIT_STATUS = 'ABORTED'
|
env.EXIT_STATUS = 'ABORTED'
|
||||||
}
|
}
|
||||||
@ -642,7 +630,7 @@ pipeline {
|
|||||||
// Exit the build if this is just a package check and there are no changes to push
|
// Exit the build if this is just a package check and there are no changes to push
|
||||||
stage('PACKAGECHECK-exit') {
|
stage('PACKAGECHECK-exit') {
|
||||||
when {
|
when {
|
||||||
branch "main"
|
branch "develop"
|
||||||
environment name: 'CHANGE_ID', value: ''
|
environment name: 'CHANGE_ID', value: ''
|
||||||
environment name: 'PACKAGE_UPDATED', value: 'false'
|
environment name: 'PACKAGE_UPDATED', value: 'false'
|
||||||
environment name: 'EXIT_STATUS', value: ''
|
environment name: 'EXIT_STATUS', value: ''
|
||||||
@ -651,13 +639,6 @@ pipeline {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
steps {
|
steps {
|
||||||
sh '''#! /bin/bash
|
|
||||||
echo "There are no package updates. Cleaning up the image and exiting."
|
|
||||||
if [ "${MULTIARCH}" == "true" ] && [ "${PACKAGE_CHECK}" == "false" ]; then
|
|
||||||
docker rmi ${IMAGE}:amd64-${META_TAG}
|
|
||||||
else
|
|
||||||
docker rmi ${IMAGE}:${META_TAG}
|
|
||||||
fi'''
|
|
||||||
script{
|
script{
|
||||||
env.EXIT_STATUS = 'ABORTED'
|
env.EXIT_STATUS = 'ABORTED'
|
||||||
}
|
}
|
||||||
@ -679,14 +660,13 @@ pipeline {
|
|||||||
]) {
|
]) {
|
||||||
script{
|
script{
|
||||||
env.CI_URL = 'https://ci-tests.linuxserver.io/' + env.IMAGE + '/' + env.META_TAG + '/index.html'
|
env.CI_URL = 'https://ci-tests.linuxserver.io/' + env.IMAGE + '/' + env.META_TAG + '/index.html'
|
||||||
|
env.CI_JSON_URL = 'https://ci-tests.linuxserver.io/' + env.IMAGE + '/' + env.META_TAG + '/report.json'
|
||||||
}
|
}
|
||||||
sh '''#! /bin/bash
|
sh '''#! /bin/bash
|
||||||
set -e
|
set -e
|
||||||
docker pull ghcr.io/linuxserver/ci:latest
|
docker pull ghcr.io/linuxserver/ci:latest
|
||||||
if [ "${MULTIARCH}" == "true" ]; then
|
if [ "${MULTIARCH}" == "true" ]; then
|
||||||
docker pull ghcr.io/linuxserver/lsiodev-buildcache:arm32v7-${COMMIT_SHA}-${BUILD_NUMBER}
|
|
||||||
docker pull ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER}
|
docker pull ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER}
|
||||||
docker tag ghcr.io/linuxserver/lsiodev-buildcache:arm32v7-${COMMIT_SHA}-${BUILD_NUMBER} ${IMAGE}:arm32v7-${META_TAG}
|
|
||||||
docker tag ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER} ${IMAGE}:arm64v8-${META_TAG}
|
docker tag ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER} ${IMAGE}:arm64v8-${META_TAG}
|
||||||
fi
|
fi
|
||||||
docker run --rm \
|
docker run --rm \
|
||||||
@ -705,10 +685,8 @@ pipeline {
|
|||||||
-e WEB_SCREENSHOT=\"${CI_WEB}\" \
|
-e WEB_SCREENSHOT=\"${CI_WEB}\" \
|
||||||
-e WEB_AUTH=\"${CI_AUTH}\" \
|
-e WEB_AUTH=\"${CI_AUTH}\" \
|
||||||
-e WEB_PATH=\"${CI_WEBPATH}\" \
|
-e WEB_PATH=\"${CI_WEBPATH}\" \
|
||||||
-e DO_REGION="ams3" \
|
|
||||||
-e DO_BUCKET="lsio-ci" \
|
|
||||||
-t ghcr.io/linuxserver/ci:latest \
|
-t ghcr.io/linuxserver/ci:latest \
|
||||||
python /ci/ci.py'''
|
python3 test_build.py'''
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -745,12 +723,12 @@ pipeline {
|
|||||||
echo $QUAYPASS | docker login quay.io -u $QUAYUSER --password-stdin
|
echo $QUAYPASS | docker login quay.io -u $QUAYUSER --password-stdin
|
||||||
for PUSHIMAGE in "${GITHUBIMAGE}" "${GITLABIMAGE}" "${QUAYIMAGE}" "${IMAGE}"; do
|
for PUSHIMAGE in "${GITHUBIMAGE}" "${GITLABIMAGE}" "${QUAYIMAGE}" "${IMAGE}"; do
|
||||||
docker tag ${IMAGE}:${META_TAG} ${PUSHIMAGE}:${META_TAG}
|
docker tag ${IMAGE}:${META_TAG} ${PUSHIMAGE}:${META_TAG}
|
||||||
docker tag ${PUSHIMAGE}:${META_TAG} ${PUSHIMAGE}:latest
|
docker tag ${PUSHIMAGE}:${META_TAG} ${PUSHIMAGE}:develop
|
||||||
docker tag ${PUSHIMAGE}:${META_TAG} ${PUSHIMAGE}:${EXT_RELEASE_TAG}
|
docker tag ${PUSHIMAGE}:${META_TAG} ${PUSHIMAGE}:${EXT_RELEASE_TAG}
|
||||||
if [ -n "${SEMVER}" ]; then
|
if [ -n "${SEMVER}" ]; then
|
||||||
docker tag ${PUSHIMAGE}:${META_TAG} ${PUSHIMAGE}:${SEMVER}
|
docker tag ${PUSHIMAGE}:${META_TAG} ${PUSHIMAGE}:${SEMVER}
|
||||||
fi
|
fi
|
||||||
docker push ${PUSHIMAGE}:latest
|
docker push ${PUSHIMAGE}:develop
|
||||||
docker push ${PUSHIMAGE}:${META_TAG}
|
docker push ${PUSHIMAGE}:${META_TAG}
|
||||||
docker push ${PUSHIMAGE}:${EXT_RELEASE_TAG}
|
docker push ${PUSHIMAGE}:${EXT_RELEASE_TAG}
|
||||||
if [ -n "${SEMVER}" ]; then
|
if [ -n "${SEMVER}" ]; then
|
||||||
@ -759,17 +737,6 @@ pipeline {
|
|||||||
done
|
done
|
||||||
'''
|
'''
|
||||||
}
|
}
|
||||||
sh '''#! /bin/bash
|
|
||||||
for DELETEIMAGE in "${GITHUBIMAGE}" "${GITLABIMAGE}" "${QUAYIMAGE}" "${IMAGE}"; do
|
|
||||||
docker rmi \
|
|
||||||
${DELETEIMAGE}:${META_TAG} \
|
|
||||||
${DELETEIMAGE}:${EXT_RELEASE_TAG} \
|
|
||||||
${DELETEIMAGE}:latest || :
|
|
||||||
if [ -n "${SEMVER}" ]; then
|
|
||||||
docker rmi ${DELETEIMAGE}:${SEMVER} || :
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
'''
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -802,59 +769,55 @@ pipeline {
|
|||||||
echo $GITLAB_TOKEN | docker login registry.gitlab.com -u LinuxServer.io --password-stdin
|
echo $GITLAB_TOKEN | docker login registry.gitlab.com -u LinuxServer.io --password-stdin
|
||||||
echo $QUAYPASS | docker login quay.io -u $QUAYUSER --password-stdin
|
echo $QUAYPASS | docker login quay.io -u $QUAYUSER --password-stdin
|
||||||
if [ "${CI}" == "false" ]; then
|
if [ "${CI}" == "false" ]; then
|
||||||
docker pull ghcr.io/linuxserver/lsiodev-buildcache:arm32v7-${COMMIT_SHA}-${BUILD_NUMBER}
|
|
||||||
docker pull ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER}
|
docker pull ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER}
|
||||||
docker tag ghcr.io/linuxserver/lsiodev-buildcache:arm32v7-${COMMIT_SHA}-${BUILD_NUMBER} ${IMAGE}:arm32v7-${META_TAG}
|
|
||||||
docker tag ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER} ${IMAGE}:arm64v8-${META_TAG}
|
docker tag ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER} ${IMAGE}:arm64v8-${META_TAG}
|
||||||
fi
|
fi
|
||||||
for MANIFESTIMAGE in "${IMAGE}" "${GITLABIMAGE}" "${GITHUBIMAGE}" "${QUAYIMAGE}"; do
|
for MANIFESTIMAGE in "${IMAGE}" "${GITLABIMAGE}" "${GITHUBIMAGE}" "${QUAYIMAGE}"; do
|
||||||
docker tag ${IMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-${META_TAG}
|
docker tag ${IMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-${META_TAG}
|
||||||
docker tag ${IMAGE}:arm32v7-${META_TAG} ${MANIFESTIMAGE}:arm32v7-${META_TAG}
|
docker tag ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-develop
|
||||||
docker tag ${IMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${META_TAG}
|
|
||||||
docker tag ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-latest
|
|
||||||
docker tag ${MANIFESTIMAGE}:arm32v7-${META_TAG} ${MANIFESTIMAGE}:arm32v7-latest
|
|
||||||
docker tag ${MANIFESTIMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-latest
|
|
||||||
docker tag ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-${EXT_RELEASE_TAG}
|
docker tag ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-${EXT_RELEASE_TAG}
|
||||||
docker tag ${MANIFESTIMAGE}:arm32v7-${META_TAG} ${MANIFESTIMAGE}:arm32v7-${EXT_RELEASE_TAG}
|
docker tag ${IMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${META_TAG}
|
||||||
|
docker tag ${MANIFESTIMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-develop
|
||||||
docker tag ${MANIFESTIMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${EXT_RELEASE_TAG}
|
docker tag ${MANIFESTIMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${EXT_RELEASE_TAG}
|
||||||
if [ -n "${SEMVER}" ]; then
|
if [ -n "${SEMVER}" ]; then
|
||||||
docker tag ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-${SEMVER}
|
docker tag ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-${SEMVER}
|
||||||
docker tag ${MANIFESTIMAGE}:arm32v7-${META_TAG} ${MANIFESTIMAGE}:arm32v7-${SEMVER}
|
|
||||||
docker tag ${MANIFESTIMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${SEMVER}
|
docker tag ${MANIFESTIMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${SEMVER}
|
||||||
fi
|
fi
|
||||||
docker push ${MANIFESTIMAGE}:amd64-${META_TAG}
|
docker push ${MANIFESTIMAGE}:amd64-${META_TAG}
|
||||||
docker push ${MANIFESTIMAGE}:arm32v7-${META_TAG}
|
|
||||||
docker push ${MANIFESTIMAGE}:arm64v8-${META_TAG}
|
|
||||||
docker push ${MANIFESTIMAGE}:amd64-latest
|
|
||||||
docker push ${MANIFESTIMAGE}:arm32v7-latest
|
|
||||||
docker push ${MANIFESTIMAGE}:arm64v8-latest
|
|
||||||
docker push ${MANIFESTIMAGE}:amd64-${EXT_RELEASE_TAG}
|
docker push ${MANIFESTIMAGE}:amd64-${EXT_RELEASE_TAG}
|
||||||
docker push ${MANIFESTIMAGE}:arm32v7-${EXT_RELEASE_TAG}
|
docker push ${MANIFESTIMAGE}:amd64-develop
|
||||||
|
docker push ${MANIFESTIMAGE}:arm64v8-${META_TAG}
|
||||||
|
docker push ${MANIFESTIMAGE}:arm64v8-develop
|
||||||
docker push ${MANIFESTIMAGE}:arm64v8-${EXT_RELEASE_TAG}
|
docker push ${MANIFESTIMAGE}:arm64v8-${EXT_RELEASE_TAG}
|
||||||
if [ -n "${SEMVER}" ]; then
|
if [ -n "${SEMVER}" ]; then
|
||||||
docker push ${MANIFESTIMAGE}:amd64-${SEMVER}
|
docker push ${MANIFESTIMAGE}:amd64-${SEMVER}
|
||||||
docker push ${MANIFESTIMAGE}:arm32v7-${SEMVER}
|
|
||||||
docker push ${MANIFESTIMAGE}:arm64v8-${SEMVER}
|
docker push ${MANIFESTIMAGE}:arm64v8-${SEMVER}
|
||||||
fi
|
fi
|
||||||
docker manifest push --purge ${MANIFESTIMAGE}:latest || :
|
docker manifest push --purge ${MANIFESTIMAGE}:develop || :
|
||||||
docker manifest create ${MANIFESTIMAGE}:latest ${MANIFESTIMAGE}:amd64-latest ${MANIFESTIMAGE}:arm32v7-latest ${MANIFESTIMAGE}:arm64v8-latest
|
docker manifest create ${MANIFESTIMAGE}:develop ${MANIFESTIMAGE}:amd64-develop ${MANIFESTIMAGE}:arm64v8-develop
|
||||||
docker manifest annotate ${MANIFESTIMAGE}:latest ${MANIFESTIMAGE}:arm32v7-latest --os linux --arch arm
|
docker manifest annotate ${MANIFESTIMAGE}:develop ${MANIFESTIMAGE}:arm64v8-develop --os linux --arch arm64 --variant v8
|
||||||
docker manifest annotate ${MANIFESTIMAGE}:latest ${MANIFESTIMAGE}:arm64v8-latest --os linux --arch arm64 --variant v8
|
|
||||||
docker manifest push --purge ${MANIFESTIMAGE}:${META_TAG} || :
|
docker manifest push --purge ${MANIFESTIMAGE}:${META_TAG} || :
|
||||||
docker manifest create ${MANIFESTIMAGE}:${META_TAG} ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:arm32v7-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${META_TAG}
|
docker manifest create ${MANIFESTIMAGE}:${META_TAG} ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${META_TAG}
|
||||||
docker manifest annotate ${MANIFESTIMAGE}:${META_TAG} ${MANIFESTIMAGE}:arm32v7-${META_TAG} --os linux --arch arm
|
|
||||||
docker manifest annotate ${MANIFESTIMAGE}:${META_TAG} ${MANIFESTIMAGE}:arm64v8-${META_TAG} --os linux --arch arm64 --variant v8
|
docker manifest annotate ${MANIFESTIMAGE}:${META_TAG} ${MANIFESTIMAGE}:arm64v8-${META_TAG} --os linux --arch arm64 --variant v8
|
||||||
docker manifest push --purge ${MANIFESTIMAGE}:${EXT_RELEASE_TAG} || :
|
docker manifest push --purge ${MANIFESTIMAGE}:${EXT_RELEASE_TAG} || :
|
||||||
docker manifest create ${MANIFESTIMAGE}:${EXT_RELEASE_TAG} ${MANIFESTIMAGE}:amd64-${EXT_RELEASE_TAG} ${MANIFESTIMAGE}:arm32v7-${EXT_RELEASE_TAG} ${MANIFESTIMAGE}:arm64v8-${EXT_RELEASE_TAG}
|
docker manifest create ${MANIFESTIMAGE}:${EXT_RELEASE_TAG} ${MANIFESTIMAGE}:amd64-${EXT_RELEASE_TAG} ${MANIFESTIMAGE}:arm64v8-${EXT_RELEASE_TAG}
|
||||||
docker manifest annotate ${MANIFESTIMAGE}:${EXT_RELEASE_TAG} ${MANIFESTIMAGE}:arm32v7-${EXT_RELEASE_TAG} --os linux --arch arm
|
|
||||||
docker manifest annotate ${MANIFESTIMAGE}:${EXT_RELEASE_TAG} ${MANIFESTIMAGE}:arm64v8-${EXT_RELEASE_TAG} --os linux --arch arm64 --variant v8
|
docker manifest annotate ${MANIFESTIMAGE}:${EXT_RELEASE_TAG} ${MANIFESTIMAGE}:arm64v8-${EXT_RELEASE_TAG} --os linux --arch arm64 --variant v8
|
||||||
if [ -n "${SEMVER}" ]; then
|
if [ -n "${SEMVER}" ]; then
|
||||||
docker manifest push --purge ${MANIFESTIMAGE}:${SEMVER} || :
|
docker manifest push --purge ${MANIFESTIMAGE}:${SEMVER} || :
|
||||||
docker manifest create ${MANIFESTIMAGE}:${SEMVER} ${MANIFESTIMAGE}:amd64-${SEMVER} ${MANIFESTIMAGE}:arm32v7-${SEMVER} ${MANIFESTIMAGE}:arm64v8-${SEMVER}
|
docker manifest create ${MANIFESTIMAGE}:${SEMVER} ${MANIFESTIMAGE}:amd64-${SEMVER} ${MANIFESTIMAGE}:arm64v8-${SEMVER}
|
||||||
docker manifest annotate ${MANIFESTIMAGE}:${SEMVER} ${MANIFESTIMAGE}:arm32v7-${SEMVER} --os linux --arch arm
|
|
||||||
docker manifest annotate ${MANIFESTIMAGE}:${SEMVER} ${MANIFESTIMAGE}:arm64v8-${SEMVER} --os linux --arch arm64 --variant v8
|
docker manifest annotate ${MANIFESTIMAGE}:${SEMVER} ${MANIFESTIMAGE}:arm64v8-${SEMVER} --os linux --arch arm64 --variant v8
|
||||||
fi
|
fi
|
||||||
docker manifest push --purge ${MANIFESTIMAGE}:latest
|
token=$(curl -sX GET "https://ghcr.io/token?scope=repository%3Alinuxserver%2F${CONTAINER_NAME}%3Apull" | jq -r '.token')
|
||||||
|
digest=$(curl -s \
|
||||||
|
--header "Accept: application/vnd.docker.distribution.manifest.v2+json" \
|
||||||
|
--header "Authorization: Bearer ${token}" \
|
||||||
|
"https://ghcr.io/v2/linuxserver/${CONTAINER_NAME}/manifests/arm32v7-develop")
|
||||||
|
if [[ $(echo "$digest" | jq -r '.layers') != "null" ]]; then
|
||||||
|
docker manifest push --purge ${MANIFESTIMAGE}:arm32v7-develop || :
|
||||||
|
docker manifest create ${MANIFESTIMAGE}:arm32v7-develop ${MANIFESTIMAGE}:amd64-develop
|
||||||
|
docker manifest push --purge ${MANIFESTIMAGE}:arm32v7-develop
|
||||||
|
fi
|
||||||
|
docker manifest push --purge ${MANIFESTIMAGE}:develop
|
||||||
docker manifest push --purge ${MANIFESTIMAGE}:${META_TAG}
|
docker manifest push --purge ${MANIFESTIMAGE}:${META_TAG}
|
||||||
docker manifest push --purge ${MANIFESTIMAGE}:${EXT_RELEASE_TAG}
|
docker manifest push --purge ${MANIFESTIMAGE}:${EXT_RELEASE_TAG}
|
||||||
if [ -n "${SEMVER}" ]; then
|
if [ -n "${SEMVER}" ]; then
|
||||||
@ -863,36 +826,13 @@ pipeline {
|
|||||||
done
|
done
|
||||||
'''
|
'''
|
||||||
}
|
}
|
||||||
sh '''#! /bin/bash
|
|
||||||
for DELETEIMAGE in "${GITHUBIMAGE}" "${GITLABIMAGE}" "${QUAYIMAGE}" "${IMAGE}"; do
|
|
||||||
docker rmi \
|
|
||||||
${DELETEIMAGE}:amd64-${META_TAG} \
|
|
||||||
${DELETEIMAGE}:amd64-latest \
|
|
||||||
${DELETEIMAGE}:amd64-${EXT_RELEASE_TAG} \
|
|
||||||
${DELETEIMAGE}:arm32v7-${META_TAG} \
|
|
||||||
${DELETEIMAGE}:arm32v7-latest \
|
|
||||||
${DELETEIMAGE}:arm32v7-${EXT_RELEASE_TAG} \
|
|
||||||
${DELETEIMAGE}:arm64v8-${META_TAG} \
|
|
||||||
${DELETEIMAGE}:arm64v8-latest \
|
|
||||||
${DELETEIMAGE}:arm64v8-${EXT_RELEASE_TAG} || :
|
|
||||||
if [ -n "${SEMVER}" ]; then
|
|
||||||
docker rmi \
|
|
||||||
${DELETEIMAGE}:amd64-${SEMVER} \
|
|
||||||
${DELETEIMAGE}:arm32v7-${SEMVER} \
|
|
||||||
${DELETEIMAGE}:arm64v8-${SEMVER} || :
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
docker rmi \
|
|
||||||
ghcr.io/linuxserver/lsiodev-buildcache:arm32v7-${COMMIT_SHA}-${BUILD_NUMBER} \
|
|
||||||
ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER} || :
|
|
||||||
'''
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// If this is a public release tag it in the LS Github
|
// If this is a public release tag it in the LS Github
|
||||||
stage('Github-Tag-Push-Release') {
|
stage('Github-Tag-Push-Release') {
|
||||||
when {
|
when {
|
||||||
branch "main"
|
branch "develop"
|
||||||
expression {
|
expression {
|
||||||
env.LS_RELEASE != env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER
|
env.LS_RELEASE != env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER
|
||||||
}
|
}
|
||||||
@ -904,17 +844,17 @@ pipeline {
|
|||||||
sh '''curl -H "Authorization: token ${GITHUB_TOKEN}" -X POST https://api.github.com/repos/${LS_USER}/${LS_REPO}/git/tags \
|
sh '''curl -H "Authorization: token ${GITHUB_TOKEN}" -X POST https://api.github.com/repos/${LS_USER}/${LS_REPO}/git/tags \
|
||||||
-d '{"tag":"'${META_TAG}'",\
|
-d '{"tag":"'${META_TAG}'",\
|
||||||
"object": "'${COMMIT_SHA}'",\
|
"object": "'${COMMIT_SHA}'",\
|
||||||
"message": "Tagging Release '${EXT_RELEASE_CLEAN}'-ls'${LS_TAG_NUMBER}' to main",\
|
"message": "Tagging Release '${EXT_RELEASE_CLEAN}'-ls'${LS_TAG_NUMBER}' to develop",\
|
||||||
"type": "commit",\
|
"type": "commit",\
|
||||||
"tagger": {"name": "LinuxServer Jenkins","email": "jenkins@linuxserver.io","date": "'${GITHUB_DATE}'"}}' '''
|
"tagger": {"name": "LinuxServer Jenkins","email": "jenkins@linuxserver.io","date": "'${GITHUB_DATE}'"}}' '''
|
||||||
echo "Pushing New release for Tag"
|
echo "Pushing New release for Tag"
|
||||||
sh '''#! /bin/bash
|
sh '''#! /bin/bash
|
||||||
echo "Updating PIP version of ${EXT_PIP} to ${EXT_RELEASE_CLEAN}" > releasebody.json
|
curl -H "Authorization: token ${GITHUB_TOKEN}" -s https://api.github.com/repos/${EXT_USER}/${EXT_REPO}/commits/${EXT_RELEASE_CLEAN} | jq '.commit.message' | sed 's:^.\\(.*\\).$:\\1:' > releasebody.json
|
||||||
echo '{"tag_name":"'${META_TAG}'",\
|
echo '{"tag_name":"'${META_TAG}'",\
|
||||||
"target_commitish": "main",\
|
"target_commitish": "develop",\
|
||||||
"name": "'${META_TAG}'",\
|
"name": "'${META_TAG}'",\
|
||||||
"body": "**LinuxServer Changes:**\\n\\n'${LS_RELEASE_NOTES}'\\n\\n**PIP Changes:**\\n\\n' > start
|
"body": "**LinuxServer Changes:**\\n\\n'${LS_RELEASE_NOTES}'\\n\\n**'${EXT_REPO}' Changes:**\\n\\n' > start
|
||||||
printf '","draft": false,"prerelease": false}' >> releasebody.json
|
printf '","draft": false,"prerelease": true}' >> releasebody.json
|
||||||
paste -d'\\0' start releasebody.json > releasebody.json.done
|
paste -d'\\0' start releasebody.json > releasebody.json.done
|
||||||
curl -H "Authorization: token ${GITHUB_TOKEN}" -X POST https://api.github.com/repos/${LS_USER}/${LS_REPO}/releases -d @releasebody.json.done'''
|
curl -H "Authorization: token ${GITHUB_TOKEN}" -X POST https://api.github.com/repos/${LS_USER}/${LS_REPO}/releases -d @releasebody.json.done'''
|
||||||
}
|
}
|
||||||
@ -956,12 +896,78 @@ pipeline {
|
|||||||
stage('Pull Request Comment') {
|
stage('Pull Request Comment') {
|
||||||
when {
|
when {
|
||||||
not {environment name: 'CHANGE_ID', value: ''}
|
not {environment name: 'CHANGE_ID', value: ''}
|
||||||
environment name: 'CI', value: 'true'
|
|
||||||
environment name: 'EXIT_STATUS', value: ''
|
environment name: 'EXIT_STATUS', value: ''
|
||||||
}
|
}
|
||||||
steps {
|
steps {
|
||||||
sh '''curl -H "Authorization: token ${GITHUB_TOKEN}" -X POST https://api.github.com/repos/${LS_USER}/${LS_REPO}/issues/${PULL_REQUEST}/comments \
|
sh '''#! /bin/bash
|
||||||
-d '{"body": "I am a bot, here are the test results for this PR: \\n'${CI_URL}' \\n'${SHELLCHECK_URL}'"}' '''
|
# Function to retrieve JSON data from URL
|
||||||
|
get_json() {
|
||||||
|
local url="$1"
|
||||||
|
local response=$(curl -s "$url")
|
||||||
|
if [ $? -ne 0 ]; then
|
||||||
|
echo "Failed to retrieve JSON data from $url"
|
||||||
|
return 1
|
||||||
|
fi
|
||||||
|
local json=$(echo "$response" | jq .)
|
||||||
|
if [ $? -ne 0 ]; then
|
||||||
|
echo "Failed to parse JSON data from $url"
|
||||||
|
return 1
|
||||||
|
fi
|
||||||
|
echo "$json"
|
||||||
|
}
|
||||||
|
|
||||||
|
build_table() {
|
||||||
|
local data="$1"
|
||||||
|
|
||||||
|
# Get the keys in the JSON data
|
||||||
|
local keys=$(echo "$data" | jq -r 'to_entries | map(.key) | .[]')
|
||||||
|
|
||||||
|
# Check if keys are empty
|
||||||
|
if [ -z "$keys" ]; then
|
||||||
|
echo "JSON report data does not contain any keys or the report does not exist."
|
||||||
|
return 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Build table header
|
||||||
|
local header="| Tag | Passed |\\n| --- | --- |\\n"
|
||||||
|
|
||||||
|
# Loop through the JSON data to build the table rows
|
||||||
|
local rows=""
|
||||||
|
for build in $keys; do
|
||||||
|
local status=$(echo "$data" | jq -r ".[\\"$build\\"].test_success")
|
||||||
|
if [ "$status" = "true" ]; then
|
||||||
|
status="✅"
|
||||||
|
else
|
||||||
|
status="❌"
|
||||||
|
fi
|
||||||
|
local row="| "$build" | "$status" |\\n"
|
||||||
|
rows="${rows}${row}"
|
||||||
|
done
|
||||||
|
|
||||||
|
local table="${header}${rows}"
|
||||||
|
local escaped_table=$(echo "$table" | sed 's/\"/\\\\"/g')
|
||||||
|
echo "$escaped_table"
|
||||||
|
}
|
||||||
|
|
||||||
|
if [[ "${CI}" = "true" ]]; then
|
||||||
|
# Retrieve JSON data from URL
|
||||||
|
data=$(get_json "$CI_JSON_URL")
|
||||||
|
# Create table from JSON data
|
||||||
|
table=$(build_table "$data")
|
||||||
|
echo -e "$table"
|
||||||
|
|
||||||
|
curl -X POST -H "Authorization: token $GITHUB_TOKEN" \
|
||||||
|
-H "Accept: application/vnd.github.v3+json" \
|
||||||
|
"https://api.github.com/repos/$LS_USER/$LS_REPO/issues/$PULL_REQUEST/comments" \
|
||||||
|
-d "{\\"body\\": \\"I am a bot, here are the test results for this PR: \\n${CI_URL}\\n${SHELLCHECK_URL}\\n${table}\\"}"
|
||||||
|
else
|
||||||
|
curl -X POST -H "Authorization: token $GITHUB_TOKEN" \
|
||||||
|
-H "Accept: application/vnd.github.v3+json" \
|
||||||
|
"https://api.github.com/repos/$LS_USER/$LS_REPO/issues/$PULL_REQUEST/comments" \
|
||||||
|
-d "{\\"body\\": \\"I am a bot, here is the pushed image/manifest for this PR: \\n\\n\\`${GITHUBIMAGE}:${META_TAG}\\`\\"}"
|
||||||
|
fi
|
||||||
|
'''
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -975,18 +981,26 @@ pipeline {
|
|||||||
sh 'echo "build aborted"'
|
sh 'echo "build aborted"'
|
||||||
}
|
}
|
||||||
else if (currentBuild.currentResult == "SUCCESS"){
|
else if (currentBuild.currentResult == "SUCCESS"){
|
||||||
sh ''' curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://wiki.jenkins-ci.org/download/attachments/2916393/headshot.png","embeds": [{"color": 1681177,\
|
sh ''' curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://raw.githubusercontent.com/linuxserver/docker-templates/master/linuxserver.io/img/jenkins-avatar.png","embeds": [{"color": 1681177,\
|
||||||
"description": "**Build:** '${BUILD_NUMBER}'\\n**CI Results:** '${CI_URL}'\\n**ShellCheck Results:** '${SHELLCHECK_URL}'\\n**Status:** Success\\n**Job:** '${RUN_DISPLAY_URL}'\\n**Change:** '${CODE_URL}'\\n**External Release:**: '${RELEASE_LINK}'\\n**DockerHub:** '${DOCKERHUB_LINK}'\\n"}],\
|
"description": "**Build:** '${BUILD_NUMBER}'\\n**CI Results:** '${CI_URL}'\\n**ShellCheck Results:** '${SHELLCHECK_URL}'\\n**Status:** Success\\n**Job:** '${RUN_DISPLAY_URL}'\\n**Change:** '${CODE_URL}'\\n**External Release:**: '${RELEASE_LINK}'\\n**DockerHub:** '${DOCKERHUB_LINK}'\\n"}],\
|
||||||
"username": "Jenkins"}' ${BUILDS_DISCORD} '''
|
"username": "Jenkins"}' ${BUILDS_DISCORD} '''
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
sh ''' curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://wiki.jenkins-ci.org/download/attachments/2916393/headshot.png","embeds": [{"color": 16711680,\
|
sh ''' curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://raw.githubusercontent.com/linuxserver/docker-templates/master/linuxserver.io/img/jenkins-avatar.png","embeds": [{"color": 16711680,\
|
||||||
"description": "**Build:** '${BUILD_NUMBER}'\\n**CI Results:** '${CI_URL}'\\n**ShellCheck Results:** '${SHELLCHECK_URL}'\\n**Status:** failure\\n**Job:** '${RUN_DISPLAY_URL}'\\n**Change:** '${CODE_URL}'\\n**External Release:**: '${RELEASE_LINK}'\\n**DockerHub:** '${DOCKERHUB_LINK}'\\n"}],\
|
"description": "**Build:** '${BUILD_NUMBER}'\\n**CI Results:** '${CI_URL}'\\n**ShellCheck Results:** '${SHELLCHECK_URL}'\\n**Status:** failure\\n**Job:** '${RUN_DISPLAY_URL}'\\n**Change:** '${CODE_URL}'\\n**External Release:**: '${RELEASE_LINK}'\\n**DockerHub:** '${DOCKERHUB_LINK}'\\n"}],\
|
||||||
"username": "Jenkins"}' ${BUILDS_DISCORD} '''
|
"username": "Jenkins"}' ${BUILDS_DISCORD} '''
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
cleanup {
|
cleanup {
|
||||||
|
sh '''#! /bin/bash
|
||||||
|
echo "Performing docker system prune!!"
|
||||||
|
containers=$(docker ps -aq)
|
||||||
|
if [[ -n "${containers}" ]]; then
|
||||||
|
docker stop ${containers}
|
||||||
|
fi
|
||||||
|
docker system prune -af --volumes || :
|
||||||
|
'''
|
||||||
cleanWs()
|
cleanWs()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
55
README.md
55
README.md
@ -1,5 +1,5 @@
|
|||||||
<!-- DO NOT EDIT THIS FILE MANUALLY -->
|
<!-- DO NOT EDIT THIS FILE MANUALLY -->
|
||||||
<!-- Please read the https://github.com/linuxserver/docker-pyload-ng/blob/main/.github/CONTRIBUTING.md -->
|
<!-- Please read the https://github.com/linuxserver/docker-pyload-ng/blob/develop/.github/CONTRIBUTING.md -->
|
||||||
|
|
||||||
[](https://linuxserver.io)
|
[](https://linuxserver.io)
|
||||||
|
|
||||||
@ -37,7 +37,7 @@ Find us at:
|
|||||||
[](https://quay.io/repository/linuxserver.io/pyload-ng)
|
[](https://quay.io/repository/linuxserver.io/pyload-ng)
|
||||||
[](https://hub.docker.com/r/linuxserver/pyload-ng)
|
[](https://hub.docker.com/r/linuxserver/pyload-ng)
|
||||||
[](https://hub.docker.com/r/linuxserver/pyload-ng)
|
[](https://hub.docker.com/r/linuxserver/pyload-ng)
|
||||||
[](https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-pyload-ng/job/main/)
|
[](https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-pyload-ng/job/develop/)
|
||||||
[](https://ci-tests.linuxserver.io/linuxserver/pyload-ng/latest/index.html)
|
[](https://ci-tests.linuxserver.io/linuxserver/pyload-ng/latest/index.html)
|
||||||
|
|
||||||
[pyLoad](https://pyload.net/) is a Free and Open Source download manager written in Python and designed to be extremely lightweight, easily extensible and fully manageable via web.
|
[pyLoad](https://pyload.net/) is a Free and Open Source download manager written in Python and designed to be extremely lightweight, easily extensible and fully manageable via web.
|
||||||
@ -46,27 +46,26 @@ Find us at:
|
|||||||
|
|
||||||
## Supported Architectures
|
## 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://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/).
|
||||||
|
|
||||||
Simply pulling `lscr.io/linuxserver/pyload-ng` should retrieve the correct image for your arch, but you can also pull specific arch images via tags.
|
Simply pulling `lscr.io/linuxserver/pyload-ng:develop` 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:
|
The architectures supported by this image are:
|
||||||
|
|
||||||
| Architecture | Tag |
|
| Architecture | Available | Tag |
|
||||||
| :----: | --- |
|
| :----: | :----: | ---- |
|
||||||
| x86-64 | amd64-latest |
|
| x86-64 | ✅ | amd64-\<version tag\> |
|
||||||
| arm64 | arm64v8-latest |
|
| arm64 | ✅ | arm64v8-\<version tag\> |
|
||||||
| armhf | arm32v7-latest |
|
| armhf | ❌ | |
|
||||||
|
|
||||||
## Version Tags
|
## Version Tags
|
||||||
|
|
||||||
This image provides various versions that are available via tags. `latest` tag usually provides the latest stable version. Others are considered under development and caution must be exercised when using them.
|
This image provides various versions that are available via tags. Please read the descriptions carefully and exercise caution when using unstable or development tags.
|
||||||
|
|
||||||
| Tag | Description |
|
|
||||||
| :----: | --- |
|
|
||||||
| latest | Stable releases from pyLoad Next |
|
|
||||||
| development | Releases from pyload Next development branch |
|
|
||||||
|
|
||||||
|
| Tag | Available | Description |
|
||||||
|
| :----: | :----: |--- |
|
||||||
|
| latest | ✅ | Stable releases from pyLoad Next |
|
||||||
|
| develop | ✅ | Releases from pyload Next develop branch |
|
||||||
## Application Setup
|
## Application Setup
|
||||||
|
|
||||||
Access the web interface at `http://your-ip:8000` the default login is:
|
Access the web interface at `http://your-ip:8000` the default login is:
|
||||||
@ -86,17 +85,18 @@ Here are some example snippets to help you get started creating a container.
|
|||||||
version: "2.1"
|
version: "2.1"
|
||||||
services:
|
services:
|
||||||
pyload-ng:
|
pyload-ng:
|
||||||
image: lscr.io/linuxserver/pyload-ng
|
image: lscr.io/linuxserver/pyload-ng:develop
|
||||||
container_name: pyload-ng
|
container_name: pyload-ng
|
||||||
environment:
|
environment:
|
||||||
- PUID=1000
|
- PUID=1000
|
||||||
- PGID=1000
|
- PGID=1000
|
||||||
- TZ=Europe/London
|
- TZ=Etc/UTC
|
||||||
volumes:
|
volumes:
|
||||||
- /path/to/appdata/config:/config
|
- /path/to/appdata/config:/config
|
||||||
- /path/to/downloads:/downloads
|
- /path/to/downloads:/downloads
|
||||||
ports:
|
ports:
|
||||||
- 8000:8000
|
- 8000:8000
|
||||||
|
- 9666:9666 #optional
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -107,12 +107,14 @@ docker run -d \
|
|||||||
--name=pyload-ng \
|
--name=pyload-ng \
|
||||||
-e PUID=1000 \
|
-e PUID=1000 \
|
||||||
-e PGID=1000 \
|
-e PGID=1000 \
|
||||||
-e TZ=Europe/London \
|
-e TZ=Etc/UTC \
|
||||||
-p 8000:8000 \
|
-p 8000:8000 \
|
||||||
|
-p 9666:9666 `#optional` \
|
||||||
-v /path/to/appdata/config:/config \
|
-v /path/to/appdata/config:/config \
|
||||||
-v /path/to/downloads:/downloads \
|
-v /path/to/downloads:/downloads \
|
||||||
--restart unless-stopped \
|
--restart unless-stopped \
|
||||||
lscr.io/linuxserver/pyload-ng
|
lscr.io/linuxserver/pyload-ng:develop
|
||||||
|
|
||||||
```
|
```
|
||||||
|
|
||||||
## Parameters
|
## Parameters
|
||||||
@ -122,9 +124,10 @@ Container images are configured using parameters passed at runtime (such as thos
|
|||||||
| Parameter | Function |
|
| Parameter | Function |
|
||||||
| :----: | --- |
|
| :----: | --- |
|
||||||
| `-p 8000` | Allows HTTP access to the application |
|
| `-p 8000` | Allows HTTP access to the application |
|
||||||
|
| `-p 9666` | Click'n'Load port. |
|
||||||
| `-e PUID=1000` | for UserID - see below for explanation |
|
| `-e PUID=1000` | for UserID - see below for explanation |
|
||||||
| `-e PGID=1000` | for GroupID - 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). |
|
||||||
| `-v /config` | pyLoad Configuration and files database |
|
| `-v /config` | pyLoad Configuration and files database |
|
||||||
| `-v /downloads` | Destination of pyLoad downloads |
|
| `-v /downloads` | Destination of pyLoad downloads |
|
||||||
|
|
||||||
@ -171,7 +174,7 @@ We publish various [Docker Mods](https://github.com/linuxserver/docker-mods) to
|
|||||||
* container version number
|
* container version number
|
||||||
* `docker inspect -f '{{ index .Config.Labels "build_version" }}' pyload-ng`
|
* `docker inspect -f '{{ index .Config.Labels "build_version" }}' pyload-ng`
|
||||||
* image version number
|
* image version number
|
||||||
* `docker inspect -f '{{ index .Config.Labels "build_version" }}' lscr.io/linuxserver/pyload-ng`
|
* `docker inspect -f '{{ index .Config.Labels "build_version" }}' lscr.io/linuxserver/pyload-ng:develop`
|
||||||
|
|
||||||
## Updating Info
|
## Updating Info
|
||||||
|
|
||||||
@ -189,7 +192,7 @@ Below are the instructions for updating containers:
|
|||||||
|
|
||||||
### Via Docker Run
|
### Via Docker Run
|
||||||
|
|
||||||
* Update the image: `docker pull lscr.io/linuxserver/pyload-ng`
|
* Update the image: `docker pull lscr.io/linuxserver/pyload-ng:develop`
|
||||||
* Stop the running container: `docker stop pyload-ng`
|
* Stop the running container: `docker stop pyload-ng`
|
||||||
* Delete the container: `docker rm pyload-ng`
|
* Delete the container: `docker rm pyload-ng`
|
||||||
* 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)
|
* 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)
|
||||||
@ -224,7 +227,7 @@ cd docker-pyload-ng
|
|||||||
docker build \
|
docker build \
|
||||||
--no-cache \
|
--no-cache \
|
||||||
--pull \
|
--pull \
|
||||||
-t lscr.io/linuxserver/pyload-ng:latest .
|
-t lscr.io/linuxserver/pyload-ng:develop .
|
||||||
```
|
```
|
||||||
|
|
||||||
The ARM variants can be built on x86_64 hardware using `multiarch/qemu-user-static`
|
The ARM variants can be built on x86_64 hardware using `multiarch/qemu-user-static`
|
||||||
@ -237,4 +240,10 @@ Once registered you can define the dockerfile to use with `-f Dockerfile.aarch64
|
|||||||
|
|
||||||
## Versions
|
## Versions
|
||||||
|
|
||||||
|
* **10.08.23:** - Bump unrar to 6.2.10.
|
||||||
|
* **01.06.23:** - Replace p7zip with 7zip, add unrar.
|
||||||
|
* **25.05.23:** - Rebase to Alpine 3.18, deprecate armhf.
|
||||||
|
* **02.02.22:** - Rebase develop to alpine 3.17.
|
||||||
|
* **02.02.22:** - Add ffmpeg for the Youtube plugin.
|
||||||
|
* **24.01.22:** - Replace unrar with p7zip.
|
||||||
* **24.01.22:** - Initial release.
|
* **24.01.22:** - Initial release.
|
||||||
|
|||||||
@ -2,19 +2,22 @@
|
|||||||
|
|
||||||
# jenkins variables
|
# jenkins variables
|
||||||
project_name: docker-pyload-ng
|
project_name: docker-pyload-ng
|
||||||
external_type: pip_version
|
external_type: github_commit
|
||||||
release_type: stable
|
release_type: prerelease
|
||||||
release_tag: latest
|
release_tag: develop
|
||||||
ls_branch: main
|
ls_branch: develop
|
||||||
|
build_armhf: false
|
||||||
repo_vars:
|
repo_vars:
|
||||||
- EXT_PIP = 'pyload-ng'
|
- EXT_GIT_BRANCH = 'develop'
|
||||||
- BUILD_VERSION_ARG = 'PYLOAD_VERSION'
|
- EXT_USER = 'pyload'
|
||||||
|
- EXT_REPO = 'pyload'
|
||||||
|
- BUILD_VERSION_ARG = 'PYLOAD_COMMIT'
|
||||||
- LS_USER = 'linuxserver'
|
- LS_USER = 'linuxserver'
|
||||||
- LS_REPO = 'docker-pyload'
|
- LS_REPO = 'docker-pyload-ng'
|
||||||
- CONTAINER_NAME = 'pyload'
|
- CONTAINER_NAME = 'pyload-ng'
|
||||||
- DOCKERHUB_IMAGE = 'linuxserver/pyload'
|
- DOCKERHUB_IMAGE = 'linuxserver/pyload-ng'
|
||||||
- DEV_DOCKERHUB_IMAGE = 'lsiodev/pyload'
|
- DEV_DOCKERHUB_IMAGE = 'lsiodev/pyload-ng'
|
||||||
- PR_DOCKERHUB_IMAGE = 'lspipepr/pyload'
|
- PR_DOCKERHUB_IMAGE = 'lspipepr/pyload-ng'
|
||||||
- DIST_IMAGE = 'alpine'
|
- DIST_IMAGE = 'alpine'
|
||||||
- MULTIARCH='true'
|
- MULTIARCH='true'
|
||||||
- CI='true'
|
- CI='true'
|
||||||
@ -25,3 +28,5 @@ repo_vars:
|
|||||||
- CI_DOCKERENV='TZ=US/Pacific'
|
- CI_DOCKERENV='TZ=US/Pacific'
|
||||||
- CI_AUTH='user:password'
|
- CI_AUTH='user:password'
|
||||||
- CI_WEBPATH=''
|
- CI_WEBPATH=''
|
||||||
|
sponsor_links:
|
||||||
|
- { name: "pyLoad", url: "https://PayPal.Me/nitzo2001/0usd" }
|
||||||
|
|||||||
197
package_versions.txt
Executable file
197
package_versions.txt
Executable file
@ -0,0 +1,197 @@
|
|||||||
|
NAME VERSION TYPE
|
||||||
|
7zip 22.01-r5 apk
|
||||||
|
Babel 2.12.1 python
|
||||||
|
Brotli 1.1.0 python
|
||||||
|
Flask 2.3.3 python
|
||||||
|
Flask-Babel 1.0.0 python
|
||||||
|
Flask-Caching 1.11.1 python
|
||||||
|
Flask-Compress 1.13 python
|
||||||
|
Flask-Themes2 1.0.0 python
|
||||||
|
Jinja2 3.1.2 python
|
||||||
|
Js2Py 0.74 python
|
||||||
|
MarkupSafe 2.1.3 python
|
||||||
|
Simple Launcher Executable 1.1.0.14 dotnet
|
||||||
|
Werkzeug 2.3.7 python
|
||||||
|
alpine-baselayout 3.4.3-r1 apk
|
||||||
|
alpine-baselayout-data 3.4.3-r1 apk
|
||||||
|
alpine-keys 2.4-r1 apk
|
||||||
|
alpine-release 3.18.3-r0 apk
|
||||||
|
alsa-lib 1.2.9-r1 apk
|
||||||
|
aom-libs 3.6.1-r0 apk
|
||||||
|
apk-tools 2.14.0-r2 apk
|
||||||
|
bash 5.2.15-r5 apk
|
||||||
|
bitmath 1.3.3.1 python
|
||||||
|
blinker 1.6.2 python
|
||||||
|
brotli-libs 1.0.9-r14 apk
|
||||||
|
busybox 1.36.1-r2 apk
|
||||||
|
busybox-binsh 1.36.1-r2 apk
|
||||||
|
ca-certificates 20230506-r0 apk
|
||||||
|
ca-certificates-bundle 20230506-r0 apk
|
||||||
|
cachelib 0.9.0 python
|
||||||
|
cairo 1.17.8-r1 apk
|
||||||
|
certifi 2023.7.22 python
|
||||||
|
cffi 1.15.1 python
|
||||||
|
cheroot 8.6.0 python
|
||||||
|
cjson 1.7.15-r4 apk
|
||||||
|
click 8.1.7 python
|
||||||
|
coreutils 9.3-r1 apk
|
||||||
|
cryptography 41.0.3 python
|
||||||
|
curl 8.2.1-r0 apk
|
||||||
|
dbus-libs 1.14.8-r0 apk
|
||||||
|
ffmpeg 6.0-r15 apk
|
||||||
|
ffmpeg-libavcodec 6.0-r15 apk
|
||||||
|
ffmpeg-libavdevice 6.0-r15 apk
|
||||||
|
ffmpeg-libavfilter 6.0-r15 apk
|
||||||
|
ffmpeg-libavformat 6.0-r15 apk
|
||||||
|
ffmpeg-libavutil 6.0-r15 apk
|
||||||
|
ffmpeg-libpostproc 6.0-r15 apk
|
||||||
|
ffmpeg-libswresample 6.0-r15 apk
|
||||||
|
ffmpeg-libswscale 6.0-r15 apk
|
||||||
|
filetype 1.2.0 python
|
||||||
|
flac-libs 1.4.3-r0 apk
|
||||||
|
flask-session2 1.3.1 python
|
||||||
|
fontconfig 2.14.2-r3 apk
|
||||||
|
freetype 2.13.0-r5 apk
|
||||||
|
fribidi 1.0.13-r0 apk
|
||||||
|
gdbm 1.23-r1 apk
|
||||||
|
giflib 5.2.1-r4 apk
|
||||||
|
glib 2.76.4-r0 apk
|
||||||
|
glslang-libs 1.3.243.0-r1 apk
|
||||||
|
gmp 6.2.1-r3 apk
|
||||||
|
gnutls 3.8.0-r2 apk
|
||||||
|
graphite2 1.3.14-r5 apk
|
||||||
|
harfbuzz 7.3.0-r0 apk
|
||||||
|
hwdata-pci 0.370-r0 apk
|
||||||
|
icu-data-en 73.2-r2 apk
|
||||||
|
icu-libs 73.2-r2 apk
|
||||||
|
itsdangerous 2.1.2 python
|
||||||
|
jaraco.functools 3.9.0 python
|
||||||
|
jq 1.6-r3 apk
|
||||||
|
lame-libs 3.100-r5 apk
|
||||||
|
lcms2 2.15-r2 apk
|
||||||
|
leptonica 1.83.1-r0 apk
|
||||||
|
libacl 2.3.1-r3 apk
|
||||||
|
libass 0.17.1-r0 apk
|
||||||
|
libasyncns 0.8-r1 apk
|
||||||
|
libattr 2.5.1-r4 apk
|
||||||
|
libblkid 2.38.1-r8 apk
|
||||||
|
libbluray 1.3.4-r0 apk
|
||||||
|
libbsd 0.11.7-r1 apk
|
||||||
|
libbz2 1.0.8-r5 apk
|
||||||
|
libc-utils 0.7.2-r5 apk
|
||||||
|
libcrypto3 3.1.2-r0 apk
|
||||||
|
libcurl 8.2.1-r0 apk
|
||||||
|
libdav1d 1.2.1-r0 apk
|
||||||
|
libdrm 2.4.115-r4 apk
|
||||||
|
libexpat 2.5.0-r1 apk
|
||||||
|
libffi 3.4.4-r2 apk
|
||||||
|
libgcc 12.2.1_git20220924-r10 apk
|
||||||
|
libgomp 12.2.1_git20220924-r10 apk
|
||||||
|
libhwy 1.0.4-r1 apk
|
||||||
|
libidn2 2.3.4-r1 apk
|
||||||
|
libintl 0.21.1-r7 apk
|
||||||
|
libjpeg-turbo 2.1.5.1-r3 apk
|
||||||
|
libjxl 0.8.2-r0 apk
|
||||||
|
libltdl 2.4.7-r2 apk
|
||||||
|
libmd 1.0.4-r2 apk
|
||||||
|
libmount 2.38.1-r8 apk
|
||||||
|
libncursesw 6.4_p20230506-r0 apk
|
||||||
|
libogg 1.3.5-r4 apk
|
||||||
|
libopenmpt 0.7.2-r0 apk
|
||||||
|
libpanelw 6.4_p20230506-r0 apk
|
||||||
|
libpciaccess 0.17-r2 apk
|
||||||
|
libplacebo 5.264.1-r1 apk
|
||||||
|
libpng 1.6.39-r3 apk
|
||||||
|
libproc2 4.0.4-r0 apk
|
||||||
|
libpulse 16.1-r10 apk
|
||||||
|
librist 0.2.7-r0 apk
|
||||||
|
libsndfile 1.2.0-r2 apk
|
||||||
|
libsodium 1.0.18-r3 apk
|
||||||
|
libsrt 1.5.2-r0 apk
|
||||||
|
libssh 0.10.5-r0 apk
|
||||||
|
libssl3 3.1.2-r0 apk
|
||||||
|
libstdc++ 12.2.1_git20220924-r10 apk
|
||||||
|
libtasn1 4.19.0-r1 apk
|
||||||
|
libtheora 1.1.1-r17 apk
|
||||||
|
libunibreak 5.1-r0 apk
|
||||||
|
libunistring 1.1-r1 apk
|
||||||
|
libva 2.18.0-r1 apk
|
||||||
|
libvdpau 1.5-r1 apk
|
||||||
|
libvorbis 1.3.7-r1 apk
|
||||||
|
libvpx 1.13.0-r1 apk
|
||||||
|
libwebp 1.3.1-r0 apk
|
||||||
|
libx11 1.8.4-r4 apk
|
||||||
|
libxau 1.0.11-r2 apk
|
||||||
|
libxcb 1.15-r1 apk
|
||||||
|
libxdmcp 1.1.4-r2 apk
|
||||||
|
libxext 1.3.5-r2 apk
|
||||||
|
libxfixes 6.0.1-r2 apk
|
||||||
|
libxft 2.3.8-r1 apk
|
||||||
|
libxml2 2.11.4-r0 apk
|
||||||
|
libxrender 0.9.11-r3 apk
|
||||||
|
libzmq 4.3.4-r4 apk
|
||||||
|
linux-pam 1.5.2-r10 apk
|
||||||
|
mbedtls 2.28.4-r0 apk
|
||||||
|
more-itertools 10.1.0 python
|
||||||
|
mpdecimal 2.5.1-r2 apk
|
||||||
|
mpg123-libs 1.31.3-r1 apk
|
||||||
|
musl 1.2.4-r1 apk
|
||||||
|
musl-utils 1.2.4-r1 apk
|
||||||
|
ncurses-terminfo-base 6.4_p20230506-r0 apk
|
||||||
|
netcat-openbsd 1.219-r1 apk
|
||||||
|
nettle 3.8.1-r2 apk
|
||||||
|
nghttp2-libs 1.55.1-r0 apk
|
||||||
|
numactl 2.0.16-r4 apk
|
||||||
|
onevpl-libs 2023.2.1-r0 apk
|
||||||
|
oniguruma 6.9.8-r1 apk
|
||||||
|
opus 1.4-r0 apk
|
||||||
|
orc 0.4.34-r0 apk
|
||||||
|
p11-kit 0.24.1-r2 apk
|
||||||
|
pango 1.50.14-r1 apk
|
||||||
|
pcre2 10.42-r1 apk
|
||||||
|
pip 23.2.1 python
|
||||||
|
pixman 0.42.2-r1 apk
|
||||||
|
procps-ng 4.0.4-r0 apk
|
||||||
|
pyc 0.1-r0 apk
|
||||||
|
pycparser 2.21 python
|
||||||
|
pycurl 7.45.2 python
|
||||||
|
pyjsparser 2.7.1 python
|
||||||
|
pyload-ng 0.5.0b3 python
|
||||||
|
python3 3.11.5-r0 apk
|
||||||
|
python3-pyc 3.11.5-r0 apk
|
||||||
|
python3-pycache-pyc0 3.11.5-r0 apk
|
||||||
|
pytz 2022.7.1 python
|
||||||
|
readline 8.2.1-r1 apk
|
||||||
|
scanelf 1.3.7-r1 apk
|
||||||
|
sdl2 2.26.5-r0 apk
|
||||||
|
semver 2.13.0 python
|
||||||
|
setuptools 65.5.0 python
|
||||||
|
shaderc 2023.3-r1 apk
|
||||||
|
shadow 4.13-r4 apk
|
||||||
|
six 1.16.0 python
|
||||||
|
skalibs 2.13.1.1-r1 apk
|
||||||
|
soxr 0.1.3-r5 apk
|
||||||
|
speexdsp 1.2.1-r1 apk
|
||||||
|
spirv-tools 1.3.243.0-r1 apk
|
||||||
|
sqlite 3.41.2-r2 apk
|
||||||
|
sqlite-libs 3.41.2-r2 apk
|
||||||
|
ssl_client 1.36.1-r2 apk
|
||||||
|
svt-av1-libs 1.6.0-r0 apk
|
||||||
|
tdb-libs 1.4.8-r1 apk
|
||||||
|
tesseract-ocr 5.3.2-r0 apk
|
||||||
|
tiff 4.5.1-r0 apk
|
||||||
|
tzdata 2023c-r1 apk
|
||||||
|
tzlocal 5.0.1 python
|
||||||
|
utmps-libs 0.1.2.1-r1 apk
|
||||||
|
v4l-utils-libs 1.24.1-r0 apk
|
||||||
|
vidstab 1.1.1-r0 apk
|
||||||
|
vulkan-loader 1.3.243.0-r1 apk
|
||||||
|
wayland-libs-client 1.22.0-r2 apk
|
||||||
|
wheel 0.41.2 python
|
||||||
|
x264-libs 0.164_git20220602-r1 apk
|
||||||
|
x265-libs 3.5-r4 apk
|
||||||
|
xvidcore 1.3.7-r1 apk
|
||||||
|
xz-libs 5.4.3-r0 apk
|
||||||
|
zimg 3.0.5-r0 apk
|
||||||
|
zlib 1.2.13-r1 apk
|
||||||
|
zstd-libs 1.5.5-r4 apk
|
||||||
@ -11,13 +11,12 @@ project_lsio_github_repo_url: "https://github.com/linuxserver/docker-{{ project_
|
|||||||
available_architectures:
|
available_architectures:
|
||||||
- { arch: "{{ arch_x86_64 }}", tag: "amd64-latest"}
|
- { arch: "{{ arch_x86_64 }}", tag: "amd64-latest"}
|
||||||
- { arch: "{{ arch_arm64 }}", tag: "arm64v8-latest"}
|
- { arch: "{{ arch_arm64 }}", tag: "arm64v8-latest"}
|
||||||
- { arch: "{{ arch_armhf }}", tag: "arm32v7-latest"}
|
|
||||||
|
|
||||||
# development version
|
# development version
|
||||||
development_versions: true
|
development_versions: true
|
||||||
development_versions_items:
|
development_versions_items:
|
||||||
- { tag: "latest", desc: "Stable releases from pyLoad Next" }
|
- { tag: "latest", desc: "Stable releases from pyLoad Next" }
|
||||||
- { tag: "development", desc: "Releases from pyload Next development branch" }
|
- { tag: "develop", desc: "Releases from pyload Next develop branch" }
|
||||||
|
|
||||||
|
|
||||||
# container parameters
|
# container parameters
|
||||||
@ -34,9 +33,9 @@ param_env_vars:
|
|||||||
- { env_var: "TZ", env_value: "Europe/London", desc: "Specify a timezone to use EG Europe/London"}
|
- { env_var: "TZ", env_value: "Europe/London", desc: "Specify a timezone to use EG Europe/London"}
|
||||||
|
|
||||||
# optional params
|
# optional params
|
||||||
opt_param_usage_include_ports: false
|
opt_param_usage_include_ports: true
|
||||||
opt_param_ports:
|
opt_param_ports:
|
||||||
- { external_port: "7227", internal_port: "7227", port_desc: "pyLoad control port" }
|
- { external_port: "9666", internal_port: "9666", port_desc: "Click'n'Load port." }
|
||||||
|
|
||||||
|
|
||||||
# application setup block
|
# application setup block
|
||||||
@ -50,4 +49,10 @@ app_setup_block: |
|
|||||||
|
|
||||||
# changelog
|
# changelog
|
||||||
changelogs:
|
changelogs:
|
||||||
|
- {date: "10.08.23:", desc: "Bump unrar to 6.2.10."}
|
||||||
|
- { date: "01.06.23:", desc: "Replace p7zip with 7zip, add unrar." }
|
||||||
|
- { date: "25.05.23:", desc: "Rebase to Alpine 3.18, deprecate armhf." }
|
||||||
|
- { date: "02.02.22:", desc: "Rebase develop to alpine 3.17." }
|
||||||
|
- { date: "02.02.22:", desc: "Add ffmpeg for the Youtube plugin." }
|
||||||
|
- { date: "24.01.22:", desc: "Replace unrar with p7zip." }
|
||||||
- { date: "24.01.22:", desc: "Initial release." }
|
- { date: "24.01.22:", desc: "Initial release." }
|
||||||
|
|||||||
1
root/donate.txt
Normal file
1
root/donate.txt
Normal file
@ -0,0 +1 @@
|
|||||||
|
pyLoad: https://PayPal.Me/nitzo2001/0usd
|
||||||
@ -1,19 +0,0 @@
|
|||||||
#!/usr/bin/with-contenv bash
|
|
||||||
|
|
||||||
# create our folders
|
|
||||||
mkdir -p \
|
|
||||||
/config/settings \
|
|
||||||
/downloads
|
|
||||||
|
|
||||||
# default config file
|
|
||||||
[[ ! -f "/config/settings/pyload.cfg" ]] && \
|
|
||||||
cp \
|
|
||||||
/defaults/pyload.cfg \
|
|
||||||
/config/settings/pyload.cfg
|
|
||||||
|
|
||||||
# permissions
|
|
||||||
echo "[cont-init.d] Setting permissions this may take some time"
|
|
||||||
chown -R abc:abc \
|
|
||||||
/config
|
|
||||||
chown abc:abc \
|
|
||||||
/downloads
|
|
||||||
18
root/etc/s6-overlay/s6-rc.d/init-pyload-config/run
Executable file
18
root/etc/s6-overlay/s6-rc.d/init-pyload-config/run
Executable file
@ -0,0 +1,18 @@
|
|||||||
|
#!/usr/bin/with-contenv bash
|
||||||
|
# shellcheck shell=bash
|
||||||
|
|
||||||
|
# create our folders
|
||||||
|
mkdir -p \
|
||||||
|
/config/settings \
|
||||||
|
/downloads
|
||||||
|
|
||||||
|
# default config file
|
||||||
|
cp -n \
|
||||||
|
/defaults/pyload.cfg \
|
||||||
|
/config/settings/pyload.cfg
|
||||||
|
|
||||||
|
# permissions
|
||||||
|
lsiown -R abc:abc \
|
||||||
|
/config
|
||||||
|
lsiown abc:abc \
|
||||||
|
/downloads
|
||||||
1
root/etc/s6-overlay/s6-rc.d/init-pyload-config/type
Normal file
1
root/etc/s6-overlay/s6-rc.d/init-pyload-config/type
Normal file
@ -0,0 +1 @@
|
|||||||
|
oneshot
|
||||||
1
root/etc/s6-overlay/s6-rc.d/init-pyload-config/up
Normal file
1
root/etc/s6-overlay/s6-rc.d/init-pyload-config/up
Normal file
@ -0,0 +1 @@
|
|||||||
|
/etc/s6-overlay/s6-rc.d/init-pyload-config/run
|
||||||
1
root/etc/s6-overlay/s6-rc.d/svc-pyload/notification-fd
Normal file
1
root/etc/s6-overlay/s6-rc.d/svc-pyload/notification-fd
Normal file
@ -0,0 +1 @@
|
|||||||
|
3
|
||||||
8
root/etc/s6-overlay/s6-rc.d/svc-pyload/run
Executable file
8
root/etc/s6-overlay/s6-rc.d/svc-pyload/run
Executable file
@ -0,0 +1,8 @@
|
|||||||
|
#!/usr/bin/with-contenv bash
|
||||||
|
# shellcheck shell=bash
|
||||||
|
|
||||||
|
PORT=$(sed -n -e '/webui/,/proxy/p' /config/settings/pyload.cfg | grep "Port" | awk -F '=' '{print $2}' | tr -d ' ')
|
||||||
|
|
||||||
|
exec \
|
||||||
|
s6-notifyoncheck -d -n 300 -w 1000 -c "nc -z localhost ${PORT:-8000}" \
|
||||||
|
s6-setuidgid abc pyload --userdir /config --storagedir /downloads
|
||||||
1
root/etc/s6-overlay/s6-rc.d/svc-pyload/type
Normal file
1
root/etc/s6-overlay/s6-rc.d/svc-pyload/type
Normal file
@ -0,0 +1 @@
|
|||||||
|
longrun
|
||||||
@ -1,4 +0,0 @@
|
|||||||
#!/usr/bin/with-contenv bash
|
|
||||||
|
|
||||||
exec \
|
|
||||||
s6-setuidgid abc pyload --userdir /config --storagedir /downloads
|
|
||||||
Loading…
x
Reference in New Issue
Block a user