mirror of
https://github.com/linuxserver/docker-piper.git
synced 2026-03-16 00:01:56 +08:00
Compare commits
99 Commits
main
...
gpu-2.2.2-
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ba4e957cb7 | ||
|
|
574af606a2 | ||
|
|
f886cd5118 | ||
|
|
58dbc5b54d | ||
|
|
342d6b0eff | ||
|
|
e8c1d5c981 | ||
|
|
451370cf29 | ||
|
|
8098ae178c | ||
|
|
2cff42c787 | ||
|
|
2e0dfec0fc | ||
|
|
3cad6bd563 | ||
|
|
0da33ce54d | ||
|
|
307cf5cea2 | ||
|
|
e2750685b6 | ||
|
|
0eae962026 | ||
|
|
3974bc948a | ||
|
|
253406081b | ||
|
|
c8766c166d | ||
|
|
9b40470edd | ||
|
|
1f36c3c912 | ||
|
|
2d0b7a9a86 | ||
|
|
104e92c663 | ||
|
|
af03959202 | ||
|
|
1fe6921c01 | ||
|
|
9c7cbf984e | ||
|
|
f7af9920f0 | ||
|
|
c8d48122c9 | ||
|
|
723a492818 | ||
|
|
ca064adc26 | ||
|
|
66c8acf5a5 | ||
|
|
7d25e0ba6b | ||
|
|
02171be4e0 | ||
|
|
952ee8203c | ||
|
|
c2ced3b377 | ||
|
|
4931044daa | ||
|
|
49ab1cfd8f | ||
|
|
6456de8997 | ||
|
|
fcecff484b | ||
|
|
05ec62af53 | ||
|
|
229fa339a0 | ||
|
|
ec7746f332 | ||
|
|
b9b803ef75 | ||
|
|
4d9c0054c1 | ||
|
|
e7a2c97bb2 | ||
|
|
735881d767 | ||
|
|
9108162922 | ||
|
|
41fe0263e0 | ||
|
|
df167c4eac | ||
|
|
d3cac6640a | ||
|
|
09b6077538 | ||
|
|
db85c1d81f | ||
|
|
d3ae266e97 | ||
|
|
b21ff9466a | ||
|
|
ff3f73ed2d | ||
|
|
af5dafb5ba | ||
|
|
2f377ea0d2 | ||
|
|
5f3003cae1 | ||
|
|
a4edf313df | ||
|
|
4c7c4b1303 | ||
|
|
9ec3fddc39 | ||
|
|
f9b016e80b | ||
|
|
8df33136fe | ||
|
|
8e9ab74431 | ||
|
|
ba55cd45c3 | ||
|
|
47e3721360 | ||
|
|
a49272dbdb | ||
|
|
9e62f6118f | ||
|
|
fc03888b97 | ||
|
|
e71ef951ab | ||
|
|
e358cd9799 | ||
|
|
1e9d87a6d7 | ||
|
|
de52055928 | ||
|
|
68a1d81dfc | ||
|
|
bdfd81e766 | ||
|
|
1e08698cc7 | ||
|
|
fa36cf385a | ||
|
|
e552469b44 | ||
|
|
756a178628 | ||
|
|
77998fab3e | ||
|
|
bb4c6febac | ||
|
|
55da880819 | ||
|
|
ec3619e5ed | ||
|
|
52154d351e | ||
|
|
5aeea8937d | ||
|
|
4bc36f339a | ||
|
|
6145fcb052 | ||
|
|
6cab3b88a0 | ||
|
|
bafa4828c4 | ||
|
|
8f21e8c277 | ||
|
|
c66f8d48c2 | ||
|
|
8f75ce00c2 | ||
|
|
79d0c4f0c3 | ||
|
|
ae4853dde4 | ||
|
|
f5b09b1d2d | ||
|
|
d9a09878f4 | ||
|
|
77eb5f2342 | ||
|
|
5ce7d5cb75 | ||
|
|
220a224ee6 | ||
|
|
69d3d769e8 |
0
.editorconfig
Executable file → Normal file
0
.editorconfig
Executable file → Normal file
6
.github/CONTRIBUTING.md
vendored
6
.github/CONTRIBUTING.md
vendored
@ -6,7 +6,7 @@
|
|||||||
* Read, and fill the Pull Request template
|
* Read, and fill the Pull Request template
|
||||||
* If this is a fix for a typo (in code, documentation, or the README) please file an issue and let us sort it out. We do not need a PR
|
* If this is a fix for a typo (in code, documentation, or the README) please file an issue and let us sort it out. We do not need a PR
|
||||||
* If the PR is addressing an existing issue include, closes #\<issue number>, in the body of the PR commit message
|
* If the PR is addressing an existing issue include, closes #\<issue number>, in the body of the PR commit message
|
||||||
* If you want to discuss changes, you can also bring it up in [#dev-talk](https://discordapp.com/channels/354974912613449730/757585807061155840) in our [Discord server](https://discord.gg/YWrKVTn)
|
* If you want to discuss changes, you can also bring it up in [#dev-talk](https://discordapp.com/channels/354974912613449730/757585807061155840) in our [Discord server](https://linuxserver.io/discord)
|
||||||
|
|
||||||
## Common files
|
## Common files
|
||||||
|
|
||||||
@ -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-piper/edit/main/readme-vars.yml).
|
Instead edit the [readme-vars.yml](https://github.com/linuxserver/docker-piper/edit/gpu/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-piper)
|
Most of these variables are also carried over to [docs.linuxserver.io](https://docs.linuxserver.io/images/docker-piper)
|
||||||
@ -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-piper/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-piper/tree/gpu/root), add an entry to the changelog
|
||||||
|
|
||||||
```yml
|
```yml
|
||||||
changelogs:
|
changelogs:
|
||||||
|
|||||||
2
.github/ISSUE_TEMPLATE/config.yml
vendored
2
.github/ISSUE_TEMPLATE/config.yml
vendored
@ -1,7 +1,7 @@
|
|||||||
blank_issues_enabled: false
|
blank_issues_enabled: false
|
||||||
contact_links:
|
contact_links:
|
||||||
- name: Discord chat support
|
- name: Discord chat support
|
||||||
url: https://discord.gg/YWrKVTn
|
url: https://linuxserver.io/discord
|
||||||
about: Realtime support / chat with the community and the team.
|
about: Realtime support / chat with the community and the team.
|
||||||
|
|
||||||
- name: Discourse discussion forum
|
- name: Discourse discussion forum
|
||||||
|
|||||||
1
.github/ISSUE_TEMPLATE/issue.bug.yml
vendored
1
.github/ISSUE_TEMPLATE/issue.bug.yml
vendored
@ -52,7 +52,6 @@ body:
|
|||||||
label: CPU architecture
|
label: CPU architecture
|
||||||
options:
|
options:
|
||||||
- x86-64
|
- x86-64
|
||||||
- arm64
|
|
||||||
validations:
|
validations:
|
||||||
required: true
|
required: true
|
||||||
- type: textarea
|
- type: textarea
|
||||||
|
|||||||
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-piper/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-piper/blob/gpu/.github/CONTRIBUTING.md) guideline and understand that I have made the correct modifications
|
||||||
|
|
||||||
------------------------------
|
------------------------------
|
||||||
|
|
||||||
|
|||||||
3
.github/workflows/call_issue_pr_tracker.yml
vendored
3
.github/workflows/call_issue_pr_tracker.yml
vendored
@ -8,6 +8,9 @@ on:
|
|||||||
pull_request_review:
|
pull_request_review:
|
||||||
types: [submitted,edited,dismissed]
|
types: [submitted,edited,dismissed]
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
manage-project:
|
manage-project:
|
||||||
permissions:
|
permissions:
|
||||||
|
|||||||
3
.github/workflows/call_issues_cron.yml
vendored
3
.github/workflows/call_issues_cron.yml
vendored
@ -4,6 +4,9 @@ on:
|
|||||||
- cron: '34 23 * * *'
|
- cron: '34 23 * * *'
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
stale:
|
stale:
|
||||||
permissions:
|
permissions:
|
||||||
|
|||||||
82
.github/workflows/external_trigger.yml
vendored
82
.github/workflows/external_trigger.yml
vendored
@ -3,56 +3,86 @@ name: External Trigger Main
|
|||||||
on:
|
on:
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
external-trigger-main:
|
external-trigger-gpu:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4.1.1
|
- uses: actions/checkout@v4.1.1
|
||||||
|
|
||||||
- name: External Trigger
|
- name: External Trigger
|
||||||
if: github.ref == 'refs/heads/main'
|
if: github.ref == 'refs/heads/gpu'
|
||||||
env:
|
env:
|
||||||
SKIP_EXTERNAL_TRIGGER: ${{ vars.SKIP_EXTERNAL_TRIGGER }}
|
SKIP_EXTERNAL_TRIGGER: ${{ vars.SKIP_EXTERNAL_TRIGGER }}
|
||||||
run: |
|
run: |
|
||||||
printf "# External trigger for docker-piper\n\n" >> $GITHUB_STEP_SUMMARY
|
printf "# External trigger for docker-piper\n\n" >> $GITHUB_STEP_SUMMARY
|
||||||
if grep -q "^piper_main" <<< "${SKIP_EXTERNAL_TRIGGER}"; then
|
if grep -q "^piper_gpu_" <<< "${SKIP_EXTERNAL_TRIGGER}"; then
|
||||||
|
echo "> [!NOTE]" >> $GITHUB_STEP_SUMMARY
|
||||||
|
echo "> Github organizational variable \`SKIP_EXTERNAL_TRIGGER\` contains \`piper_gpu_\`; will skip trigger if version matches." >> $GITHUB_STEP_SUMMARY
|
||||||
|
elif grep -q "^piper_gpu" <<< "${SKIP_EXTERNAL_TRIGGER}"; then
|
||||||
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
||||||
echo "> Github organizational variable \`SKIP_EXTERNAL_TRIGGER\` contains \`piper_main\`; skipping trigger." >> $GITHUB_STEP_SUMMARY
|
echo "> Github organizational variable \`SKIP_EXTERNAL_TRIGGER\` contains \`piper_gpu\`; skipping trigger." >> $GITHUB_STEP_SUMMARY
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
fi
|
||||||
echo "> [!NOTE]" >> $GITHUB_STEP_SUMMARY
|
echo "> [!NOTE]" >> $GITHUB_STEP_SUMMARY
|
||||||
echo "> External trigger running off of main branch. To disable this trigger, add \`piper_main\` into the Github organizational variable \`SKIP_EXTERNAL_TRIGGER\`." >> $GITHUB_STEP_SUMMARY
|
echo "> External trigger running off of gpu branch. To disable this trigger, add \`piper_gpu\` into the Github organizational variable \`SKIP_EXTERNAL_TRIGGER\`." >> $GITHUB_STEP_SUMMARY
|
||||||
printf "\n## Retrieving external version\n\n" >> $GITHUB_STEP_SUMMARY
|
printf "\n## Retrieving external version\n\n" >> $GITHUB_STEP_SUMMARY
|
||||||
EXT_RELEASE=$(curl -sL "https://pypi.python.org/pypi/wyoming-piper/json" |jq -r '. | .info.version')
|
EXT_RELEASE=$(curl -sL "https://pypi.python.org/pypi/wyoming-piper/json" |jq -r '. | .info.version')
|
||||||
echo "Type is \`pip_version\`" >> $GITHUB_STEP_SUMMARY
|
echo "Type is \`pip_version\`" >> $GITHUB_STEP_SUMMARY
|
||||||
|
if grep -q "^piper_gpu_${EXT_RELEASE}" <<< "${SKIP_EXTERNAL_TRIGGER}"; then
|
||||||
|
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
||||||
|
echo "> Github organizational variable \`SKIP_EXTERNAL_TRIGGER\` matches current external release; skipping trigger." >> $GITHUB_STEP_SUMMARY
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
if [ -z "${EXT_RELEASE}" ] || [ "${EXT_RELEASE}" == "null" ]; then
|
if [ -z "${EXT_RELEASE}" ] || [ "${EXT_RELEASE}" == "null" ]; then
|
||||||
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
||||||
echo "> Can't retrieve external version, exiting" >> $GITHUB_STEP_SUMMARY
|
echo "> Can't retrieve external version, exiting" >> $GITHUB_STEP_SUMMARY
|
||||||
FAILURE_REASON="Can't retrieve external version for piper branch main"
|
FAILURE_REASON="Can't retrieve external version for piper branch gpu"
|
||||||
GHA_TRIGGER_URL="https://github.com/linuxserver/docker-piper/actions/runs/${{ github.run_id }}"
|
GHA_TRIGGER_URL="https://github.com/linuxserver/docker-piper/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"}],
|
||||||
"username": "Github Actions"}' ${{ secrets.DISCORD_WEBHOOK }}
|
"username": "Github Actions"}' ${{ secrets.DISCORD_WEBHOOK }}
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
EXT_RELEASE=$(echo ${EXT_RELEASE} | sed 's/[~,%@+;:/]//g')
|
EXT_RELEASE_SANITIZED=$(echo ${EXT_RELEASE} | sed 's/[~,%@+;:/]//g')
|
||||||
echo "External version: \`${EXT_RELEASE}\`" >> $GITHUB_STEP_SUMMARY
|
echo "Sanitized external version: \`${EXT_RELEASE_SANITIZED}\`" >> $GITHUB_STEP_SUMMARY
|
||||||
echo "Retrieving last pushed version" >> $GITHUB_STEP_SUMMARY
|
echo "Retrieving last pushed version" >> $GITHUB_STEP_SUMMARY
|
||||||
image="linuxserver/piper"
|
image="linuxserver/piper"
|
||||||
tag="latest"
|
tag="gpu"
|
||||||
token=$(curl -sX GET \
|
token=$(curl -sX GET \
|
||||||
"https://ghcr.io/token?scope=repository%3Alinuxserver%2Fpiper%3Apull" \
|
"https://ghcr.io/token?scope=repository%3Alinuxserver%2Fpiper%3Apull" \
|
||||||
| jq -r '.token')
|
| jq -r '.token')
|
||||||
multidigest=$(curl -s \
|
multidigest=$(curl -s \
|
||||||
|
--header "Accept: application/vnd.docker.distribution.manifest.v2+json" \
|
||||||
|
--header "Accept: application/vnd.oci.image.index.v1+json" \
|
||||||
|
--header "Authorization: Bearer ${token}" \
|
||||||
|
"https://ghcr.io/v2/${image}/manifests/${tag}")
|
||||||
|
if jq -e '.layers // empty' <<< "${multidigest}" >/dev/null 2>&1; then
|
||||||
|
# If there's a layer element it's a single-arch manifest so just get that digest
|
||||||
|
digest=$(jq -r '.config.digest' <<< "${multidigest}")
|
||||||
|
else
|
||||||
|
# Otherwise it's multi-arch or has manifest annotations
|
||||||
|
if jq -e '.manifests[]?.annotations // empty' <<< "${multidigest}" >/dev/null 2>&1; then
|
||||||
|
# Check for manifest annotations and delete if found
|
||||||
|
multidigest=$(jq 'del(.manifests[] | select(.annotations))' <<< "${multidigest}")
|
||||||
|
fi
|
||||||
|
if [[ $(jq '.manifests | length' <<< "${multidigest}") -gt 1 ]]; then
|
||||||
|
# If there's still more than one digest, it's multi-arch
|
||||||
|
multidigest=$(jq -r ".manifests[] | select(.platform.architecture == \"amd64\").digest?" <<< "${multidigest}")
|
||||||
|
else
|
||||||
|
# Otherwise it's single arch
|
||||||
|
multidigest=$(jq -r ".manifests[].digest?" <<< "${multidigest}")
|
||||||
|
fi
|
||||||
|
if digest=$(curl -s \
|
||||||
--header "Accept: application/vnd.docker.distribution.manifest.v2+json" \
|
--header "Accept: application/vnd.docker.distribution.manifest.v2+json" \
|
||||||
|
--header "Accept: application/vnd.oci.image.manifest.v1+json" \
|
||||||
--header "Authorization: Bearer ${token}" \
|
--header "Authorization: Bearer ${token}" \
|
||||||
"https://ghcr.io/v2/${image}/manifests/${tag}" \
|
"https://ghcr.io/v2/${image}/manifests/${multidigest}"); then
|
||||||
| jq -r 'first(.manifests[].digest)')
|
digest=$(jq -r '.config.digest' <<< "${digest}");
|
||||||
digest=$(curl -s \
|
fi
|
||||||
--header "Accept: application/vnd.docker.distribution.manifest.v2+json" \
|
fi
|
||||||
--header "Authorization: Bearer ${token}" \
|
|
||||||
"https://ghcr.io/v2/${image}/manifests/${multidigest}" \
|
|
||||||
| 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}")
|
||||||
@ -66,35 +96,35 @@ jobs:
|
|||||||
if [ -z "${IMAGE_VERSION}" ]; then
|
if [ -z "${IMAGE_VERSION}" ]; then
|
||||||
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
||||||
echo "Can't retrieve last pushed version, exiting" >> $GITHUB_STEP_SUMMARY
|
echo "Can't retrieve last pushed version, exiting" >> $GITHUB_STEP_SUMMARY
|
||||||
FAILURE_REASON="Can't retrieve last pushed version for piper tag latest"
|
FAILURE_REASON="Can't retrieve last pushed version for piper tag gpu"
|
||||||
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}\`" >> $GITHUB_STEP_SUMMARY
|
echo "Last pushed version: \`${IMAGE_VERSION}\`" >> $GITHUB_STEP_SUMMARY
|
||||||
if [ "${EXT_RELEASE}" == "${IMAGE_VERSION}" ]; then
|
if [ "${EXT_RELEASE_SANITIZED}" == "${IMAGE_VERSION}" ]; then
|
||||||
echo "Version \`${EXT_RELEASE}\` already pushed, exiting" >> $GITHUB_STEP_SUMMARY
|
echo "Sanitized version \`${EXT_RELEASE_SANITIZED}\` already pushed, exiting" >> $GITHUB_STEP_SUMMARY
|
||||||
exit 0
|
exit 0
|
||||||
elif [ $(curl -s https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-piper/job/main/lastBuild/api/json | jq -r '.building') == "true" ]; then
|
elif [ $(curl -s https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-piper/job/gpu/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" >> $GITHUB_STEP_SUMMARY
|
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
|
||||||
if [[ "${artifacts_found}" == "false" ]]; then
|
if [[ "${artifacts_found}" == "false" ]]; then
|
||||||
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
||||||
echo "> New version detected, but not all artifacts are published yet; skipping trigger" >> $GITHUB_STEP_SUMMARY
|
echo "> New version detected, but not all artifacts are published yet; skipping trigger" >> $GITHUB_STEP_SUMMARY
|
||||||
FAILURE_REASON="New version ${EXT_RELEASE} for piper tag latest is detected, however not all artifacts are uploaded to upstream release yet. Will try again later."
|
FAILURE_REASON="New version ${EXT_RELEASE} for piper tag gpu is detected, however not all artifacts are uploaded to upstream release yet. Will try again later."
|
||||||
curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://cdn.discordapp.com/avatars/354986384542662657/df91181b3f1cf0ef1592fbe18e0962d7.png","embeds": [{"color": 9802903,
|
curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://cdn.discordapp.com/avatars/354986384542662657/df91181b3f1cf0ef1592fbe18e0962d7.png","embeds": [{"color": 9802903,
|
||||||
"description": "**Trigger Failed** \n**Reason:** '"${FAILURE_REASON}"' \n"}],
|
"description": "**Trigger Failed** \n**Reason:** '"${FAILURE_REASON}"' \n"}],
|
||||||
"username": "Github Actions"}' ${{ secrets.DISCORD_WEBHOOK }}
|
"username": "Github Actions"}' ${{ secrets.DISCORD_WEBHOOK }}
|
||||||
else
|
else
|
||||||
printf "\n## Trigger new build\n\n" >> $GITHUB_STEP_SUMMARY
|
printf "\n## Trigger new build\n\n" >> $GITHUB_STEP_SUMMARY
|
||||||
echo "New version \`${EXT_RELEASE}\` found; old version was \`${IMAGE_VERSION}\`. Triggering new build" >> $GITHUB_STEP_SUMMARY
|
echo "New sanitized version \`${EXT_RELEASE_SANITIZED}\` found; old version was \`${IMAGE_VERSION}\`. Triggering new build" >> $GITHUB_STEP_SUMMARY
|
||||||
if "${artifacts_found}" == "true" ]]; then
|
if [[ "${artifacts_found}" == "true" ]]; then
|
||||||
echo "All artifacts seem to be uploaded." >> $GITHUB_STEP_SUMMARY
|
echo "All artifacts seem to be uploaded." >> $GITHUB_STEP_SUMMARY
|
||||||
fi
|
fi
|
||||||
response=$(curl -iX POST \
|
response=$(curl -iX POST \
|
||||||
https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-piper/job/main/buildWithParameters?PACKAGE_CHECK=false \
|
https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-piper/job/gpu/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'})" >> $GITHUB_STEP_SUMMARY
|
echo "Jenkins [job queue url](${response%$'\r'})" >> $GITHUB_STEP_SUMMARY
|
||||||
echo "Sleeping 10 seconds until job starts" >> $GITHUB_STEP_SUMMARY
|
echo "Sleeping 10 seconds until job starts" >> $GITHUB_STEP_SUMMARY
|
||||||
@ -109,7 +139,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 piper tag latest. Old version:${IMAGE_VERSION} New version:${EXT_RELEASE}"
|
TRIGGER_REASON="A version change was detected for piper tag gpu. Old version:${IMAGE_VERSION} New version:${EXT_RELEASE_SANITIZED}"
|
||||||
curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://cdn.discordapp.com/avatars/354986384542662657/df91181b3f1cf0ef1592fbe18e0962d7.png","embeds": [{"color": 9802903,
|
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 }}
|
||||||
|
|||||||
@ -5,6 +5,9 @@ on:
|
|||||||
- cron: '30 * * * *'
|
- cron: '30 * * * *'
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
external-trigger-scheduler:
|
external-trigger-scheduler:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|||||||
8
.github/workflows/greetings.yml
vendored
8
.github/workflows/greetings.yml
vendored
@ -2,12 +2,18 @@ name: Greetings
|
|||||||
|
|
||||||
on: [pull_request_target, issues]
|
on: [pull_request_target, issues]
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
greeting:
|
greeting:
|
||||||
|
permissions:
|
||||||
|
issues: write
|
||||||
|
pull-requests: write
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
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 relevant issue templates, or risk having this issue marked as invalid.'
|
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-piper/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-piper/blob/gpu/.github/PULL_REQUEST_TEMPLATE.md)!'
|
||||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|||||||
30
.github/workflows/package_trigger_scheduler.yml
vendored
30
.github/workflows/package_trigger_scheduler.yml
vendored
@ -5,6 +5,9 @@ on:
|
|||||||
- cron: '35 8 * * 1'
|
- cron: '35 8 * * 1'
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
package-trigger-scheduler:
|
package-trigger-scheduler:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
@ -27,9 +30,18 @@ jobs:
|
|||||||
fi
|
fi
|
||||||
printf "\n## Evaluating \`%s\`\n\n" ${br} >> $GITHUB_STEP_SUMMARY
|
printf "\n## Evaluating \`%s\`\n\n" ${br} >> $GITHUB_STEP_SUMMARY
|
||||||
JENKINS_VARS=$(curl -sX GET https://raw.githubusercontent.com/linuxserver/docker-piper/${br}/jenkins-vars.yml)
|
JENKINS_VARS=$(curl -sX GET https://raw.githubusercontent.com/linuxserver/docker-piper/${br}/jenkins-vars.yml)
|
||||||
if [[ "${br}" == $(yq -r '.ls_branch' <<< "${JENKINS_VARS}") ]]; then
|
if ! curl -sfX GET https://raw.githubusercontent.com/linuxserver/docker-piper/${br}/Jenkinsfile >/dev/null 2>&1; then
|
||||||
|
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
||||||
|
echo "> No Jenkinsfile found. Branch is either deprecated or is an early dev branch." >> $GITHUB_STEP_SUMMARY
|
||||||
|
skipped_branches="${skipped_branches}${br} "
|
||||||
|
elif [[ "${br}" == $(yq -r '.ls_branch' <<< "${JENKINS_VARS}") ]]; then
|
||||||
echo "Branch appears to be live; checking workflow." >> $GITHUB_STEP_SUMMARY
|
echo "Branch appears to be live; checking workflow." >> $GITHUB_STEP_SUMMARY
|
||||||
if [[ $(yq -r '.skip_package_check' <<< "${JENKINS_VARS}") == "true" ]]; then
|
README_VARS=$(curl -sX GET https://raw.githubusercontent.com/linuxserver/docker-piper/${br}/readme-vars.yml)
|
||||||
|
if [[ $(yq -r '.project_deprecation_status' <<< "${README_VARS}") == "true" ]]; then
|
||||||
|
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
||||||
|
echo "> Branch appears to be deprecated; skipping trigger." >> $GITHUB_STEP_SUMMARY
|
||||||
|
skipped_branches="${skipped_branches}${br} "
|
||||||
|
elif [[ $(yq -r '.skip_package_check' <<< "${JENKINS_VARS}") == "true" ]]; then
|
||||||
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
||||||
echo "> Skipping branch ${br} due to \`skip_package_check\` being set in \`jenkins-vars.yml\`." >> $GITHUB_STEP_SUMMARY
|
echo "> Skipping branch ${br} due to \`skip_package_check\` being set in \`jenkins-vars.yml\`." >> $GITHUB_STEP_SUMMARY
|
||||||
skipped_branches="${skipped_branches}${br} "
|
skipped_branches="${skipped_branches}${br} "
|
||||||
@ -37,7 +49,7 @@ jobs:
|
|||||||
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
||||||
echo "> Github organizational variable \`SKIP_PACKAGE_TRIGGER\` contains \`piper_${br}\`; skipping trigger." >> $GITHUB_STEP_SUMMARY
|
echo "> Github organizational variable \`SKIP_PACKAGE_TRIGGER\` contains \`piper_${br}\`; skipping trigger." >> $GITHUB_STEP_SUMMARY
|
||||||
skipped_branches="${skipped_branches}${br} "
|
skipped_branches="${skipped_branches}${br} "
|
||||||
elif [ $(curl -s https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-piper/job/${br}/lastBuild/api/json | jq -r '.building') == "true" ]; then
|
elif [ $(curl -s https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-piper/job/${br}/lastBuild/api/json | jq -r '.building' 2>/dev/null) == "true" ]; then
|
||||||
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
||||||
echo "> There already seems to be an active build on Jenkins; skipping package trigger for ${br}" >> $GITHUB_STEP_SUMMARY
|
echo "> There already seems to be an active build on Jenkins; skipping package trigger for ${br}" >> $GITHUB_STEP_SUMMARY
|
||||||
skipped_branches="${skipped_branches}${br} "
|
skipped_branches="${skipped_branches}${br} "
|
||||||
@ -49,6 +61,11 @@ jobs:
|
|||||||
response=$(curl -iX POST \
|
response=$(curl -iX POST \
|
||||||
https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-piper/job/${br}/buildWithParameters?PACKAGE_CHECK=true \
|
https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-piper/job/${br}/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|")
|
||||||
|
if [[ -z "${response}" ]]; then
|
||||||
|
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
||||||
|
echo "> Jenkins build could not be triggered. Skipping branch."
|
||||||
|
continue
|
||||||
|
fi
|
||||||
echo "Jenkins [job queue url](${response%$'\r'})" >> $GITHUB_STEP_SUMMARY
|
echo "Jenkins [job queue url](${response%$'\r'})" >> $GITHUB_STEP_SUMMARY
|
||||||
echo "Sleeping 10 seconds until job starts" >> $GITHUB_STEP_SUMMARY
|
echo "Sleeping 10 seconds until job starts" >> $GITHUB_STEP_SUMMARY
|
||||||
sleep 10
|
sleep 10
|
||||||
@ -56,11 +73,14 @@ jobs:
|
|||||||
buildurl="${buildurl%$'\r'}"
|
buildurl="${buildurl%$'\r'}"
|
||||||
echo "Jenkins job [build url](${buildurl})" >> $GITHUB_STEP_SUMMARY
|
echo "Jenkins job [build url](${buildurl})" >> $GITHUB_STEP_SUMMARY
|
||||||
echo "Attempting to change the Jenkins job description" >> $GITHUB_STEP_SUMMARY
|
echo "Attempting to change the Jenkins job description" >> $GITHUB_STEP_SUMMARY
|
||||||
curl -iX POST \
|
if ! curl -ifX POST \
|
||||||
"${buildurl}submitDescription" \
|
"${buildurl}submitDescription" \
|
||||||
--user ${{ secrets.JENKINS_USER }}:${{ secrets.JENKINS_TOKEN }} \
|
--user ${{ secrets.JENKINS_USER }}:${{ secrets.JENKINS_TOKEN }} \
|
||||||
--data-urlencode "description=GHA package trigger https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" \
|
--data-urlencode "description=GHA package trigger https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" \
|
||||||
--data-urlencode "Submit=Submit"
|
--data-urlencode "Submit=Submit"; then
|
||||||
|
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
|
||||||
|
echo "> Unable to change the Jenkins job description."
|
||||||
|
fi
|
||||||
sleep 20
|
sleep 20
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
|
|||||||
18
Dockerfile
18
Dockerfile
@ -24,17 +24,15 @@ RUN \
|
|||||||
pip \
|
pip \
|
||||||
wheel && \
|
wheel && \
|
||||||
pip install -U --no-cache-dir --find-links https://wheel-index.linuxserver.io/ubuntu/ \
|
pip install -U --no-cache-dir --find-links https://wheel-index.linuxserver.io/ubuntu/ \
|
||||||
|
nvidia-cublas-cu12 \
|
||||||
|
nvidia-cuda-nvrtc-cu12 \
|
||||||
|
nvidia-cuda-runtime-cu12 \
|
||||||
|
"nvidia-cudnn-cu12>=9.0,<10.0" \
|
||||||
|
nvidia-cufft-cu12 \
|
||||||
|
nvidia-curand-cu12 \
|
||||||
|
onnxruntime-gpu \
|
||||||
|
piper-tts \
|
||||||
"wyoming-piper==${PIPER_VERSION}" && \
|
"wyoming-piper==${PIPER_VERSION}" && \
|
||||||
if [ -z ${PIPER_BIN_VERSION+x} ]; then \
|
|
||||||
PIPER_BIN_VERSION=$(curl -sL "https://api.github.com/repos/rhasspy/piper/releases/latest" \
|
|
||||||
| awk '/tag_name/{print $4;exit}' FS='[""]'); \
|
|
||||||
fi && \
|
|
||||||
curl -sL -o \
|
|
||||||
/tmp/piper.tar.gz -L \
|
|
||||||
"https://github.com/rhasspy/piper/releases/download/${PIPER_BIN_VERSION}/piper_linux_x86_64.tar.gz" && \
|
|
||||||
tar xzf \
|
|
||||||
/tmp/piper.tar.gz -C \
|
|
||||||
/usr/share && \
|
|
||||||
printf "Linuxserver.io version: ${VERSION}\nBuild-date: ${BUILD_DATE}" > /build_version && \
|
printf "Linuxserver.io version: ${VERSION}\nBuild-date: ${BUILD_DATE}" > /build_version && \
|
||||||
echo "**** cleanup ****" && \
|
echo "**** cleanup ****" && \
|
||||||
rm -rf \
|
rm -rf \
|
||||||
|
|||||||
@ -1,48 +0,0 @@
|
|||||||
# syntax=docker/dockerfile:1
|
|
||||||
|
|
||||||
FROM ghcr.io/linuxserver/baseimage-ubuntu:arm64v8-noble
|
|
||||||
|
|
||||||
# set version label
|
|
||||||
ARG BUILD_DATE
|
|
||||||
ARG VERSION
|
|
||||||
ARG PIPER_VERSION
|
|
||||||
LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DATE}"
|
|
||||||
LABEL maintainer="thespad"
|
|
||||||
|
|
||||||
ENV DEBIAN_FRONTEND="noninteractive" \
|
|
||||||
TMPDIR="/run/piper-temp"
|
|
||||||
|
|
||||||
RUN \
|
|
||||||
apt-get update && \
|
|
||||||
apt-get install -y --no-install-recommends \
|
|
||||||
python3-venv && \
|
|
||||||
if [ -z ${PIPER_VERSION+x} ]; then \
|
|
||||||
PIPER_VERSION=$(curl -sL https://pypi.python.org/pypi/wyoming-piper/json |jq -r '. | .info.version'); \
|
|
||||||
fi && \
|
|
||||||
python3 -m venv /lsiopy && \
|
|
||||||
pip install -U --no-cache-dir \
|
|
||||||
pip \
|
|
||||||
wheel && \
|
|
||||||
pip install -U --no-cache-dir --find-links https://wheel-index.linuxserver.io/ubuntu/ \
|
|
||||||
"wyoming-piper==${PIPER_VERSION}" && \
|
|
||||||
if [ -z ${PIPER_BIN_VERSION+x} ]; then \
|
|
||||||
PIPER_BIN_VERSION=$(curl -sL "https://api.github.com/repos/rhasspy/piper/releases/latest" \
|
|
||||||
| awk '/tag_name/{print $4;exit}' FS='[""]'); \
|
|
||||||
fi && \
|
|
||||||
curl -sL -o \
|
|
||||||
/tmp/piper.tar.gz -L \
|
|
||||||
"https://github.com/rhasspy/piper/releases/download/${PIPER_BIN_VERSION}/piper_linux_aarch64.tar.gz" && \
|
|
||||||
tar xzf \
|
|
||||||
/tmp/piper.tar.gz -C \
|
|
||||||
/usr/share && \
|
|
||||||
printf "Linuxserver.io version: ${VERSION}\nBuild-date: ${BUILD_DATE}" > /build_version && \
|
|
||||||
echo "**** cleanup ****" && \
|
|
||||||
rm -rf \
|
|
||||||
/var/lib/apt/lists/* \
|
|
||||||
/tmp/*
|
|
||||||
|
|
||||||
COPY root /
|
|
||||||
|
|
||||||
VOLUME /config
|
|
||||||
|
|
||||||
EXPOSE 10200
|
|
||||||
490
Jenkinsfile
vendored
490
Jenkinsfile
vendored
@ -8,7 +8,7 @@ pipeline {
|
|||||||
}
|
}
|
||||||
// Input to determine if this is a package check
|
// Input to determine if this is a package check
|
||||||
parameters {
|
parameters {
|
||||||
string(defaultValue: 'false', description: 'package check run', name: 'PACKAGE_CHECK')
|
string(defaultValue: 'false', description: 'package check run', name: 'PACKAGE_CHECK')
|
||||||
}
|
}
|
||||||
// Configuration for the variables used for this specific repo
|
// Configuration for the variables used for this specific repo
|
||||||
environment {
|
environment {
|
||||||
@ -28,7 +28,7 @@ pipeline {
|
|||||||
DEV_DOCKERHUB_IMAGE = 'lsiodev/piper'
|
DEV_DOCKERHUB_IMAGE = 'lsiodev/piper'
|
||||||
PR_DOCKERHUB_IMAGE = 'lspipepr/piper'
|
PR_DOCKERHUB_IMAGE = 'lspipepr/piper'
|
||||||
DIST_IMAGE = 'ubuntu'
|
DIST_IMAGE = 'ubuntu'
|
||||||
MULTIARCH='true'
|
MULTIARCH='false'
|
||||||
CI='true'
|
CI='true'
|
||||||
CI_WEB='false'
|
CI_WEB='false'
|
||||||
CI_DELAY='120'
|
CI_DELAY='120'
|
||||||
@ -55,15 +55,27 @@ pipeline {
|
|||||||
steps{
|
steps{
|
||||||
echo "Running on node: ${NODE_NAME}"
|
echo "Running on node: ${NODE_NAME}"
|
||||||
sh '''#! /bin/bash
|
sh '''#! /bin/bash
|
||||||
containers=$(docker ps -aq)
|
echo "Pruning builder"
|
||||||
|
docker builder prune -f --builder container || :
|
||||||
|
containers=$(docker ps -q)
|
||||||
if [[ -n "${containers}" ]]; then
|
if [[ -n "${containers}" ]]; then
|
||||||
docker stop ${containers}
|
BUILDX_CONTAINER_ID=$(docker ps -qf 'name=buildx_buildkit')
|
||||||
|
for container in ${containers}; do
|
||||||
|
if [[ "${container}" == "${BUILDX_CONTAINER_ID}" ]]; then
|
||||||
|
echo "skipping buildx container in docker stop"
|
||||||
|
else
|
||||||
|
echo "Stopping container ${container}"
|
||||||
|
docker stop ${container}
|
||||||
|
fi
|
||||||
|
done
|
||||||
fi
|
fi
|
||||||
docker system prune -af --volumes || : '''
|
docker system prune -f --volumes || :
|
||||||
|
docker image prune -af || :
|
||||||
|
'''
|
||||||
script{
|
script{
|
||||||
env.EXIT_STATUS = ''
|
env.EXIT_STATUS = ''
|
||||||
env.LS_RELEASE = sh(
|
env.LS_RELEASE = sh(
|
||||||
script: '''docker run --rm quay.io/skopeo/stable:v1 inspect docker://ghcr.io/${LS_USER}/${CONTAINER_NAME}: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}:gpu 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' ''',
|
||||||
@ -81,7 +93,11 @@ pipeline {
|
|||||||
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.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'
|
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'
|
||||||
|
if ( env.SYFT_IMAGE_TAG == null ) {
|
||||||
|
env.SYFT_IMAGE_TAG = 'latest'
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
echo "Using syft image tag ${SYFT_IMAGE_TAG}"
|
||||||
sh '''#! /bin/bash
|
sh '''#! /bin/bash
|
||||||
echo "The default github branch detected as ${GH_DEFAULT_BRANCH}" '''
|
echo "The default github branch detected as ${GH_DEFAULT_BRANCH}" '''
|
||||||
script{
|
script{
|
||||||
@ -92,7 +108,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 gpu-${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
|
||||||
@ -169,10 +185,10 @@ pipeline {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// If this is a main build use live docker endpoints
|
// If this is a gpu build use live docker endpoints
|
||||||
stage("Set ENV live build"){
|
stage("Set ENV live build"){
|
||||||
when {
|
when {
|
||||||
branch "main"
|
branch "gpu"
|
||||||
environment name: 'CHANGE_ID', value: ''
|
environment name: 'CHANGE_ID', value: ''
|
||||||
}
|
}
|
||||||
steps {
|
steps {
|
||||||
@ -182,20 +198,22 @@ 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 + '|arm64v8-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER
|
env.CI_TAGS = 'amd64-gpu-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER + '|arm64v8-gpu-' + 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 = 'gpu-' + 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 = 'gpu-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER
|
||||||
env.EXT_RELEASE_TAG = 'version-' + env.EXT_RELEASE_CLEAN
|
env.EXT_RELEASE_TAG = 'gpu-version-' + env.EXT_RELEASE_CLEAN
|
||||||
|
env.BUILDCACHE = 'docker.io/lsiodev/buildcache,registry.gitlab.com/linuxserver.io/docker-jenkins-builder/lsiodev-buildcache,ghcr.io/linuxserver/lsiodev-buildcache,quay.io/linuxserver.io/lsiodev-buildcache'
|
||||||
|
env.CITEST_IMAGETAG = 'latest'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// 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 "gpu"}
|
||||||
environment name: 'CHANGE_ID', value: ''
|
environment name: 'CHANGE_ID', value: ''
|
||||||
}
|
}
|
||||||
steps {
|
steps {
|
||||||
@ -205,14 +223,16 @@ 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 + '|arm64v8-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA
|
env.CI_TAGS = 'amd64-gpu-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA + '|arm64v8-gpu-' + 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 = 'gpu-' + 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 = 'gpu-' + 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 = 'gpu-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/'
|
||||||
|
env.BUILDCACHE = 'docker.io/lsiodev/buildcache,registry.gitlab.com/linuxserver.io/docker-jenkins-builder/lsiodev-buildcache,ghcr.io/linuxserver/lsiodev-buildcache,quay.io/linuxserver.io/lsiodev-buildcache'
|
||||||
|
env.CITEST_IMAGETAG = 'develop'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -228,15 +248,17 @@ 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 + '-dev-' + env.COMMIT_SHA + '-pr-' + env.PULL_REQUEST + '|arm64v8-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA + '-pr-' + env.PULL_REQUEST
|
env.CI_TAGS = 'amd64-gpu-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA + '-pr-' + env.PULL_REQUEST + '|arm64v8-gpu-' + 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 + '-dev-' + env.COMMIT_SHA + '-pr-' + env.PULL_REQUEST
|
env.CI_TAGS = 'gpu-' + 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 + '-dev-' + env.COMMIT_SHA + '-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 + '-dev-' + env.COMMIT_SHA + '-pr-' + env.PULL_REQUEST
|
env.META_TAG = 'gpu-' + 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 = 'gpu-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/'
|
||||||
|
env.BUILDCACHE = 'docker.io/lsiodev/buildcache,registry.gitlab.com/linuxserver.io/docker-jenkins-builder/lsiodev-buildcache,ghcr.io/linuxserver/lsiodev-buildcache,quay.io/linuxserver.io/lsiodev-buildcache'
|
||||||
|
env.CITEST_IMAGETAG = 'develop'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -259,7 +281,7 @@ pipeline {
|
|||||||
-v ${WORKSPACE}:/mnt \
|
-v ${WORKSPACE}:/mnt \
|
||||||
-e AWS_ACCESS_KEY_ID=\"${S3_KEY}\" \
|
-e AWS_ACCESS_KEY_ID=\"${S3_KEY}\" \
|
||||||
-e AWS_SECRET_ACCESS_KEY=\"${S3_SECRET}\" \
|
-e AWS_SECRET_ACCESS_KEY=\"${S3_SECRET}\" \
|
||||||
ghcr.io/linuxserver/baseimage-alpine:3.20 s6-envdir -fn -- /var/run/s6/container_environment /bin/bash -c "\
|
ghcr.io/linuxserver/baseimage-alpine:3.23 s6-envdir -fn -- /var/run/s6/container_environment /bin/bash -c "\
|
||||||
apk add --no-cache python3 && \
|
apk add --no-cache python3 && \
|
||||||
python3 -m venv /lsiopy && \
|
python3 -m venv /lsiopy && \
|
||||||
pip install --no-cache-dir -U pip && \
|
pip install --no-cache-dir -U pip && \
|
||||||
@ -271,7 +293,7 @@ pipeline {
|
|||||||
// 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 "gpu"
|
||||||
environment name: 'CHANGE_ID', value: ''
|
environment name: 'CHANGE_ID', value: ''
|
||||||
expression {
|
expression {
|
||||||
env.CONTAINER_NAME != null
|
env.CONTAINER_NAME != null
|
||||||
@ -283,24 +305,24 @@ pipeline {
|
|||||||
TEMPDIR=$(mktemp -d)
|
TEMPDIR=$(mktemp -d)
|
||||||
docker pull ghcr.io/linuxserver/jenkins-builder:latest
|
docker pull ghcr.io/linuxserver/jenkins-builder:latest
|
||||||
# Cloned repo paths for templating:
|
# Cloned repo paths for templating:
|
||||||
# ${TEMPDIR}/docker-${CONTAINER_NAME}: Cloned branch main of ${LS_USER}/${LS_REPO} for running the jenkins builder on
|
# ${TEMPDIR}/docker-${CONTAINER_NAME}: Cloned branch gpu of ${LS_USER}/${LS_REPO} for running the jenkins builder on
|
||||||
# ${TEMPDIR}/repo/${LS_REPO}: Cloned branch main of ${LS_USER}/${LS_REPO} for commiting various templated file changes and pushing back to Github
|
# ${TEMPDIR}/repo/${LS_REPO}: Cloned branch gpu of ${LS_USER}/${LS_REPO} for commiting various templated file changes and pushing back to Github
|
||||||
# ${TEMPDIR}/docs/docker-documentation: Cloned docs repo for pushing docs updates to Github
|
# ${TEMPDIR}/docs/docker-documentation: Cloned docs repo for pushing docs updates to Github
|
||||||
# ${TEMPDIR}/unraid/docker-templates: Cloned docker-templates repo to check for logos
|
# ${TEMPDIR}/unraid/docker-templates: Cloned docker-templates repo to check for logos
|
||||||
# ${TEMPDIR}/unraid/templates: Cloned templates repo for commiting unraid template changes and pushing back to Github
|
# ${TEMPDIR}/unraid/templates: Cloned templates repo for commiting unraid template changes and pushing back to Github
|
||||||
git clone --branch main --depth 1 https://github.com/${LS_USER}/${LS_REPO}.git ${TEMPDIR}/docker-${CONTAINER_NAME}
|
git clone --branch gpu --depth 1 https://github.com/${LS_USER}/${LS_REPO}.git ${TEMPDIR}/docker-${CONTAINER_NAME}
|
||||||
docker run --rm -v ${TEMPDIR}/docker-${CONTAINER_NAME}:/tmp -e LOCAL=true -e PUID=$(id -u) -e PGID=$(id -g) ghcr.io/linuxserver/jenkins-builder:latest
|
docker run --rm -v ${TEMPDIR}/docker-${CONTAINER_NAME}:/tmp -e LOCAL=true -e PUID=$(id -u) -e PGID=$(id -g) ghcr.io/linuxserver/jenkins-builder:latest
|
||||||
echo "Starting Stage 1 - Jenkinsfile update"
|
echo "Starting 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 gpu
|
||||||
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'
|
||||||
git pull https://LinuxServer-CI:${GITHUB_TOKEN}@github.com/${LS_USER}/${LS_REPO}.git main
|
git pull https://LinuxServer-CI:${GITHUB_TOKEN}@github.com/${LS_USER}/${LS_REPO}.git gpu
|
||||||
git push https://LinuxServer-CI:${GITHUB_TOKEN}@github.com/${LS_USER}/${LS_REPO}.git main
|
git push https://LinuxServer-CI:${GITHUB_TOKEN}@github.com/${LS_USER}/${LS_REPO}.git gpu
|
||||||
echo "true" > /tmp/${COMMIT_SHA}-${BUILD_NUMBER}
|
echo "true" > /tmp/${COMMIT_SHA}-${BUILD_NUMBER}
|
||||||
echo "Updating Jenkinsfile and exiting build, new one will trigger based on commit"
|
echo "Updating Jenkinsfile and exiting build, new one will trigger based on commit"
|
||||||
rm -Rf ${TEMPDIR}
|
rm -Rf ${TEMPDIR}
|
||||||
@ -319,13 +341,13 @@ 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 gpu
|
||||||
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 pull https://LinuxServer-CI:${GITHUB_TOKEN}@github.com/${LS_USER}/${LS_REPO}.git main
|
git pull https://LinuxServer-CI:${GITHUB_TOKEN}@github.com/${LS_USER}/${LS_REPO}.git gpu
|
||||||
git push https://LinuxServer-CI:${GITHUB_TOKEN}@github.com/${LS_USER}/${LS_REPO}.git main
|
git push https://LinuxServer-CI:${GITHUB_TOKEN}@github.com/${LS_USER}/${LS_REPO}.git gpu
|
||||||
echo "true" > /tmp/${COMMIT_SHA}-${BUILD_NUMBER}
|
echo "true" > /tmp/${COMMIT_SHA}-${BUILD_NUMBER}
|
||||||
echo "Deleting old/deprecated templates and exiting build, new one will trigger based on commit"
|
echo "Deleting old/deprecated templates and exiting build, new one will trigger based on commit"
|
||||||
rm -Rf ${TEMPDIR}
|
rm -Rf ${TEMPDIR}
|
||||||
@ -333,6 +355,35 @@ pipeline {
|
|||||||
else
|
else
|
||||||
echo "No templates to delete"
|
echo "No templates to delete"
|
||||||
fi
|
fi
|
||||||
|
echo "Starting Stage 2.5 - Update init diagram"
|
||||||
|
if ! grep -q 'init_diagram:' readme-vars.yml; then
|
||||||
|
echo "Adding the key 'init_diagram' to readme-vars.yml"
|
||||||
|
sed -i '\\|^#.*changelog.*$|d' readme-vars.yml
|
||||||
|
sed -i 's|^changelogs:|# init diagram\\ninit_diagram:\\n\\n# changelog\\nchangelogs:|' readme-vars.yml
|
||||||
|
fi
|
||||||
|
mkdir -p ${TEMPDIR}/d2
|
||||||
|
docker run --rm -v ${TEMPDIR}/d2:/output -e PUID=$(id -u) -e PGID=$(id -g) -e RAW="true" ghcr.io/linuxserver/d2-builder:latest ${CONTAINER_NAME}:gpu
|
||||||
|
ls -al ${TEMPDIR}/d2
|
||||||
|
yq -ei ".init_diagram |= load_str(\\"${TEMPDIR}/d2/${CONTAINER_NAME}-gpu.d2\\")" readme-vars.yml
|
||||||
|
if [[ $(md5sum readme-vars.yml | cut -c1-8) != $(md5sum ${TEMPDIR}/docker-${CONTAINER_NAME}/readme-vars.yml | cut -c1-8) ]]; then
|
||||||
|
echo "'init_diagram' has been updated. Updating repo and exiting build, new one will trigger based on commit."
|
||||||
|
mkdir -p ${TEMPDIR}/repo
|
||||||
|
git clone https://github.com/${LS_USER}/${LS_REPO}.git ${TEMPDIR}/repo/${LS_REPO}
|
||||||
|
cd ${TEMPDIR}/repo/${LS_REPO}
|
||||||
|
git checkout -f gpu
|
||||||
|
cp ${WORKSPACE}/readme-vars.yml ${TEMPDIR}/repo/${LS_REPO}/readme-vars.yml
|
||||||
|
git add readme-vars.yml
|
||||||
|
git commit -m 'Bot Updating Templated Files'
|
||||||
|
git pull https://LinuxServer-CI:${GITHUB_TOKEN}@github.com/${LS_USER}/${LS_REPO}.git gpu
|
||||||
|
git push https://LinuxServer-CI:${GITHUB_TOKEN}@github.com/${LS_USER}/${LS_REPO}.git gpu
|
||||||
|
echo "true" > /tmp/${COMMIT_SHA}-${BUILD_NUMBER}
|
||||||
|
echo "Updating templates and exiting build, new one will trigger based on commit"
|
||||||
|
rm -Rf ${TEMPDIR}
|
||||||
|
exit 0
|
||||||
|
else
|
||||||
|
echo "false" > /tmp/${COMMIT_SHA}-${BUILD_NUMBER}
|
||||||
|
echo "Init diagram is unchanged"
|
||||||
|
fi
|
||||||
echo "Starting Stage 3 - Update templates"
|
echo "Starting Stage 3 - Update templates"
|
||||||
CURRENTHASH=$(grep -hs ^ ${TEMPLATED_FILES} | md5sum | cut -c1-8)
|
CURRENTHASH=$(grep -hs ^ ${TEMPLATED_FILES} | md5sum | cut -c1-8)
|
||||||
cd ${TEMPDIR}/docker-${CONTAINER_NAME}
|
cd ${TEMPDIR}/docker-${CONTAINER_NAME}
|
||||||
@ -341,7 +392,7 @@ 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 gpu
|
||||||
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
|
||||||
@ -354,8 +405,8 @@ pipeline {
|
|||||||
fi
|
fi
|
||||||
git add readme-vars.yml ${TEMPLATED_FILES}
|
git add readme-vars.yml ${TEMPLATED_FILES}
|
||||||
git commit -m 'Bot Updating Templated Files'
|
git commit -m 'Bot Updating Templated Files'
|
||||||
git pull https://LinuxServer-CI:${GITHUB_TOKEN}@github.com/${LS_USER}/${LS_REPO}.git main
|
git pull https://LinuxServer-CI:${GITHUB_TOKEN}@github.com/${LS_USER}/${LS_REPO}.git gpu
|
||||||
git push https://LinuxServer-CI:${GITHUB_TOKEN}@github.com/${LS_USER}/${LS_REPO}.git main
|
git push https://LinuxServer-CI:${GITHUB_TOKEN}@github.com/${LS_USER}/${LS_REPO}.git gpu
|
||||||
echo "true" > /tmp/${COMMIT_SHA}-${BUILD_NUMBER}
|
echo "true" > /tmp/${COMMIT_SHA}-${BUILD_NUMBER}
|
||||||
echo "Updating templates and exiting build, new one will trigger based on commit"
|
echo "Updating templates and exiting build, new one will trigger based on commit"
|
||||||
rm -Rf ${TEMPDIR}
|
rm -Rf ${TEMPDIR}
|
||||||
@ -456,7 +507,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 "gpu"
|
||||||
environment name: 'CHANGE_ID', value: ''
|
environment name: 'CHANGE_ID', value: ''
|
||||||
environment name: 'FILES_UPDATED', value: 'true'
|
environment name: 'FILES_UPDATED', value: 'true'
|
||||||
expression {
|
expression {
|
||||||
@ -469,10 +520,10 @@ pipeline {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// If this is a main build check the S6 service file perms
|
// If this is a gpu build check the S6 service file perms
|
||||||
stage("Check S6 Service file Permissions"){
|
stage("Check S6 Service file Permissions"){
|
||||||
when {
|
when {
|
||||||
branch "main"
|
branch "gpu"
|
||||||
environment name: 'CHANGE_ID', value: ''
|
environment name: 'CHANGE_ID', value: ''
|
||||||
environment name: 'EXIT_STATUS', value: ''
|
environment name: 'EXIT_STATUS', value: ''
|
||||||
}
|
}
|
||||||
@ -539,10 +590,47 @@ pipeline {
|
|||||||
--label \"org.opencontainers.image.licenses=GPL-3.0-only\" \
|
--label \"org.opencontainers.image.licenses=GPL-3.0-only\" \
|
||||||
--label \"org.opencontainers.image.ref.name=${COMMIT_SHA}\" \
|
--label \"org.opencontainers.image.ref.name=${COMMIT_SHA}\" \
|
||||||
--label \"org.opencontainers.image.title=Piper\" \
|
--label \"org.opencontainers.image.title=Piper\" \
|
||||||
--label \"org.opencontainers.image.description=[Piper](https://github.com/rhasspy/piper/) is a fast, local neural text to speech system that sounds great and is optimized for the Raspberry Pi 4. This container provides a Wyoming protocol server for Piper.\" \
|
--label \"org.opencontainers.image.description=[Piper](https://github.com/rhasspy/wyoming-piper) is a fast, local neural text to speech system that sounds great and is optimized for the Raspberry Pi 4. This container provides a Wyoming protocol server for Piper.\" \
|
||||||
--no-cache --pull -t ${IMAGE}:${META_TAG} --platform=linux/amd64 \
|
--no-cache --pull -t ${IMAGE}:${META_TAG} --platform=linux/amd64 \
|
||||||
--provenance=false --sbom=false \
|
--provenance=true --sbom=true --builder=container --load \
|
||||||
--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 '''#! /bin/bash
|
||||||
|
set -e
|
||||||
|
IFS=',' read -ra CACHE <<< "$BUILDCACHE"
|
||||||
|
for i in "${CACHE[@]}"; do
|
||||||
|
docker tag ${IMAGE}:${META_TAG} ${i}:amd64-${COMMIT_SHA}-${BUILD_NUMBER}
|
||||||
|
done
|
||||||
|
'''
|
||||||
|
withCredentials([
|
||||||
|
[
|
||||||
|
$class: 'UsernamePasswordMultiBinding',
|
||||||
|
credentialsId: 'Quay.io-Robot',
|
||||||
|
usernameVariable: 'QUAYUSER',
|
||||||
|
passwordVariable: 'QUAYPASS'
|
||||||
|
]
|
||||||
|
]) {
|
||||||
|
retry_backoff(5,5) {
|
||||||
|
sh '''#! /bin/bash
|
||||||
|
set -e
|
||||||
|
echo $DOCKERHUB_TOKEN | docker login -u linuxserverci --password-stdin
|
||||||
|
echo $GITHUB_TOKEN | docker login ghcr.io -u LinuxServer-CI --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
|
||||||
|
|
||||||
|
if [[ "${PACKAGE_CHECK}" != "true" ]]; then
|
||||||
|
declare -A pids
|
||||||
|
IFS=',' read -ra CACHE <<< "$BUILDCACHE"
|
||||||
|
for i in "${CACHE[@]}"; do
|
||||||
|
docker push ${i}:amd64-${COMMIT_SHA}-${BUILD_NUMBER} &
|
||||||
|
pids[$!]="$i"
|
||||||
|
done
|
||||||
|
for p in "${!pids[@]}"; do
|
||||||
|
wait "$p" || { [[ "${pids[$p]}" != *"quay.io"* ]] && exit 1; }
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
'''
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// Build MultiArch Docker containers for push to LS Repo
|
// Build MultiArch Docker containers for push to LS Repo
|
||||||
@ -571,10 +659,47 @@ pipeline {
|
|||||||
--label \"org.opencontainers.image.licenses=GPL-3.0-only\" \
|
--label \"org.opencontainers.image.licenses=GPL-3.0-only\" \
|
||||||
--label \"org.opencontainers.image.ref.name=${COMMIT_SHA}\" \
|
--label \"org.opencontainers.image.ref.name=${COMMIT_SHA}\" \
|
||||||
--label \"org.opencontainers.image.title=Piper\" \
|
--label \"org.opencontainers.image.title=Piper\" \
|
||||||
--label \"org.opencontainers.image.description=[Piper](https://github.com/rhasspy/piper/) is a fast, local neural text to speech system that sounds great and is optimized for the Raspberry Pi 4. This container provides a Wyoming protocol server for Piper.\" \
|
--label \"org.opencontainers.image.description=[Piper](https://github.com/rhasspy/wyoming-piper) is a fast, local neural text to speech system that sounds great and is optimized for the Raspberry Pi 4. This container provides a Wyoming protocol server for Piper.\" \
|
||||||
--no-cache --pull -t ${IMAGE}:amd64-${META_TAG} --platform=linux/amd64 \
|
--no-cache --pull -t ${IMAGE}:amd64-${META_TAG} --platform=linux/amd64 \
|
||||||
--provenance=false --sbom=false \
|
--provenance=true --sbom=true --builder=container --load \
|
||||||
--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 '''#! /bin/bash
|
||||||
|
set -e
|
||||||
|
IFS=',' read -ra CACHE <<< "$BUILDCACHE"
|
||||||
|
for i in "${CACHE[@]}"; do
|
||||||
|
docker tag ${IMAGE}:amd64-${META_TAG} ${i}:amd64-${COMMIT_SHA}-${BUILD_NUMBER}
|
||||||
|
done
|
||||||
|
'''
|
||||||
|
withCredentials([
|
||||||
|
[
|
||||||
|
$class: 'UsernamePasswordMultiBinding',
|
||||||
|
credentialsId: 'Quay.io-Robot',
|
||||||
|
usernameVariable: 'QUAYUSER',
|
||||||
|
passwordVariable: 'QUAYPASS'
|
||||||
|
]
|
||||||
|
]) {
|
||||||
|
retry_backoff(5,5) {
|
||||||
|
sh '''#! /bin/bash
|
||||||
|
set -e
|
||||||
|
echo $DOCKERHUB_TOKEN | docker login -u linuxserverci --password-stdin
|
||||||
|
echo $GITHUB_TOKEN | docker login ghcr.io -u LinuxServer-CI --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
|
||||||
|
|
||||||
|
if [[ "${PACKAGE_CHECK}" != "true" ]]; then
|
||||||
|
declare -A pids
|
||||||
|
IFS=',' read -ra CACHE <<< "$BUILDCACHE"
|
||||||
|
for i in "${CACHE[@]}"; do
|
||||||
|
docker push ${i}:amd64-${COMMIT_SHA}-${BUILD_NUMBER} &
|
||||||
|
pids[$!]="$i"
|
||||||
|
done
|
||||||
|
for p in "${!pids[@]}"; do
|
||||||
|
wait "$p" || { [[ "${pids[$p]}" != *"quay.io"* ]] && exit 1; }
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
'''
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
stage('Build ARM64') {
|
stage('Build ARM64') {
|
||||||
@ -583,10 +708,6 @@ pipeline {
|
|||||||
}
|
}
|
||||||
steps {
|
steps {
|
||||||
echo "Running on node: ${NODE_NAME}"
|
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 "sed -r -i 's|(^FROM .*)|\\1\\n\\nENV LSIO_FIRST_PARTY=true|g' Dockerfile.aarch64"
|
sh "sed -r -i 's|(^FROM .*)|\\1\\n\\nENV LSIO_FIRST_PARTY=true|g' Dockerfile.aarch64"
|
||||||
sh "docker buildx build \
|
sh "docker buildx build \
|
||||||
--label \"org.opencontainers.image.created=${GITHUB_DATE}\" \
|
--label \"org.opencontainers.image.created=${GITHUB_DATE}\" \
|
||||||
@ -600,20 +721,54 @@ pipeline {
|
|||||||
--label \"org.opencontainers.image.licenses=GPL-3.0-only\" \
|
--label \"org.opencontainers.image.licenses=GPL-3.0-only\" \
|
||||||
--label \"org.opencontainers.image.ref.name=${COMMIT_SHA}\" \
|
--label \"org.opencontainers.image.ref.name=${COMMIT_SHA}\" \
|
||||||
--label \"org.opencontainers.image.title=Piper\" \
|
--label \"org.opencontainers.image.title=Piper\" \
|
||||||
--label \"org.opencontainers.image.description=[Piper](https://github.com/rhasspy/piper/) is a fast, local neural text to speech system that sounds great and is optimized for the Raspberry Pi 4. This container provides a Wyoming protocol server for Piper.\" \
|
--label \"org.opencontainers.image.description=[Piper](https://github.com/rhasspy/wyoming-piper) is a fast, local neural text to speech system that sounds great and is optimized for the Raspberry Pi 4. This container provides a Wyoming protocol server for Piper.\" \
|
||||||
--no-cache --pull -f Dockerfile.aarch64 -t ${IMAGE}:arm64v8-${META_TAG} --platform=linux/arm64 \
|
--no-cache --pull -f Dockerfile.aarch64 -t ${IMAGE}:arm64v8-${META_TAG} --platform=linux/arm64 \
|
||||||
--provenance=false --sbom=false \
|
--provenance=true --sbom=true --builder=container --load \
|
||||||
--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 '''#! /bin/bash
|
||||||
retry_backoff(5,5) {
|
set -e
|
||||||
sh "docker push ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER}"
|
IFS=',' read -ra CACHE <<< "$BUILDCACHE"
|
||||||
|
for i in "${CACHE[@]}"; do
|
||||||
|
docker tag ${IMAGE}:arm64v8-${META_TAG} ${i}:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER}
|
||||||
|
done
|
||||||
|
'''
|
||||||
|
withCredentials([
|
||||||
|
[
|
||||||
|
$class: 'UsernamePasswordMultiBinding',
|
||||||
|
credentialsId: 'Quay.io-Robot',
|
||||||
|
usernameVariable: 'QUAYUSER',
|
||||||
|
passwordVariable: 'QUAYPASS'
|
||||||
|
]
|
||||||
|
]) {
|
||||||
|
retry_backoff(5,5) {
|
||||||
|
sh '''#! /bin/bash
|
||||||
|
set -e
|
||||||
|
echo $DOCKERHUB_TOKEN | docker login -u linuxserverci --password-stdin
|
||||||
|
echo $GITHUB_TOKEN | docker login ghcr.io -u LinuxServer-CI --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
|
||||||
|
if [[ "${PACKAGE_CHECK}" != "true" ]]; then
|
||||||
|
declare -A pids
|
||||||
|
IFS=',' read -ra CACHE <<< "$BUILDCACHE"
|
||||||
|
for i in "${CACHE[@]}"; do
|
||||||
|
docker push ${i}:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER} &
|
||||||
|
pids[$!]="$i"
|
||||||
|
done
|
||||||
|
for p in "${!pids[@]}"; do
|
||||||
|
wait "$p" || { [[ "${pids[$p]}" != *"quay.io"* ]] && exit 1; }
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
'''
|
||||||
|
}
|
||||||
}
|
}
|
||||||
sh '''#! /bin/bash
|
sh '''#! /bin/bash
|
||||||
containers=$(docker ps -aq)
|
containers=$(docker ps -aq)
|
||||||
if [[ -n "${containers}" ]]; then
|
if [[ -n "${containers}" ]]; then
|
||||||
docker stop ${containers}
|
docker stop ${containers}
|
||||||
fi
|
fi
|
||||||
docker system prune -af --volumes || : '''
|
docker system prune -f --volumes || :
|
||||||
|
docker image prune -af || :
|
||||||
|
'''
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -621,7 +776,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 "gpu"
|
||||||
environment name: 'CHANGE_ID', value: ''
|
environment name: 'CHANGE_ID', value: ''
|
||||||
environment name: 'EXIT_STATUS', value: ''
|
environment name: 'EXIT_STATUS', value: ''
|
||||||
}
|
}
|
||||||
@ -638,20 +793,20 @@ pipeline {
|
|||||||
docker run --rm \
|
docker run --rm \
|
||||||
-v /var/run/docker.sock:/var/run/docker.sock:ro \
|
-v /var/run/docker.sock:/var/run/docker.sock:ro \
|
||||||
-v ${TEMPDIR}:/tmp \
|
-v ${TEMPDIR}:/tmp \
|
||||||
ghcr.io/anchore/syft:latest \
|
ghcr.io/anchore/syft:${SYFT_IMAGE_TAG} \
|
||||||
${LOCAL_CONTAINER} -o table=/tmp/package_versions.txt
|
${LOCAL_CONTAINER} -o table=/tmp/package_versions.txt
|
||||||
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 gpu
|
||||||
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
|
||||||
git add package_versions.txt
|
git add package_versions.txt
|
||||||
git commit -m 'Bot Updating Package Versions'
|
git commit -m 'Bot Updating Package Versions'
|
||||||
git pull https://LinuxServer-CI:${GITHUB_TOKEN}@github.com/${LS_USER}/${LS_REPO}.git main
|
git pull https://LinuxServer-CI:${GITHUB_TOKEN}@github.com/${LS_USER}/${LS_REPO}.git gpu
|
||||||
git push https://LinuxServer-CI:${GITHUB_TOKEN}@github.com/${LS_USER}/${LS_REPO}.git main
|
git push https://LinuxServer-CI:${GITHUB_TOKEN}@github.com/${LS_USER}/${LS_REPO}.git gpu
|
||||||
echo "true" > /tmp/packages-${COMMIT_SHA}-${BUILD_NUMBER}
|
echo "true" > /tmp/packages-${COMMIT_SHA}-${BUILD_NUMBER}
|
||||||
echo "Package tag updated, stopping build process"
|
echo "Package tag updated, stopping build process"
|
||||||
else
|
else
|
||||||
@ -669,7 +824,7 @@ 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 "gpu"
|
||||||
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: ''
|
||||||
@ -683,7 +838,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 "gpu"
|
||||||
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: ''
|
||||||
@ -725,7 +880,7 @@ pipeline {
|
|||||||
CI_DOCKERENV="LSIO_FIRST_PARTY=true"
|
CI_DOCKERENV="LSIO_FIRST_PARTY=true"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
docker pull ghcr.io/linuxserver/ci:latest
|
docker pull ghcr.io/linuxserver/ci:${CITEST_IMAGETAG}
|
||||||
if [ "${MULTIARCH}" == "true" ]; then
|
if [ "${MULTIARCH}" == "true" ]; then
|
||||||
docker pull ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER} --platform=arm64
|
docker pull ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER} --platform=arm64
|
||||||
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}
|
||||||
@ -737,7 +892,7 @@ pipeline {
|
|||||||
-e DOCKER_LOGS_TIMEOUT=\"${CI_DELAY}\" \
|
-e DOCKER_LOGS_TIMEOUT=\"${CI_DELAY}\" \
|
||||||
-e TAGS=\"${CI_TAGS}\" \
|
-e TAGS=\"${CI_TAGS}\" \
|
||||||
-e META_TAG=\"${META_TAG}\" \
|
-e META_TAG=\"${META_TAG}\" \
|
||||||
-e RELEASE_TAG=\"latest\" \
|
-e RELEASE_TAG=\"gpu\" \
|
||||||
-e PORT=\"${CI_PORT}\" \
|
-e PORT=\"${CI_PORT}\" \
|
||||||
-e SSL=\"${CI_SSL}\" \
|
-e SSL=\"${CI_SSL}\" \
|
||||||
-e BASE=\"${DIST_IMAGE}\" \
|
-e BASE=\"${DIST_IMAGE}\" \
|
||||||
@ -748,7 +903,10 @@ pipeline {
|
|||||||
-e WEB_AUTH=\"${CI_AUTH}\" \
|
-e WEB_AUTH=\"${CI_AUTH}\" \
|
||||||
-e WEB_PATH=\"${CI_WEBPATH}\" \
|
-e WEB_PATH=\"${CI_WEBPATH}\" \
|
||||||
-e NODE_NAME=\"${NODE_NAME}\" \
|
-e NODE_NAME=\"${NODE_NAME}\" \
|
||||||
-t ghcr.io/linuxserver/ci:latest \
|
-e SYFT_IMAGE_TAG=\"${CI_SYFT_IMAGE_TAG:-${SYFT_IMAGE_TAG}}\" \
|
||||||
|
-e COMMIT_SHA=\"${COMMIT_SHA}\" \
|
||||||
|
-e BUILD_NUMBER=\"${BUILD_NUMBER}\" \
|
||||||
|
-t ghcr.io/linuxserver/ci:${CITEST_IMAGETAG} \
|
||||||
python3 test_build.py'''
|
python3 test_build.py'''
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -763,37 +921,25 @@ pipeline {
|
|||||||
environment name: 'EXIT_STATUS', value: ''
|
environment name: 'EXIT_STATUS', value: ''
|
||||||
}
|
}
|
||||||
steps {
|
steps {
|
||||||
withCredentials([
|
retry_backoff(5,5) {
|
||||||
[
|
sh '''#! /bin/bash
|
||||||
$class: 'UsernamePasswordMultiBinding',
|
set -e
|
||||||
credentialsId: 'Quay.io-Robot',
|
for PUSHIMAGE in "${IMAGE}" "${GITLABIMAGE}" "${GITHUBIMAGE}" "${QUAYIMAGE}"; do
|
||||||
usernameVariable: 'QUAYUSER',
|
[[ ${PUSHIMAGE%%/*} =~ \\. ]] && PUSHIMAGEPLUS="${PUSHIMAGE}" || PUSHIMAGEPLUS="docker.io/${PUSHIMAGE}"
|
||||||
passwordVariable: 'QUAYPASS'
|
IFS=',' read -ra CACHE <<< "$BUILDCACHE"
|
||||||
]
|
for i in "${CACHE[@]}"; do
|
||||||
]) {
|
if [[ "${PUSHIMAGEPLUS}" == "$(cut -d "/" -f1 <<< ${i})"* ]]; then
|
||||||
retry_backoff(5,5) {
|
CACHEIMAGE=${i}
|
||||||
sh '''#! /bin/bash
|
fi
|
||||||
set -e
|
|
||||||
echo $DOCKERHUB_TOKEN | docker login -u linuxserverci --password-stdin
|
|
||||||
echo $GITHUB_TOKEN | docker login ghcr.io -u LinuxServer-CI --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
|
|
||||||
for PUSHIMAGE in "${GITHUBIMAGE}" "${GITLABIMAGE}" "${QUAYIMAGE}" "${IMAGE}"; do
|
|
||||||
docker tag ${IMAGE}:${META_TAG} ${PUSHIMAGE}:${META_TAG}
|
|
||||||
docker tag ${PUSHIMAGE}:${META_TAG} ${PUSHIMAGE}:latest
|
|
||||||
docker tag ${PUSHIMAGE}:${META_TAG} ${PUSHIMAGE}:${EXT_RELEASE_TAG}
|
|
||||||
if [ -n "${SEMVER}" ]; then
|
|
||||||
docker tag ${PUSHIMAGE}:${META_TAG} ${PUSHIMAGE}:${SEMVER}
|
|
||||||
fi
|
|
||||||
docker push ${PUSHIMAGE}:latest
|
|
||||||
docker push ${PUSHIMAGE}:${META_TAG}
|
|
||||||
docker push ${PUSHIMAGE}:${EXT_RELEASE_TAG}
|
|
||||||
if [ -n "${SEMVER}" ]; then
|
|
||||||
docker push ${PUSHIMAGE}:${SEMVER}
|
|
||||||
fi
|
|
||||||
done
|
done
|
||||||
'''
|
docker buildx imagetools create --prefer-index=false -t ${PUSHIMAGE}:${META_TAG} -t ${PUSHIMAGE}:gpu -t ${PUSHIMAGE}:${EXT_RELEASE_TAG} ${CACHEIMAGE}:amd64-${COMMIT_SHA}-${BUILD_NUMBER} || \
|
||||||
}
|
{ if [[ "${PUSHIMAGE}" != "${QUAYIMAGE}" ]]; then exit 1; fi; }
|
||||||
|
if [ -n "${SEMVER}" ]; then
|
||||||
|
docker buildx imagetools create --prefer-index=false -t ${PUSHIMAGE}:${SEMVER} ${CACHEIMAGE}:amd64-${COMMIT_SHA}-${BUILD_NUMBER} || \
|
||||||
|
{ if [[ "${PUSHIMAGE}" != "${QUAYIMAGE}" ]]; then exit 1; fi; }
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
'''
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -804,64 +950,48 @@ pipeline {
|
|||||||
environment name: 'EXIT_STATUS', value: ''
|
environment name: 'EXIT_STATUS', value: ''
|
||||||
}
|
}
|
||||||
steps {
|
steps {
|
||||||
withCredentials([
|
retry_backoff(5,5) {
|
||||||
[
|
sh '''#! /bin/bash
|
||||||
$class: 'UsernamePasswordMultiBinding',
|
set -e
|
||||||
credentialsId: 'Quay.io-Robot',
|
for MANIFESTIMAGE in "${IMAGE}" "${GITLABIMAGE}" "${GITHUBIMAGE}" "${QUAYIMAGE}"; do
|
||||||
usernameVariable: 'QUAYUSER',
|
[[ ${MANIFESTIMAGE%%/*} =~ \\. ]] && MANIFESTIMAGEPLUS="${MANIFESTIMAGE}" || MANIFESTIMAGEPLUS="docker.io/${MANIFESTIMAGE}"
|
||||||
passwordVariable: 'QUAYPASS'
|
IFS=',' read -ra CACHE <<< "$BUILDCACHE"
|
||||||
]
|
for i in "${CACHE[@]}"; do
|
||||||
]) {
|
if [[ "${MANIFESTIMAGEPLUS}" == "$(cut -d "/" -f1 <<< ${i})"* ]]; then
|
||||||
retry_backoff(5,5) {
|
CACHEIMAGE=${i}
|
||||||
sh '''#! /bin/bash
|
fi
|
||||||
set -e
|
done
|
||||||
echo $DOCKERHUB_TOKEN | docker login -u linuxserverci --password-stdin
|
docker buildx imagetools create --prefer-index=false -t ${MANIFESTIMAGE}:amd64-${META_TAG} -t ${MANIFESTIMAGE}:amd64-gpu -t ${MANIFESTIMAGE}:amd64-${EXT_RELEASE_TAG} ${CACHEIMAGE}:amd64-${COMMIT_SHA}-${BUILD_NUMBER} || \
|
||||||
echo $GITHUB_TOKEN | docker login ghcr.io -u LinuxServer-CI --password-stdin
|
{ if [[ "${MANIFESTIMAGE}" != "${QUAYIMAGE}" ]]; then exit 1; fi; }
|
||||||
echo $GITLAB_TOKEN | docker login registry.gitlab.com -u LinuxServer.io --password-stdin
|
docker buildx imagetools create --prefer-index=false -t ${MANIFESTIMAGE}:arm64v8-${META_TAG} -t ${MANIFESTIMAGE}:arm64v8-gpu -t ${MANIFESTIMAGE}:arm64v8-${EXT_RELEASE_TAG} ${CACHEIMAGE}:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER} || \
|
||||||
echo $QUAYPASS | docker login quay.io -u $QUAYUSER --password-stdin
|
{ if [[ "${MANIFESTIMAGE}" != "${QUAYIMAGE}" ]]; then exit 1; fi; }
|
||||||
if [ "${CI}" == "false" ]; then
|
if [ -n "${SEMVER}" ]; then
|
||||||
docker pull ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER} --platform=arm64
|
docker buildx imagetools create --prefer-index=false -t ${MANIFESTIMAGE}:amd64-${SEMVER} ${CACHEIMAGE}:amd64-${COMMIT_SHA}-${BUILD_NUMBER} || \
|
||||||
docker tag ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER} ${IMAGE}:arm64v8-${META_TAG}
|
{ if [[ "${MANIFESTIMAGE}" != "${QUAYIMAGE}" ]]; then exit 1; fi; }
|
||||||
|
docker buildx imagetools create --prefer-index=false -t ${MANIFESTIMAGE}:arm64v8-${SEMVER} ${CACHEIMAGE}:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER} || \
|
||||||
|
{ if [[ "${MANIFESTIMAGE}" != "${QUAYIMAGE}" ]]; then exit 1; fi; }
|
||||||
fi
|
fi
|
||||||
for MANIFESTIMAGE in "${IMAGE}" "${GITLABIMAGE}" "${GITHUBIMAGE}" "${QUAYIMAGE}"; do
|
done
|
||||||
docker tag ${IMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-${META_TAG}
|
for MANIFESTIMAGE in "${IMAGE}" "${GITLABIMAGE}" "${GITHUBIMAGE}" "${QUAYIMAGE}"; do
|
||||||
docker tag ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-latest
|
docker buildx imagetools create -t ${MANIFESTIMAGE}:gpu ${MANIFESTIMAGE}:amd64-gpu ${MANIFESTIMAGE}:arm64v8-gpu || \
|
||||||
docker tag ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-${EXT_RELEASE_TAG}
|
{ if [[ "${MANIFESTIMAGE}" != "${QUAYIMAGE}" ]]; then exit 1; fi; }
|
||||||
docker tag ${IMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${META_TAG}
|
docker buildx imagetools create -t ${MANIFESTIMAGE}:${META_TAG} ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${META_TAG} || \
|
||||||
docker tag ${MANIFESTIMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-latest
|
{ if [[ "${MANIFESTIMAGE}" != "${QUAYIMAGE}" ]]; then exit 1; fi; }
|
||||||
docker tag ${MANIFESTIMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${EXT_RELEASE_TAG}
|
docker buildx imagetools create -t ${MANIFESTIMAGE}:${EXT_RELEASE_TAG} ${MANIFESTIMAGE}:amd64-${EXT_RELEASE_TAG} ${MANIFESTIMAGE}:arm64v8-${EXT_RELEASE_TAG} || \
|
||||||
if [ -n "${SEMVER}" ]; then
|
{ if [[ "${MANIFESTIMAGE}" != "${QUAYIMAGE}" ]]; then exit 1; fi; }
|
||||||
docker tag ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-${SEMVER}
|
if [ -n "${SEMVER}" ]; then
|
||||||
docker tag ${MANIFESTIMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${SEMVER}
|
docker buildx imagetools create -t ${MANIFESTIMAGE}:${SEMVER} ${MANIFESTIMAGE}:amd64-${SEMVER} ${MANIFESTIMAGE}:arm64v8-${SEMVER} || \
|
||||||
fi
|
{ if [[ "${MANIFESTIMAGE}" != "${QUAYIMAGE}" ]]; then exit 1; fi; }
|
||||||
docker push ${MANIFESTIMAGE}:amd64-${META_TAG}
|
fi
|
||||||
docker push ${MANIFESTIMAGE}:amd64-${EXT_RELEASE_TAG}
|
done
|
||||||
docker push ${MANIFESTIMAGE}:amd64-latest
|
'''
|
||||||
docker push ${MANIFESTIMAGE}:arm64v8-${META_TAG}
|
|
||||||
docker push ${MANIFESTIMAGE}:arm64v8-latest
|
|
||||||
docker push ${MANIFESTIMAGE}:arm64v8-${EXT_RELEASE_TAG}
|
|
||||||
if [ -n "${SEMVER}" ]; then
|
|
||||||
docker push ${MANIFESTIMAGE}:amd64-${SEMVER}
|
|
||||||
docker push ${MANIFESTIMAGE}:arm64v8-${SEMVER}
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
for MANIFESTIMAGE in "${IMAGE}" "${GITLABIMAGE}" "${GITHUBIMAGE}" "${QUAYIMAGE}"; do
|
|
||||||
docker buildx imagetools create -t ${MANIFESTIMAGE}:latest ${MANIFESTIMAGE}:amd64-latest ${MANIFESTIMAGE}:arm64v8-latest
|
|
||||||
docker buildx imagetools create -t ${MANIFESTIMAGE}:${META_TAG} ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${META_TAG}
|
|
||||||
docker buildx imagetools create -t ${MANIFESTIMAGE}:${EXT_RELEASE_TAG} ${MANIFESTIMAGE}:amd64-${EXT_RELEASE_TAG} ${MANIFESTIMAGE}:arm64v8-${EXT_RELEASE_TAG}
|
|
||||||
if [ -n "${SEMVER}" ]; then
|
|
||||||
docker buildx imagetools create -t ${MANIFESTIMAGE}:${SEMVER} ${MANIFESTIMAGE}:amd64-${SEMVER} ${MANIFESTIMAGE}:arm64v8-${SEMVER}
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
'''
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// 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 "gpu"
|
||||||
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
|
||||||
}
|
}
|
||||||
@ -869,36 +999,54 @@ pipeline {
|
|||||||
environment name: 'EXIT_STATUS', value: ''
|
environment name: 'EXIT_STATUS', value: ''
|
||||||
}
|
}
|
||||||
steps {
|
steps {
|
||||||
echo "Pushing New tag for current commit ${META_TAG}"
|
|
||||||
sh '''curl -H "Authorization: token ${GITHUB_TOKEN}" -X POST https://api.github.com/repos/${LS_USER}/${LS_REPO}/git/tags \
|
|
||||||
-d '{"tag":"'${META_TAG}'",\
|
|
||||||
"object": "'${COMMIT_SHA}'",\
|
|
||||||
"message": "Tagging Release '${EXT_RELEASE_CLEAN}'-ls'${LS_TAG_NUMBER}' to main",\
|
|
||||||
"type": "commit",\
|
|
||||||
"tagger": {"name": "LinuxServer-CI","email": "ci@linuxserver.io","date": "'${GITHUB_DATE}'"}}' '''
|
|
||||||
echo "Pushing New release for Tag"
|
|
||||||
sh '''#! /bin/bash
|
sh '''#! /bin/bash
|
||||||
|
echo "Auto-generating release notes"
|
||||||
|
if [ "$(git tag --points-at HEAD)" != "" ]; then
|
||||||
|
echo "Existing tag points to current commit, suggesting no new LS changes"
|
||||||
|
AUTO_RELEASE_NOTES="No changes"
|
||||||
|
else
|
||||||
|
AUTO_RELEASE_NOTES=$(curl -fsL -H "Authorization: token ${GITHUB_TOKEN}" -H "Accept: application/vnd.github+json" -X POST https://api.github.com/repos/${LS_USER}/${LS_REPO}/releases/generate-notes \
|
||||||
|
-d '{"tag_name":"'${META_TAG}'",\
|
||||||
|
"target_commitish": "gpu"}' \
|
||||||
|
| jq -r '.body' | sed 's|## What.s Changed||')
|
||||||
|
fi
|
||||||
|
echo "Pushing New tag for current commit ${META_TAG}"
|
||||||
|
curl -H "Authorization: token ${GITHUB_TOKEN}" -X POST https://api.github.com/repos/${LS_USER}/${LS_REPO}/git/tags \
|
||||||
|
-d '{"tag":"'${META_TAG}'",\
|
||||||
|
"object": "'${COMMIT_SHA}'",\
|
||||||
|
"message": "Tagging Release '${EXT_RELEASE_CLEAN}'-ls'${LS_TAG_NUMBER}' to gpu",\
|
||||||
|
"type": "commit",\
|
||||||
|
"tagger": {"name": "LinuxServer-CI","email": "ci@linuxserver.io","date": "'${GITHUB_DATE}'"}}'
|
||||||
|
echo "Pushing New release for Tag"
|
||||||
echo "Updating PIP version of ${EXT_PIP} to ${EXT_RELEASE_CLEAN}" > releasebody.json
|
echo "Updating PIP version of ${EXT_PIP} to ${EXT_RELEASE_CLEAN}" > releasebody.json
|
||||||
echo '{"tag_name":"'${META_TAG}'",\
|
jq -n \
|
||||||
"target_commitish": "main",\
|
--arg tag_name "$META_TAG" \
|
||||||
"name": "'${META_TAG}'",\
|
--arg target_commitish "gpu" \
|
||||||
"body": "**CI Report:**\\n\\n'${CI_URL:-N/A}'\\n\\n**LinuxServer Changes:**\\n\\n'${LS_RELEASE_NOTES}'\\n\\n**PIP Changes:**\\n\\n' > start
|
--arg ci_url "${CI_URL:-N/A}" \
|
||||||
printf '","draft": false,"prerelease": false}' >> releasebody.json
|
--arg ls_notes "$AUTO_RELEASE_NOTES" \
|
||||||
paste -d'\\0' start releasebody.json > releasebody.json.done
|
--arg remote_notes "$(cat releasebody.json)" \
|
||||||
curl -H "Authorization: token ${GITHUB_TOKEN}" -X POST https://api.github.com/repos/${LS_USER}/${LS_REPO}/releases -d @releasebody.json.done'''
|
'{
|
||||||
|
"tag_name": $tag_name,
|
||||||
|
"target_commitish": $target_commitish,
|
||||||
|
"name": $tag_name,
|
||||||
|
"body": ("**CI Report:**\\n\\n" + $ci_url + "\\n\\n**LinuxServer Changes:**\\n\\n" + $ls_notes + "\\n\\n**Remote Changes:**\\n\\n" + $remote_notes),
|
||||||
|
"draft": false,
|
||||||
|
"prerelease": true }' > 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
|
||||||
|
'''
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// Add protection to the release branch
|
// Add protection to the release branch
|
||||||
stage('Github-Release-Branch-Protection') {
|
stage('Github-Release-Branch-Protection') {
|
||||||
when {
|
when {
|
||||||
branch "main"
|
branch "gpu"
|
||||||
environment name: 'CHANGE_ID', value: ''
|
environment name: 'CHANGE_ID', value: ''
|
||||||
environment name: 'EXIT_STATUS', value: ''
|
environment name: 'EXIT_STATUS', value: ''
|
||||||
}
|
}
|
||||||
steps {
|
steps {
|
||||||
echo "Setting up protection for release branch main"
|
echo "Setting up protection for release branch gpu"
|
||||||
sh '''#! /bin/bash
|
sh '''#! /bin/bash
|
||||||
curl -H "Authorization: token ${GITHUB_TOKEN}" -X PUT https://api.github.com/repos/${LS_USER}/${LS_REPO}/branches/main/protection \
|
curl -H "Authorization: token ${GITHUB_TOKEN}" -X PUT https://api.github.com/repos/${LS_USER}/${LS_REPO}/branches/gpu/protection \
|
||||||
-d $(jq -c . << EOF
|
-d $(jq -c . << EOF
|
||||||
{
|
{
|
||||||
"required_status_checks": null,
|
"required_status_checks": null,
|
||||||
@ -1060,12 +1208,22 @@ EOF
|
|||||||
}
|
}
|
||||||
cleanup {
|
cleanup {
|
||||||
sh '''#! /bin/bash
|
sh '''#! /bin/bash
|
||||||
echo "Performing docker system prune!!"
|
echo "Pruning builder!!"
|
||||||
containers=$(docker ps -aq)
|
docker builder prune -f --builder container || :
|
||||||
|
containers=$(docker ps -q)
|
||||||
if [[ -n "${containers}" ]]; then
|
if [[ -n "${containers}" ]]; then
|
||||||
docker stop ${containers}
|
BUILDX_CONTAINER_ID=$(docker ps -qf 'name=buildx_buildkit')
|
||||||
|
for container in ${containers}; do
|
||||||
|
if [[ "${container}" == "${BUILDX_CONTAINER_ID}" ]]; then
|
||||||
|
echo "skipping buildx container in docker stop"
|
||||||
|
else
|
||||||
|
echo "Stopping container ${container}"
|
||||||
|
docker stop ${container}
|
||||||
|
fi
|
||||||
|
done
|
||||||
fi
|
fi
|
||||||
docker system prune -af --volumes || :
|
docker system prune -f --volumes || :
|
||||||
|
docker image prune -af || :
|
||||||
'''
|
'''
|
||||||
cleanWs()
|
cleanWs()
|
||||||
}
|
}
|
||||||
|
|||||||
61
README.md
61
README.md
@ -1,11 +1,10 @@
|
|||||||
<!-- DO NOT EDIT THIS FILE MANUALLY -->
|
<!-- DO NOT EDIT THIS FILE MANUALLY -->
|
||||||
<!-- Please read https://github.com/linuxserver/docker-piper/blob/main/.github/CONTRIBUTING.md -->
|
<!-- Please read https://github.com/linuxserver/docker-piper/blob/gpu/.github/CONTRIBUTING.md -->
|
||||||
[](https://linuxserver.io)
|
[](https://linuxserver.io)
|
||||||
|
|
||||||
[](https://blog.linuxserver.io "all the things you can do with our containers including How-To guides, opinions and much more!")
|
[](https://blog.linuxserver.io "all the things you can do with our containers including How-To guides, opinions and much more!")
|
||||||
[](https://discord.gg/YWrKVTn "realtime support / chat with the community and the team.")
|
[](https://linuxserver.io/discord "realtime support / chat with the community and the team.")
|
||||||
[](https://discourse.linuxserver.io "post on our community forum.")
|
[](https://discourse.linuxserver.io "post on our community forum.")
|
||||||
[](https://fleet.linuxserver.io "an online web interface which displays all of our maintained images.")
|
|
||||||
[](https://github.com/linuxserver "view the source for all of our repositories.")
|
[](https://github.com/linuxserver "view the source for all of our repositories.")
|
||||||
[](https://opencollective.com/linuxserver "please consider helping us by either donating or contributing to our budget")
|
[](https://opencollective.com/linuxserver "please consider helping us by either donating or contributing to our budget")
|
||||||
|
|
||||||
@ -20,9 +19,8 @@ The [LinuxServer.io](https://linuxserver.io) team brings you another container r
|
|||||||
Find us at:
|
Find us at:
|
||||||
|
|
||||||
* [Blog](https://blog.linuxserver.io) - all the things you can do with our containers including How-To guides, opinions and much more!
|
* [Blog](https://blog.linuxserver.io) - all the things you can do with our containers including How-To guides, opinions and much more!
|
||||||
* [Discord](https://discord.gg/YWrKVTn) - realtime support / chat with the community and the team.
|
* [Discord](https://linuxserver.io/discord) - realtime support / chat with the community and the team.
|
||||||
* [Discourse](https://discourse.linuxserver.io) - post on our community forum.
|
* [Discourse](https://discourse.linuxserver.io) - post on our community forum.
|
||||||
* [Fleet](https://fleet.linuxserver.io) - an online web interface which displays all of our maintained images.
|
|
||||||
* [GitHub](https://github.com/linuxserver) - view the source for all of our repositories.
|
* [GitHub](https://github.com/linuxserver) - view the source for all of our repositories.
|
||||||
* [Open Collective](https://opencollective.com/linuxserver) - please consider helping us by either donating or contributing to our budget
|
* [Open Collective](https://opencollective.com/linuxserver) - please consider helping us by either donating or contributing to our budget
|
||||||
|
|
||||||
@ -36,34 +34,43 @@ Find us at:
|
|||||||
[](https://quay.io/repository/linuxserver.io/piper)
|
[](https://quay.io/repository/linuxserver.io/piper)
|
||||||
[](https://hub.docker.com/r/linuxserver/piper)
|
[](https://hub.docker.com/r/linuxserver/piper)
|
||||||
[](https://hub.docker.com/r/linuxserver/piper)
|
[](https://hub.docker.com/r/linuxserver/piper)
|
||||||
[](https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-piper/job/main/)
|
[](https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-piper/job/gpu/)
|
||||||
[](https://ci-tests.linuxserver.io/linuxserver/piper/latest/index.html)
|
[](https://ci-tests.linuxserver.io/linuxserver/piper/gpu/index.html)
|
||||||
|
|
||||||
[Piper](https://github.com/rhasspy/piper/) is a fast, local neural text to speech system that sounds great and is optimized for the Raspberry Pi 4. This container provides a Wyoming protocol server for Piper.
|
[Piper](https://github.com/rhasspy/wyoming-piper) is a fast, local neural text to speech system that sounds great and is optimized for the Raspberry Pi 4. This container provides a Wyoming protocol server for Piper.
|
||||||
|
|
||||||
[](https://github.com/rhasspy/piper/)
|
[](https://github.com/rhasspy/wyoming-piper)
|
||||||
|
|
||||||
## Supported Architectures
|
## Supported Architectures
|
||||||
|
|
||||||
We utilise the docker manifest for multi-platform awareness. More information is available from docker [here](https://distribution.github.io/distribution/spec/manifest-v2-2/#manifest-list) and our announcement [here](https://blog.linuxserver.io/2019/02/21/the-lsio-pipeline-project/).
|
We utilise the docker manifest for multi-platform awareness. More information is available from docker [here](https://distribution.github.io/distribution/spec/manifest-v2-2/#manifest-list) and our announcement [here](https://blog.linuxserver.io/2019/02/21/the-lsio-pipeline-project/).
|
||||||
|
|
||||||
Simply pulling `lscr.io/linuxserver/piper:latest` should retrieve the correct image for your arch, but you can also pull specific arch images via tags.
|
Simply pulling `lscr.io/linuxserver/piper:gpu` 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 | Available | Tag |
|
| Architecture | Available | Tag |
|
||||||
| :----: | :----: | ---- |
|
| :----: | :----: | ---- |
|
||||||
| x86-64 | ✅ | amd64-\<version tag\> |
|
| x86-64 | ✅ | amd64-\<version tag\> |
|
||||||
| arm64 | ✅ | arm64v8-\<version tag\> |
|
| arm64 | ❌ | |
|
||||||
| armhf | ❌ | |
|
|
||||||
|
## Version Tags
|
||||||
|
|
||||||
|
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 | Available | Description |
|
||||||
|
| :----: | :----: |--- |
|
||||||
|
| latest | ✅ | Stable releases |
|
||||||
|
| gpu | ✅ | Releases with Nvidia GPU support (amd64 only) |
|
||||||
|
|
||||||
## Application Setup
|
## Application Setup
|
||||||
|
|
||||||
For use with Home Assistant [Assist](https://www.home-assistant.io/voice_control/voice_remote_local_assistant/), add the Wyoming integration and supply the hostname/IP and port that piper is running add-on."
|
For use with Home Assistant [Assist](https://www.home-assistant.io/voice_control/voice_remote_local_assistant/), add the Wyoming integration and supply the hostname/IP and port that piper is running add-on."
|
||||||
|
|
||||||
For more information see the [piper docs](https://github.com/rhasspy/piper/),
|
When using the `gpu` tag with Nvidia GPUs, make sure you set the container to use the `nvidia` runtime and that you have the [Nvidia Container Toolkit](https://github.com/NVIDIA/nvidia-container-toolkit) installed on the host and that you run the container with the correct GPU(s) exposed. See the [Nvidia Container Toolkit docs](https://docs.nvidia.com/datacenter/cloud-native/container-toolkit/latest/sample-workload.html) for more details.
|
||||||
|
|
||||||
|
For more information see the [wyoming piper docs](https://github.com/rhasspy/wyoming-piper),
|
||||||
|
|
||||||
|
|
||||||
## Read-Only Operation
|
## Read-Only Operation
|
||||||
|
|
||||||
This image can be run with a read-only container filesystem. For details please [read the docs](https://docs.linuxserver.io/misc/read-only/).
|
This image can be run with a read-only container filesystem. For details please [read the docs](https://docs.linuxserver.io/misc/read-only/).
|
||||||
@ -72,24 +79,28 @@ This image can be run with a read-only container filesystem. For details please
|
|||||||
|
|
||||||
To help you get started creating a container from this image you can either use docker-compose or the docker cli.
|
To help you get started creating a container from this image you can either use docker-compose or the docker cli.
|
||||||
|
|
||||||
|
>[!NOTE]
|
||||||
|
>Unless a parameter is flagged as 'optional', it is *mandatory* and a value must be provided.
|
||||||
|
|
||||||
### docker-compose (recommended, [click here for more info](https://docs.linuxserver.io/general/docker-compose))
|
### docker-compose (recommended, [click here for more info](https://docs.linuxserver.io/general/docker-compose))
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
---
|
---
|
||||||
services:
|
services:
|
||||||
piper:
|
piper:
|
||||||
image: lscr.io/linuxserver/piper:latest
|
image: lscr.io/linuxserver/piper:gpu
|
||||||
container_name: piper
|
container_name: piper
|
||||||
environment:
|
environment:
|
||||||
- PUID=1000
|
- PUID=1000
|
||||||
- PGID=1000
|
- PGID=1000
|
||||||
- TZ=Etc/UTC
|
- TZ=Etc/UTC
|
||||||
- PIPER_VOICE=en_US-lessac-medium
|
- PIPER_VOICE=en_US-lessac-medium
|
||||||
|
- LOCAL_ONLY= #optional
|
||||||
- PIPER_LENGTH=1.0 #optional
|
- PIPER_LENGTH=1.0 #optional
|
||||||
- PIPER_NOISE=0.667 #optional
|
- PIPER_NOISE=0.667 #optional
|
||||||
- PIPER_NOISEW=0.333 #optional
|
- PIPER_NOISEW=0.333 #optional
|
||||||
- PIPER_SPEAKER=0 #optional
|
- PIPER_SPEAKER=0 #optional
|
||||||
- PIPER_PROCS=1 #optional
|
- NO_STREAMING= #optional
|
||||||
volumes:
|
volumes:
|
||||||
- /path/to/piper/data:/config
|
- /path/to/piper/data:/config
|
||||||
ports:
|
ports:
|
||||||
@ -106,15 +117,16 @@ docker run -d \
|
|||||||
-e PGID=1000 \
|
-e PGID=1000 \
|
||||||
-e TZ=Etc/UTC \
|
-e TZ=Etc/UTC \
|
||||||
-e PIPER_VOICE=en_US-lessac-medium \
|
-e PIPER_VOICE=en_US-lessac-medium \
|
||||||
|
-e LOCAL_ONLY= `#optional` \
|
||||||
-e PIPER_LENGTH=1.0 `#optional` \
|
-e PIPER_LENGTH=1.0 `#optional` \
|
||||||
-e PIPER_NOISE=0.667 `#optional` \
|
-e PIPER_NOISE=0.667 `#optional` \
|
||||||
-e PIPER_NOISEW=0.333 `#optional` \
|
-e PIPER_NOISEW=0.333 `#optional` \
|
||||||
-e PIPER_SPEAKER=0 `#optional` \
|
-e PIPER_SPEAKER=0 `#optional` \
|
||||||
-e PIPER_PROCS=1 `#optional` \
|
-e NO_STREAMING= `#optional` \
|
||||||
-p 10200:10200 \
|
-p 10200:10200 \
|
||||||
-v /path/to/piper/data:/config \
|
-v /path/to/piper/data:/config \
|
||||||
--restart unless-stopped \
|
--restart unless-stopped \
|
||||||
lscr.io/linuxserver/piper:latest
|
lscr.io/linuxserver/piper:gpu
|
||||||
```
|
```
|
||||||
|
|
||||||
## Parameters
|
## Parameters
|
||||||
@ -123,16 +135,17 @@ Containers are configured using parameters passed at runtime (such as those abov
|
|||||||
|
|
||||||
| Parameter | Function |
|
| Parameter | Function |
|
||||||
| :----: | --- |
|
| :----: | --- |
|
||||||
| `-p 10200` | Wyoming connection port. |
|
| `-p 10200:10200` | Wyoming connection 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=Etc/UTC` | specify a timezone to use, see this [list](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones#List). |
|
| `-e TZ=Etc/UTC` | specify a timezone to use, see this [list](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones#List). |
|
||||||
| `-e PIPER_VOICE=en_US-lessac-medium` | The [Piper voice](https://huggingface.co/rhasspy/piper-voices/tree/main) to use, in the format `<language>-<name>-<quality>` |
|
| `-e PIPER_VOICE=en_US-lessac-medium` | The [Piper voice](https://huggingface.co/rhasspy/piper-voices/tree/main) to use, in the format `<language>-<name>-<quality>` |
|
||||||
|
| `-e LOCAL_ONLY=` | If set to `true`, or any other value, the container will not attempt to download models from HuggingFace and will only use locally-provided models. |
|
||||||
| `-e PIPER_LENGTH=1.0` | Voice speaking rate, 1.0 is default with < 1.0 being faster and > 1.0 being slower. |
|
| `-e PIPER_LENGTH=1.0` | Voice speaking rate, 1.0 is default with < 1.0 being faster and > 1.0 being slower. |
|
||||||
| `-e PIPER_NOISE=0.667` | Controls the variability of the voice by adding noise. Values above 1 will start to degrade audio. |
|
| `-e PIPER_NOISE=0.667` | Controls the variability of the voice by adding noise. Values above 1 will start to degrade audio. |
|
||||||
| `-e PIPER_NOISEW=0.333` | Controls the variability of speaking cadence. Values above 1 produce extreme stutters and pauses. |
|
| `-e PIPER_NOISEW=0.333` | Controls the variability of speaking cadence. Values above 1 produce extreme stutters and pauses. |
|
||||||
| `-e PIPER_SPEAKER=0` | Speaker number to use if the voice supports multiple speakers. |
|
| `-e PIPER_SPEAKER=0` | Speaker number to use if the voice supports multiple speakers. |
|
||||||
| `-e PIPER_PROCS=1` | Number of Piper processes to run simultaneously. |
|
| `-e NO_STREAMING=` | Setting to `true`, or any other value, will disable support for streaming audio on sentence boundaries. |
|
||||||
| `-v /config` | Local path for piper config files. |
|
| `-v /config` | Local path for piper config files. |
|
||||||
| `--read-only=true` | Run container with a read-only filesystem. Please [read the docs](https://docs.linuxserver.io/misc/read-only/). |
|
| `--read-only=true` | Run container with a read-only filesystem. Please [read the docs](https://docs.linuxserver.io/misc/read-only/). |
|
||||||
|
|
||||||
@ -200,7 +213,7 @@ We publish various [Docker Mods](https://github.com/linuxserver/docker-mods) to
|
|||||||
* Image version number:
|
* Image version number:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
docker inspect -f '{{ index .Config.Labels "build_version" }}' lscr.io/linuxserver/piper:latest
|
docker inspect -f '{{ index .Config.Labels "build_version" }}' lscr.io/linuxserver/piper:gpu
|
||||||
```
|
```
|
||||||
|
|
||||||
## Updating Info
|
## Updating Info
|
||||||
@ -248,7 +261,7 @@ Below are the instructions for updating containers:
|
|||||||
* Update the image:
|
* Update the image:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
docker pull lscr.io/linuxserver/piper:latest
|
docker pull lscr.io/linuxserver/piper:gpu
|
||||||
```
|
```
|
||||||
|
|
||||||
* Stop the running container:
|
* Stop the running container:
|
||||||
@ -285,7 +298,7 @@ cd docker-piper
|
|||||||
docker build \
|
docker build \
|
||||||
--no-cache \
|
--no-cache \
|
||||||
--pull \
|
--pull \
|
||||||
-t lscr.io/linuxserver/piper:latest .
|
-t lscr.io/linuxserver/piper:gpu .
|
||||||
```
|
```
|
||||||
|
|
||||||
The ARM variants can be built on x86_64 hardware and vice versa using `lscr.io/linuxserver/qemu-static`
|
The ARM variants can be built on x86_64 hardware and vice versa using `lscr.io/linuxserver/qemu-static`
|
||||||
@ -298,5 +311,7 @@ Once registered you can define the dockerfile to use with `-f Dockerfile.aarch64
|
|||||||
|
|
||||||
## Versions
|
## Versions
|
||||||
|
|
||||||
|
* **15.11.25:** - Add streaming support & support for local only mode.
|
||||||
|
* **26.11.24:** - Add GPU branch.
|
||||||
* **18.07.24:** - Rebase to Ubuntu Noble.
|
* **18.07.24:** - Rebase to Ubuntu Noble.
|
||||||
* **25.11.23:** - Initial Release.
|
* **25.11.23:** - Initial Release.
|
||||||
|
|||||||
@ -3,9 +3,9 @@
|
|||||||
# jenkins variables
|
# jenkins variables
|
||||||
project_name: docker-piper
|
project_name: docker-piper
|
||||||
external_type: pip_version
|
external_type: pip_version
|
||||||
release_type: stable
|
release_type: prerelease
|
||||||
release_tag: latest
|
release_tag: gpu
|
||||||
ls_branch: main
|
ls_branch: gpu
|
||||||
repo_vars:
|
repo_vars:
|
||||||
- EXT_PIP = 'wyoming-piper'
|
- EXT_PIP = 'wyoming-piper'
|
||||||
- BUILD_VERSION_ARG = 'PIPER_VERSION'
|
- BUILD_VERSION_ARG = 'PIPER_VERSION'
|
||||||
@ -16,7 +16,7 @@ repo_vars:
|
|||||||
- DEV_DOCKERHUB_IMAGE = 'lsiodev/piper'
|
- DEV_DOCKERHUB_IMAGE = 'lsiodev/piper'
|
||||||
- PR_DOCKERHUB_IMAGE = 'lspipepr/piper'
|
- PR_DOCKERHUB_IMAGE = 'lspipepr/piper'
|
||||||
- DIST_IMAGE = 'ubuntu'
|
- DIST_IMAGE = 'ubuntu'
|
||||||
- MULTIARCH='true'
|
- MULTIARCH='false'
|
||||||
- CI='true'
|
- CI='true'
|
||||||
- CI_WEB='false'
|
- CI_WEB='false'
|
||||||
- CI_DELAY='120'
|
- CI_DELAY='120'
|
||||||
|
|||||||
@ -1,160 +1,179 @@
|
|||||||
NAME VERSION TYPE
|
NAME VERSION TYPE
|
||||||
Simple Launcher 1.1.0.14 dotnet (+5 duplicates)
|
Simple Launcher 1.1.0.14 binary (+5 duplicates)
|
||||||
adduser 3.137ubuntu1 deb
|
adduser 3.137ubuntu1 deb
|
||||||
apt 2.7.14build2 deb
|
apt 2.8.3 deb
|
||||||
apt-utils 2.7.14build2 deb
|
apt-utils 2.8.3 deb
|
||||||
base-files 13ubuntu10.1 deb
|
base-files 13ubuntu10.4 deb
|
||||||
base-passwd 3.6.3build1 deb
|
base-passwd 3.6.3build1 deb
|
||||||
bash 5.2.21-2ubuntu4 deb
|
bash 5.2.21-2ubuntu4 deb
|
||||||
bsdutils 1:2.39.3-9ubuntu6.1 deb
|
bsdutils 1:2.39.3-9ubuntu6.4 deb
|
||||||
ca-certificates 20240203 deb
|
ca-certificates 20240203 deb
|
||||||
catatonit 0.1.7-1 deb
|
catatonit 0.1.7-1 deb
|
||||||
coreutils 9.4-3ubuntu6 deb
|
coreutils 9.4-3ubuntu6.1 deb
|
||||||
cron 3.0pl1-184ubuntu2 deb
|
cron 3.0pl1-184ubuntu2 deb
|
||||||
cron-daemon-common 3.0pl1-184ubuntu2 deb
|
cron-daemon-common 3.0pl1-184ubuntu2 deb
|
||||||
curl 8.5.0-2ubuntu10.4 deb
|
curl 8.5.0-2ubuntu10.7 deb
|
||||||
dash 0.5.12-6ubuntu5 deb
|
dash 0.5.12-6ubuntu5 deb
|
||||||
debconf 1.5.86ubuntu1 deb
|
debconf 1.5.86ubuntu1 deb
|
||||||
debianutils 5.17build1 deb
|
debianutils 5.17build1 deb
|
||||||
diffutils 1:3.10-1build1 deb
|
diffutils 1:3.10-1build1 deb
|
||||||
dirmngr 2.4.4-2ubuntu17 deb
|
dirmngr 2.4.4-2ubuntu17.4 deb
|
||||||
dpkg 1.22.6ubuntu6.1 deb
|
dpkg 1.22.6ubuntu6.5 deb
|
||||||
e2fsprogs 1.47.0-2.4~exp1ubuntu4.1 deb
|
e2fsprogs 1.47.0-2.4~exp1ubuntu4.1 deb
|
||||||
findutils 4.9.0-5build1 deb
|
findutils 4.9.0-5build1 deb
|
||||||
gcc-14-base 14.2.0-4ubuntu2~24.04 deb
|
flatbuffers 25.12.19 python
|
||||||
gnupg 2.4.4-2ubuntu17 deb
|
gcc-14-base 14.2.0-4ubuntu2~24.04.1 deb
|
||||||
gnupg-l10n 2.4.4-2ubuntu17 deb
|
gnupg 2.4.4-2ubuntu17.4 deb
|
||||||
gnupg-utils 2.4.4-2ubuntu17 deb
|
gnupg-l10n 2.4.4-2ubuntu17.4 deb
|
||||||
gpg 2.4.4-2ubuntu17 deb
|
gnupg-utils 2.4.4-2ubuntu17.4 deb
|
||||||
gpg-agent 2.4.4-2ubuntu17 deb
|
gpg 2.4.4-2ubuntu17.4 deb
|
||||||
gpg-wks-client 2.4.4-2ubuntu17 deb
|
gpg-agent 2.4.4-2ubuntu17.4 deb
|
||||||
gpgconf 2.4.4-2ubuntu17 deb
|
gpg-wks-client 2.4.4-2ubuntu17.4 deb
|
||||||
gpgsm 2.4.4-2ubuntu17 deb
|
gpgconf 2.4.4-2ubuntu17.4 deb
|
||||||
gpgv 2.4.4-2ubuntu17 deb
|
gpgsm 2.4.4-2ubuntu17.4 deb
|
||||||
|
gpgv 2.4.4-2ubuntu17.4 deb
|
||||||
grep 3.11-4build1 deb
|
grep 3.11-4build1 deb
|
||||||
gzip 1.12-1ubuntu3 deb
|
gzip 1.12-1ubuntu3.1 deb
|
||||||
hostname 3.23+nmu2ubuntu2 deb
|
hostname 3.23+nmu2ubuntu2 deb
|
||||||
init-system-helpers 1.66ubuntu1 deb
|
init-system-helpers 1.66ubuntu1 deb
|
||||||
jq 1.7.1-3build1 deb
|
jq 1.7.1-3ubuntu0.24.04.1 deb
|
||||||
keyboxd 2.4.4-2ubuntu17 deb
|
keyboxd 2.4.4-2ubuntu17.4 deb
|
||||||
krb5-locales 1.20.1-6ubuntu2.1 deb
|
krb5-locales 1.20.1-6ubuntu2.6 deb
|
||||||
libacl1 2.3.2-1build1 deb
|
libacl1 2.3.2-1build1.1 deb
|
||||||
libapt-pkg6.0t64 2.7.14build2 deb
|
libapt-pkg6.0t64 2.8.3 deb
|
||||||
libassuan0 2.5.6-1build1 deb
|
libassuan0 2.5.6-1build1 deb
|
||||||
libattr1 1:2.5.2-1build1 deb
|
libattr1 1:2.5.2-1build1.1 deb
|
||||||
libaudit-common 1:3.1.2-2.1build1 deb
|
libaudit-common 1:3.1.2-2.1build1.1 deb
|
||||||
libaudit1 1:3.1.2-2.1build1 deb
|
libaudit1 1:3.1.2-2.1build1.1 deb
|
||||||
libblkid1 2.39.3-9ubuntu6.1 deb
|
libblkid1 2.39.3-9ubuntu6.4 deb
|
||||||
libbrotli1 1.1.0-2build2 deb
|
libbrotli1 1.1.0-2build2 deb
|
||||||
libbsd0 0.12.1-1build1 deb
|
libbsd0 0.12.1-1build1.1 deb
|
||||||
libbz2-1.0 1.0.8-5.1build0.1 deb
|
libbz2-1.0 1.0.8-5.1build0.1 deb
|
||||||
libc-bin 2.39-0ubuntu8.3 deb
|
libc-bin 2.39-0ubuntu8.7 deb
|
||||||
libc6 2.39-0ubuntu8.3 deb
|
libc6 2.39-0ubuntu8.7 deb
|
||||||
libcap-ng0 0.8.4-2build2 deb
|
libcap-ng0 0.8.4-2build2 deb
|
||||||
libcap2 1:2.66-5ubuntu2 deb
|
libcap2 1:2.66-5ubuntu2.2 deb
|
||||||
libcom-err2 1.47.0-2.4~exp1ubuntu4.1 deb
|
libcom-err2 1.47.0-2.4~exp1ubuntu4.1 deb
|
||||||
libcrypt1 1:4.4.36-4build1 deb
|
libcrypt1 1:4.4.36-4build1 deb
|
||||||
libcurl4t64 8.5.0-2ubuntu10.4 deb
|
libcurl4t64 8.5.0-2ubuntu10.7 deb
|
||||||
libdb5.3t64 5.3.28+dfsg2-7 deb
|
libdb5.3t64 5.3.28+dfsg2-7 deb
|
||||||
libdebconfclient0 0.271ubuntu3 deb
|
libdebconfclient0 0.271ubuntu3 deb
|
||||||
libexpat1 2.6.1-2ubuntu0.1 deb
|
libexpat1 2.6.1-2ubuntu0.4 deb
|
||||||
libext2fs2t64 1.47.0-2.4~exp1ubuntu4.1 deb
|
libext2fs2t64 1.47.0-2.4~exp1ubuntu4.1 deb
|
||||||
libffi8 3.4.6-1build1 deb
|
libffi8 3.4.6-1build1 deb
|
||||||
libgcc-s1 14.2.0-4ubuntu2~24.04 deb
|
libgcc-s1 14.2.0-4ubuntu2~24.04.1 deb
|
||||||
libgcrypt20 1.10.3-2build1 deb
|
libgcrypt20 1.10.3-2build1 deb
|
||||||
libgmp10 2:6.3.0+dfsg-2ubuntu6 deb
|
libgmp10 2:6.3.0+dfsg-2ubuntu6.1 deb
|
||||||
libgnutls30t64 3.8.3-1.1ubuntu3.2 deb
|
libgnutls30t64 3.8.3-1.1ubuntu3.5 deb
|
||||||
libgpg-error0 1.47-3build2 deb
|
libgpg-error0 1.47-3build2.1 deb
|
||||||
libgssapi-krb5-2 1.20.1-6ubuntu2.1 deb
|
libgssapi-krb5-2 1.20.1-6ubuntu2.6 deb
|
||||||
libhogweed6t64 3.9.1-2.2build1.1 deb
|
libhogweed6t64 3.9.1-2.2build1.1 deb
|
||||||
libidn2-0 2.3.7-2build1 deb
|
libidn2-0 2.3.7-2build1.1 deb
|
||||||
libjq1 1.7.1-3build1 deb
|
libjq1 1.7.1-3ubuntu0.24.04.1 deb
|
||||||
libk5crypto3 1.20.1-6ubuntu2.1 deb
|
libk5crypto3 1.20.1-6ubuntu2.6 deb
|
||||||
libkeyutils1 1.6.3-3build1 deb
|
libkeyutils1 1.6.3-3build1 deb
|
||||||
libkrb5-3 1.20.1-6ubuntu2.1 deb
|
libkrb5-3 1.20.1-6ubuntu2.6 deb
|
||||||
libkrb5support0 1.20.1-6ubuntu2.1 deb
|
libkrb5support0 1.20.1-6ubuntu2.6 deb
|
||||||
libksba8 1.6.6-1build1 deb
|
libksba8 1.6.6-1build1 deb
|
||||||
libldap-common 2.6.7+dfsg-1~exp1ubuntu8 deb
|
libldap-common 2.6.10+dfsg-0ubuntu0.24.04.1 deb
|
||||||
libldap2 2.6.7+dfsg-1~exp1ubuntu8 deb
|
libldap2 2.6.10+dfsg-0ubuntu0.24.04.1 deb
|
||||||
liblz4-1 1.9.4-1build1.1 deb
|
liblz4-1 1.9.4-1build1.1 deb
|
||||||
liblzma5 5.6.1+really5.4.5-1build0.1 deb
|
liblzma5 5.6.1+really5.4.5-1ubuntu0.2 deb
|
||||||
libmd0 1.1.0-2build1 deb
|
libmd0 1.1.0-2build1.1 deb
|
||||||
libmount1 2.39.3-9ubuntu6.1 deb
|
libmount1 2.39.3-9ubuntu6.4 deb
|
||||||
libncursesw6 6.4+20240113-1ubuntu2 deb
|
libncursesw6 6.4+20240113-1ubuntu2 deb
|
||||||
libnettle8t64 3.9.1-2.2build1.1 deb
|
libnettle8t64 3.9.1-2.2build1.1 deb
|
||||||
libnghttp2-14 1.59.0-1ubuntu0.1 deb
|
libnghttp2-14 1.59.0-1ubuntu0.2 deb
|
||||||
libnpth0t64 1.6-3.1build1 deb
|
libnpth0t64 1.6-3.1build1 deb
|
||||||
libonig5 6.9.9-1build1 deb
|
libonig5 6.9.9-1build1 deb
|
||||||
libp11-kit0 0.25.3-4ubuntu2.1 deb
|
libp11-kit0 0.25.3-4ubuntu2.1 deb
|
||||||
libpam-modules 1.5.3-5ubuntu5.1 deb
|
libpam-modules 1.5.3-5ubuntu5.5 deb
|
||||||
libpam-modules-bin 1.5.3-5ubuntu5.1 deb
|
libpam-modules-bin 1.5.3-5ubuntu5.5 deb
|
||||||
libpam-runtime 1.5.3-5ubuntu5.1 deb
|
libpam-runtime 1.5.3-5ubuntu5.5 deb
|
||||||
libpam0g 1.5.3-5ubuntu5.1 deb
|
libpam0g 1.5.3-5ubuntu5.5 deb
|
||||||
libpcre2-8-0 10.42-4ubuntu2 deb
|
libpcre2-8-0 10.42-4ubuntu2.1 deb
|
||||||
libproc2-0 2:4.0.4-4ubuntu3.2 deb
|
libproc2-0 2:4.0.4-4ubuntu3.2 deb
|
||||||
libpsl5t64 0.21.2-1.1build1 deb
|
libpsl5t64 0.21.2-1.1build1 deb
|
||||||
libpython3-stdlib 3.12.3-0ubuntu2 deb
|
libpython3-stdlib 3.12.3-0ubuntu2.1 deb
|
||||||
libpython3.12-minimal 3.12.3-1ubuntu0.3 deb
|
libpython3.12-minimal 3.12.3-1ubuntu0.12 deb
|
||||||
libpython3.12-stdlib 3.12.3-1ubuntu0.3 deb
|
libpython3.12-stdlib 3.12.3-1ubuntu0.12 deb
|
||||||
libreadline8t64 8.2-4build1 deb
|
libreadline8t64 8.2-4build1 deb
|
||||||
librtmp1 2.4+20151223.gitfa8646d.1-2build7 deb
|
librtmp1 2.4+20151223.gitfa8646d.1-2build7 deb
|
||||||
libsasl2-2 2.1.28+dfsg1-5ubuntu3.1 deb
|
libsasl2-2 2.1.28+dfsg1-5ubuntu3.1 deb
|
||||||
libsasl2-modules 2.1.28+dfsg1-5ubuntu3.1 deb
|
libsasl2-modules 2.1.28+dfsg1-5ubuntu3.1 deb
|
||||||
libsasl2-modules-db 2.1.28+dfsg1-5ubuntu3.1 deb
|
libsasl2-modules-db 2.1.28+dfsg1-5ubuntu3.1 deb
|
||||||
libseccomp2 2.5.5-1ubuntu3.1 deb
|
libseccomp2 2.5.5-1ubuntu3.1 deb
|
||||||
libselinux1 3.5-2ubuntu2 deb
|
libselinux1 3.5-2ubuntu2.1 deb
|
||||||
libsemanage-common 3.5-1build5 deb
|
libsemanage-common 3.5-1build5 deb
|
||||||
libsemanage2 3.5-1build5 deb
|
libsemanage2 3.5-1build5 deb
|
||||||
libsepol2 3.5-2build1 deb
|
libsepol2 3.5-2build1 deb
|
||||||
libsmartcols1 2.39.3-9ubuntu6.1 deb
|
libsmartcols1 2.39.3-9ubuntu6.4 deb
|
||||||
libsqlite3-0 3.45.1-1ubuntu2 deb
|
libsqlite3-0 3.45.1-1ubuntu2.5 deb
|
||||||
libss2 1.47.0-2.4~exp1ubuntu4.1 deb
|
libss2 1.47.0-2.4~exp1ubuntu4.1 deb
|
||||||
libssh-4 0.10.6-2build2 deb
|
libssh-4 0.10.6-2ubuntu0.3 deb
|
||||||
libssl3t64 3.0.13-0ubuntu3.4 deb
|
libssl3t64 3.0.13-0ubuntu3.7 deb
|
||||||
libstdc++6 14.2.0-4ubuntu2~24.04 deb
|
libstdc++6 14.2.0-4ubuntu2~24.04.1 deb
|
||||||
libsystemd0 255.4-1ubuntu8.4 deb
|
libsystemd0 255.4-1ubuntu8.12 deb
|
||||||
libtasn1-6 4.19.0-3build1 deb
|
libtasn1-6 4.19.0-3ubuntu0.24.04.2 deb
|
||||||
libtinfo6 6.4+20240113-1ubuntu2 deb
|
libtinfo6 6.4+20240113-1ubuntu2 deb
|
||||||
libudev1 255.4-1ubuntu8.4 deb
|
libudev1 255.4-1ubuntu8.12 deb
|
||||||
libunistring5 1.1-2build1 deb
|
libunistring5 1.1-2build1.1 deb
|
||||||
libuuid1 2.39.3-9ubuntu6.1 deb
|
libuuid1 2.39.3-9ubuntu6.4 deb
|
||||||
libxxhash0 0.8.2-2build1 deb
|
libxxhash0 0.8.2-2build1 deb
|
||||||
libzstd1 1.5.5+dfsg2-2build1.1 deb
|
libzstd1 1.5.5+dfsg2-2build1.1 deb
|
||||||
locales 2.39-0ubuntu8.3 deb
|
locales 2.39-0ubuntu8.7 deb
|
||||||
login 1:4.13+dfsg1-4ubuntu3.2 deb
|
login 1:4.13+dfsg1-4ubuntu3.2 deb
|
||||||
logsave 1.47.0-2.4~exp1ubuntu4.1 deb
|
logsave 1.47.0-2.4~exp1ubuntu4.1 deb
|
||||||
mawk 1.3.4.20240123-1build1 deb
|
mawk 1.3.4.20240123-1build1 deb
|
||||||
media-types 10.1.0 deb
|
media-types 10.1.0 deb
|
||||||
mount 2.39.3-9ubuntu6.1 deb
|
mount 2.39.3-9ubuntu6.4 deb
|
||||||
|
mpmath 1.3.0 python
|
||||||
ncurses-base 6.4+20240113-1ubuntu2 deb
|
ncurses-base 6.4+20240113-1ubuntu2 deb
|
||||||
ncurses-bin 6.4+20240113-1ubuntu2 deb
|
ncurses-bin 6.4+20240113-1ubuntu2 deb
|
||||||
netbase 6.4 deb
|
netbase 6.4 deb
|
||||||
netcat-openbsd 1.226-1ubuntu2 deb
|
netcat-openbsd 1.226-1ubuntu2 deb
|
||||||
openssl 3.0.13-0ubuntu3.4 deb
|
numpy 2.4.3 python
|
||||||
|
nvidia-cublas-cu12 12.9.1.4 python
|
||||||
|
nvidia-cuda-nvrtc-cu12 12.9.86 python
|
||||||
|
nvidia-cuda-runtime-cu12 12.9.79 python
|
||||||
|
nvidia-cudnn-cu12 9.19.0.56 python
|
||||||
|
nvidia-cufft-cu12 11.4.1.4 python
|
||||||
|
nvidia-curand-cu12 10.3.10.19 python
|
||||||
|
nvidia-nvjitlink-cu12 12.9.86 python
|
||||||
|
onnxruntime 1.24.3 python
|
||||||
|
onnxruntime-gpu 1.24.3 python
|
||||||
|
openssl 3.0.13-0ubuntu3.7 deb
|
||||||
|
packaging 26.0 python
|
||||||
passwd 1:4.13+dfsg1-4ubuntu3.2 deb
|
passwd 1:4.13+dfsg1-4ubuntu3.2 deb
|
||||||
perl-base 5.38.2-3.2build2 deb
|
perl-base 5.38.2-3.2ubuntu0.2 deb
|
||||||
pinentry-curses 1.2.1-3ubuntu5 deb
|
pinentry-curses 1.2.1-3ubuntu5 deb
|
||||||
pip 24.3.1 python
|
pip 26.0.1 python
|
||||||
|
piper-tts 1.4.1 python
|
||||||
procps 2:4.0.4-4ubuntu3.2 deb
|
procps 2:4.0.4-4ubuntu3.2 deb
|
||||||
|
protobuf 7.34.0 python
|
||||||
publicsuffix 20231001.0357-0.1 deb
|
publicsuffix 20231001.0357-0.1 deb
|
||||||
python3 3.12.3-0ubuntu2 deb
|
python3 3.12.3-0ubuntu2.1 deb
|
||||||
python3-minimal 3.12.3-0ubuntu2 deb
|
python3-minimal 3.12.3-0ubuntu2.1 deb
|
||||||
python3-pip-whl 24.0+dfsg-1ubuntu1.1 deb
|
python3-pip-whl 24.0+dfsg-1ubuntu1.3 deb
|
||||||
python3-setuptools-whl 68.1.2-2ubuntu1.1 deb
|
python3-setuptools-whl 68.1.2-2ubuntu1.2 deb
|
||||||
python3-venv 3.12.3-0ubuntu2 deb
|
python3-venv 3.12.3-0ubuntu2.1 deb
|
||||||
python3.12 3.12.3-1ubuntu0.3 deb
|
python3.12 3.12.3-1ubuntu0.12 deb
|
||||||
python3.12-minimal 3.12.3-1ubuntu0.3 deb
|
python3.12-minimal 3.12.3-1ubuntu0.12 deb
|
||||||
python3.12-venv 3.12.3-1ubuntu0.3 deb
|
python3.12-venv 3.12.3-1ubuntu0.12 deb
|
||||||
readline-common 8.2-4build1 deb
|
readline-common 8.2-4build1 deb
|
||||||
|
regex 2026.2.28 python
|
||||||
sed 4.9-2build1 deb
|
sed 4.9-2build1 deb
|
||||||
sensible-utils 0.0.22 deb
|
sensible-utils 0.0.22 deb
|
||||||
systemd-standalone-sysusers 255.4-1ubuntu8.4 deb
|
sentence-stream 1.3.0 python
|
||||||
|
sympy 1.14.0 python
|
||||||
|
systemd-standalone-sysusers 255.4-1ubuntu8.12 deb
|
||||||
sysvinit-utils 3.08-6ubuntu3 deb
|
sysvinit-utils 3.08-6ubuntu3 deb
|
||||||
tar 1.35+dfsg-3build1 deb
|
tar 1.35+dfsg-3build1 deb
|
||||||
tzdata 2024a-3ubuntu1.1 deb
|
tzdata 2025b-0ubuntu0.24.04.1 deb
|
||||||
ubuntu-keyring 2023.11.28.1 deb
|
ubuntu-keyring 2023.11.28.1 deb
|
||||||
util-linux 2.39.3-9ubuntu6.1 deb
|
unminimize 0.2.1 deb
|
||||||
wheel 0.45.1 python
|
util-linux 2.39.3-9ubuntu6.4 deb
|
||||||
wyoming 1.1.0 python
|
wheel 0.46.3 python
|
||||||
wyoming-piper 1.4.0 python
|
wyoming 1.8.0 python
|
||||||
|
wyoming-piper 2.2.2 python
|
||||||
zlib1g 1:1.3.dfsg-3.1ubuntu2.1 deb
|
zlib1g 1:1.3.dfsg-3.1ubuntu2.1 deb
|
||||||
|
|||||||
@ -2,48 +2,91 @@
|
|||||||
|
|
||||||
# project information
|
# project information
|
||||||
project_name: piper
|
project_name: piper
|
||||||
project_url: "https://github.com/rhasspy/piper/"
|
project_url: "https://github.com/rhasspy/wyoming-piper"
|
||||||
project_logo: "https://raw.githubusercontent.com/linuxserver/docker-templates/master/linuxserver.io/img/piper-logo.png"
|
project_logo: "https://raw.githubusercontent.com/linuxserver/docker-templates/master/linuxserver.io/img/piper-logo.png"
|
||||||
project_blurb: "[{{ project_name|capitalize }}]({{ project_url }}) is a fast, local neural text to speech system that sounds great and is optimized for the Raspberry Pi 4. This container provides a Wyoming protocol server for Piper."
|
project_blurb: "[{{ project_name|capitalize }}]({{ project_url }}) is a fast, local neural text to speech system that sounds great and is optimized for the Raspberry Pi 4. This container provides a Wyoming protocol server for Piper."
|
||||||
project_lsio_github_repo_url: "https://github.com/linuxserver/docker-{{ project_name }}"
|
project_lsio_github_repo_url: "https://github.com/linuxserver/docker-{{ project_name }}"
|
||||||
|
|
||||||
# supported architectures
|
# supported architectures
|
||||||
available_architectures:
|
available_architectures:
|
||||||
- { arch: "{{ arch_x86_64 }}", tag: "amd64-latest"}
|
- {arch: "{{ arch_x86_64 }}", tag: "amd64-latest"}
|
||||||
- { arch: "{{ arch_arm64 }}", tag: "arm64v8-latest"}
|
development_versions: true
|
||||||
|
development_versions_items:
|
||||||
|
- {tag: "latest", desc: "Stable releases"}
|
||||||
|
- {tag: "gpu", desc: "Releases with Nvidia GPU support (amd64 only)"}
|
||||||
# container parameters
|
# container parameters
|
||||||
common_param_env_vars_enabled: true
|
common_param_env_vars_enabled: true
|
||||||
param_container_name: "{{ project_name }}"
|
param_container_name: "{{ project_name }}"
|
||||||
param_usage_include_env: true
|
param_usage_include_env: true
|
||||||
param_env_vars:
|
param_env_vars:
|
||||||
- { env_var: "PIPER_VOICE", env_value: "en_US-lessac-medium", desc: "The [Piper voice](https://huggingface.co/rhasspy/piper-voices/tree/main) to use, in the format `<language>-<name>-<quality>`" }
|
- {env_var: "PIPER_VOICE", env_value: "en_US-lessac-medium", desc: "The [Piper voice](https://huggingface.co/rhasspy/piper-voices/tree/main) to use, in the format `<language>-<name>-<quality>`"}
|
||||||
param_usage_include_vols: true
|
param_usage_include_vols: true
|
||||||
param_volumes:
|
param_volumes:
|
||||||
- { vol_path: "/config", vol_host_path: "/path/to/{{ project_name }}/data", desc: "Local path for piper config files." }
|
- {vol_path: "/config", vol_host_path: "/path/to/{{ project_name }}/data", desc: "Local path for piper config files."}
|
||||||
param_usage_include_ports: true
|
param_usage_include_ports: true
|
||||||
param_ports:
|
param_ports:
|
||||||
- { external_port: "10200", internal_port: "10200", port_desc: "Wyoming connection port." }
|
- {external_port: "10200", internal_port: "10200", port_desc: "Wyoming connection port."}
|
||||||
|
|
||||||
# optional container parameters
|
# optional container parameters
|
||||||
opt_param_usage_include_env: true
|
opt_param_usage_include_env: true
|
||||||
opt_param_env_vars:
|
opt_param_env_vars:
|
||||||
- { env_var: "PIPER_LENGTH", env_value: "1.0", desc: "Voice speaking rate, 1.0 is default with < 1.0 being faster and > 1.0 being slower." }
|
- {env_var: "LOCAL_ONLY", env_value: "", desc: "If set to `true`, or any other value, the container will not attempt to download models from HuggingFace and will only use locally-provided models."}
|
||||||
- { env_var: "PIPER_NOISE", env_value: "0.667", desc: "Controls the variability of the voice by adding noise. Values above 1 will start to degrade audio." }
|
- {env_var: "PIPER_LENGTH", env_value: "1.0", desc: "Voice speaking rate, 1.0 is default with < 1.0 being faster and > 1.0 being slower."}
|
||||||
- { env_var: "PIPER_NOISEW", env_value: "0.333", desc: "Controls the variability of speaking cadence. Values above 1 produce extreme stutters and pauses." }
|
- {env_var: "PIPER_NOISE", env_value: "0.667", desc: "Controls the variability of the voice by adding noise. Values above 1 will start to degrade audio."}
|
||||||
- { env_var: "PIPER_SPEAKER", env_value: "0", desc: "Speaker number to use if the voice supports multiple speakers." }
|
- {env_var: "PIPER_NOISEW", env_value: "0.333", desc: "Controls the variability of speaking cadence. Values above 1 produce extreme stutters and pauses."}
|
||||||
- { env_var: "PIPER_PROCS", env_value: "1", desc: "Number of Piper processes to run simultaneously." }
|
- {env_var: "PIPER_SPEAKER", env_value: "0", desc: "Speaker number to use if the voice supports multiple speakers."}
|
||||||
|
- {env_var: "NO_STREAMING", env_value: "", desc: "Setting to `true`, or any other value, will disable support for streaming audio on sentence boundaries."}
|
||||||
readonly_supported: true
|
readonly_supported: true
|
||||||
|
|
||||||
# application setup block
|
# application setup block
|
||||||
app_setup_block_enabled: true
|
app_setup_block_enabled: true
|
||||||
app_setup_block: |
|
app_setup_block: |
|
||||||
For use with Home Assistant [Assist](https://www.home-assistant.io/voice_control/voice_remote_local_assistant/), add the Wyoming integration and supply the hostname/IP and port that piper is running add-on."
|
For use with Home Assistant [Assist](https://www.home-assistant.io/voice_control/voice_remote_local_assistant/), add the Wyoming integration and supply the hostname/IP and port that piper is running add-on."
|
||||||
|
|
||||||
For more information see the [piper docs](https://github.com/rhasspy/piper/),
|
When using the `gpu` tag with Nvidia GPUs, make sure you set the container to use the `nvidia` runtime and that you have the [Nvidia Container Toolkit](https://github.com/NVIDIA/nvidia-container-toolkit) installed on the host and that you run the container with the correct GPU(s) exposed. See the [Nvidia Container Toolkit docs](https://docs.nvidia.com/datacenter/cloud-native/container-toolkit/latest/sample-workload.html) for more details.
|
||||||
|
|
||||||
|
For more information see the [wyoming piper docs](https://github.com/rhasspy/wyoming-piper),
|
||||||
|
# init diagram
|
||||||
|
init_diagram: |
|
||||||
|
"piper:gpu": {
|
||||||
|
docker-mods
|
||||||
|
base {
|
||||||
|
fix-attr +\nlegacy cont-init
|
||||||
|
}
|
||||||
|
docker-mods -> base
|
||||||
|
legacy-services
|
||||||
|
custom services
|
||||||
|
init-services -> legacy-services
|
||||||
|
init-services -> custom services
|
||||||
|
custom services -> legacy-services
|
||||||
|
legacy-services -> ci-service-check
|
||||||
|
init-migrations -> init-adduser
|
||||||
|
init-os-end -> init-config
|
||||||
|
init-config -> init-config-end
|
||||||
|
init-crontab-config -> init-config-end
|
||||||
|
init-piper-config -> init-config-end
|
||||||
|
init-config -> init-crontab-config
|
||||||
|
init-mods-end -> init-custom-files
|
||||||
|
init-adduser -> init-device-perms
|
||||||
|
base -> init-envfile
|
||||||
|
base -> init-migrations
|
||||||
|
init-config-end -> init-mods
|
||||||
|
init-mods-package-install -> init-mods-end
|
||||||
|
init-mods -> init-mods-package-install
|
||||||
|
init-adduser -> init-os-end
|
||||||
|
init-device-perms -> init-os-end
|
||||||
|
init-envfile -> init-os-end
|
||||||
|
init-config -> init-piper-config
|
||||||
|
init-custom-files -> init-services
|
||||||
|
init-services -> svc-cron
|
||||||
|
svc-cron -> legacy-services
|
||||||
|
init-services -> svc-piper
|
||||||
|
svc-piper -> legacy-services
|
||||||
|
}
|
||||||
|
Base Images: {
|
||||||
|
"baseimage-ubuntu:noble"
|
||||||
|
}
|
||||||
|
"piper:gpu" <- Base Images
|
||||||
# changelog
|
# changelog
|
||||||
changelogs:
|
changelogs:
|
||||||
- { date: "18.07.24:", desc: "Rebase to Ubuntu Noble." }
|
- {date: "15.11.25:", desc: "Add streaming support & support for local only mode."}
|
||||||
- { date: "25.11.23:", desc: "Initial Release." }
|
- {date: "26.11.24:", desc: "Add GPU branch."}
|
||||||
|
- {date: "18.07.24:", desc: "Rebase to Ubuntu Noble."}
|
||||||
|
- {date: "25.11.23:", desc: "Initial Release."}
|
||||||
|
|||||||
@ -1,16 +1,33 @@
|
|||||||
#!/command/with-contenv bash
|
#!/command/with-contenv bash
|
||||||
# shellcheck shell=bash
|
# shellcheck shell=bash
|
||||||
|
|
||||||
|
NVIDIA_PACKAGE_DIR="/lsiopy/lib/python3.12/site-packages/nvidia"
|
||||||
|
|
||||||
|
for dir in "${NVIDIA_PACKAGE_DIR}"/*; do
|
||||||
|
if [ -d "$dir/lib" ]; then
|
||||||
|
export LD_LIBRARY_PATH="$dir/lib:$LD_LIBRARY_PATH"
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
|
unset UPDATE_MODELS
|
||||||
|
|
||||||
|
if [[ -z ${LOCAL_ONLY} ]]; then
|
||||||
|
UPDATE_MODELS=true
|
||||||
|
fi
|
||||||
|
|
||||||
|
LD_LIBRARY_PATH="/lsiopy/lib/python3.12/site-packages/onnxruntime-gpu/capi:$LD_LIBRARY_PATH"
|
||||||
|
|
||||||
exec \
|
exec \
|
||||||
s6-notifyoncheck -d -n 300 -w 1000 -c "nc -z localhost 10200" \
|
s6-notifyoncheck -d -n 300 -w 1000 -c "nc -z localhost 10200" \
|
||||||
s6-setuidgid abc python3 -m wyoming_piper \
|
s6-setuidgid abc python3 -m wyoming_piper \
|
||||||
--piper '/usr/share/piper/piper' \
|
|
||||||
--uri 'tcp://0.0.0.0:10200' \
|
--uri 'tcp://0.0.0.0:10200' \
|
||||||
--length-scale "${PIPER_LENGTH:-1.0}" \
|
--length-scale "${PIPER_LENGTH:-1.0}" \
|
||||||
--noise-scale "${PIPER_NOISE:-0.667}" \
|
--noise-scale "${PIPER_NOISE:-0.667}" \
|
||||||
--noise-w "${PIPER_NOISEW:-0.333}" \
|
--noise-w "${PIPER_NOISEW:-0.333}" \
|
||||||
--speaker "${PIPER_SPEAKER:-0}" \
|
--speaker "${PIPER_SPEAKER:-0}" \
|
||||||
--voice "${PIPER_VOICE}" \
|
--voice "${PIPER_VOICE}" \
|
||||||
--max-piper-procs "${PIPER_PROCS:-1}" \
|
|
||||||
--data-dir /config \
|
--data-dir /config \
|
||||||
--download-dir /config --update-voices
|
--download-dir /config \
|
||||||
|
--use-cuda \
|
||||||
|
${UPDATE_MODELS:+--update-voices} \
|
||||||
|
${NO_STREAMING:+--no-streaming}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user