Compare commits
61 commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
458f79ca4b | ||
|
|
6ea8b43b0d | ||
|
|
113e0bf43b | ||
|
|
6a6256acd4 | ||
|
|
ac17141dc8 | ||
|
|
2c1f03e3a7 | ||
|
|
4775b97056 | ||
|
|
d9e9c8a664 | ||
|
|
ec8542f160 | ||
|
|
e1e80e60c0 | ||
|
|
59c62f1ae7 | ||
|
|
081f3bf4a3 | ||
|
|
a34a58bd62 | ||
|
|
64ecb6745f | ||
|
|
ba27487240 | ||
|
|
5e393c25ff | ||
|
|
5a3ccf4cf0 | ||
|
|
d48d182f0f | ||
|
|
8beeaeca45 | ||
|
|
12873dd927 | ||
|
|
1730537b24 | ||
|
|
7d602a73c4 | ||
|
|
2f5c0f11df | ||
|
|
2411390177 | ||
|
|
7777d8828d | ||
|
|
795d744a0f | ||
|
|
5dfe7d15c6 | ||
|
|
ff812c0651 | ||
|
|
70b76baa2f | ||
|
|
8f35e8139b | ||
|
|
6bd31eb477 | ||
|
|
481825d48e | ||
|
|
2926dbe73c | ||
|
|
c6b5263eb1 | ||
|
|
f272148962 | ||
|
|
bb5a7b16e2 | ||
|
|
1983fb36bb | ||
|
|
85bd229846 | ||
|
|
94ccace81c | ||
|
|
9ec43eb872 | ||
|
|
c822962c7a | ||
|
|
a2b17e520a | ||
|
|
6567cde19c | ||
|
|
719f49cb0a | ||
|
|
5b1eb38ce6 | ||
|
|
34006fe7e7 | ||
|
|
af2c6f228e | ||
|
|
b48c87eb2f | ||
|
|
ef81cb3b33 | ||
|
|
56d8fbb73f | ||
|
|
b9b51a1b93 | ||
|
|
46e3e8d74c | ||
|
|
4066c272d7 | ||
|
|
28e54925ca | ||
|
|
c4951e7021 | ||
|
|
f2844953b3 | ||
|
|
552137dbb1 | ||
|
|
3ae6c4fd66 | ||
|
|
cb6b200afc | ||
|
|
458334e3c1 | ||
|
|
d69c527089 |
15
.forgejo/workflows/build.yaml
Normal file
15
.forgejo/workflows/build.yaml
Normal file
|
|
@ -0,0 +1,15 @@
|
||||||
|
name: build
|
||||||
|
run-name: ${{ gitea.actor }} is building baseimage-alpine
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- 'master'
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
runs-on: podman
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- run: podman login --username registry --password ${{ secrets.MEATBAG_REGISTRY_TOKEN }} registry.meatbag.se
|
||||||
|
- run: podman build -t meatbag/baseimage-alpine:latest .
|
||||||
|
- run: podman push meatbag/baseimage-alpine registry.meatbag.se/meatbag/baseimage-alpine
|
||||||
123
.github/CONTRIBUTING.md
vendored
123
.github/CONTRIBUTING.md
vendored
|
|
@ -1,123 +0,0 @@
|
||||||
# Contributing to baseimage-alpine
|
|
||||||
|
|
||||||
## Gotchas
|
|
||||||
|
|
||||||
* While contributing make sure to make all your changes before creating a Pull Request, as our pipeline builds each commit after the PR is open.
|
|
||||||
* Read, and fill the Pull Request template
|
|
||||||
* If this is a fix for a typo (in code, documentation, or the README) please file an issue and let us sort it out. We do not need a PR
|
|
||||||
* If the PR is addressing an existing issue include, closes #\<issue number>, in the body of the PR commit message
|
|
||||||
* If you want to discuss changes, you can also bring it up in [#dev-talk](https://discordapp.com/channels/354974912613449730/757585807061155840) in our [Discord server](https://discord.gg/YWrKVTn)
|
|
||||||
|
|
||||||
## Common files
|
|
||||||
|
|
||||||
| File | Use case |
|
|
||||||
| :----: | --- |
|
|
||||||
| `Dockerfile` | Dockerfile used to build amd64 images |
|
|
||||||
| `Dockerfile.aarch64` | Dockerfile used to build 64bit ARM architectures |
|
|
||||||
| `Dockerfile.armhf` | Dockerfile used to build 32bit ARM architectures |
|
|
||||||
| `Jenkinsfile` | This file is a product of our builder and should not be edited directly. This is used to build the image |
|
|
||||||
| `jenkins-vars.yml` | This file is used to generate the `Jenkinsfile` mentioned above, it only affects the build-process |
|
|
||||||
| `package_versions.txt` | This file is generated as a part of the build-process and should not be edited directly. It lists all the installed packages and their versions |
|
|
||||||
| `README.md` | This file is a product of our builder and should not be edited directly. This displays the readme for the repository and image registries |
|
|
||||||
| `readme-vars.yml` | This file is used to generate the `README.md` |
|
|
||||||
|
|
||||||
## Readme
|
|
||||||
|
|
||||||
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-baseimage-alpine/edit/master/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.
|
|
||||||
Most of these variables are also carried over to [docs.linuxserver.io](https://docs.linuxserver.io)
|
|
||||||
|
|
||||||
### Fixing typos or clarify the text in the readme
|
|
||||||
|
|
||||||
There are variables for multiple parts of the readme, the most common ones are:
|
|
||||||
|
|
||||||
| Variable | Description |
|
|
||||||
| :----: | --- |
|
|
||||||
| `project_blurb` | This is the short excerpt shown above the project logo. |
|
|
||||||
| `app_setup_block` | This is the text that shows up under "Application Setup" if enabled |
|
|
||||||
|
|
||||||
### Parameters
|
|
||||||
|
|
||||||
The compose and run examples are also generated from these variables.
|
|
||||||
|
|
||||||
We have a [reference file](https://github.com/linuxserver/docker-jenkins-builder/blob/master/vars/_container-vars-blank) in our Jenkins Builder.
|
|
||||||
|
|
||||||
These are prefixed with `param_` for required parameters, or `opt_param` for optional parameters, except for `cap_add`.
|
|
||||||
Remember to enable param, if currently disabled. This differs between parameters, and can be seen in the reference file.
|
|
||||||
|
|
||||||
Devices, environment variables, ports and volumes expects its variables in a certain way.
|
|
||||||
|
|
||||||
### Devices
|
|
||||||
|
|
||||||
```yml
|
|
||||||
param_devices:
|
|
||||||
- { device_path: "/dev/dri", device_host_path: "/dev/dri", desc: "For hardware transcoding" }
|
|
||||||
opt_param_devices:
|
|
||||||
- { device_path: "/dev/dri", device_host_path: "/dev/dri", desc: "For hardware transcoding" }
|
|
||||||
```
|
|
||||||
|
|
||||||
### Environment variables
|
|
||||||
|
|
||||||
```yml
|
|
||||||
param_env_vars:
|
|
||||||
- { env_var: "TZ", env_value: "Europe/London", desc: "Specify a timezone to use EG Europe/London." }
|
|
||||||
opt_param_env_vars:
|
|
||||||
- { env_var: "VERSION", env_value: "latest", desc: "Supported values are LATEST, PLEXPASS or a specific version number." }
|
|
||||||
```
|
|
||||||
|
|
||||||
### Ports
|
|
||||||
|
|
||||||
```yml
|
|
||||||
param_ports:
|
|
||||||
- { external_port: "80", internal_port: "80", port_desc: "Application WebUI" }
|
|
||||||
opt_param_ports:
|
|
||||||
- { external_port: "80", internal_port: "80", port_desc: "Application WebUI" }
|
|
||||||
```
|
|
||||||
|
|
||||||
### Volumes
|
|
||||||
|
|
||||||
```yml
|
|
||||||
param_volumes:
|
|
||||||
- { vol_path: "/config", vol_host_path: "</path/to/appdata/config>", desc: "Configuration files." }
|
|
||||||
opt_param_volumes:
|
|
||||||
- { vol_path: "/config", vol_host_path: "</path/to/appdata/config>", desc: "Configuration files." }
|
|
||||||
```
|
|
||||||
|
|
||||||
### Testing template changes
|
|
||||||
|
|
||||||
After you make any changes to the templates, you can use our [Jenkins Builder](https://github.com/linuxserver/docker-jenkins-builder) to have the files updated from the modified templates. Please use the command found under `Running Locally` [on this page](https://github.com/linuxserver/docker-jenkins-builder/blob/master/README.md) to generate them prior to submitting a PR.
|
|
||||||
|
|
||||||
## Dockerfiles
|
|
||||||
|
|
||||||
We use multiple Dockerfiles in our repos, this is because sometimes some CPU architectures needs different packages to work.
|
|
||||||
If you are proposing additional packages to be added, ensure that you added the packages to all the Dockerfiles in alphabetical order.
|
|
||||||
|
|
||||||
### Testing your changes
|
|
||||||
|
|
||||||
```bash
|
|
||||||
git clone https://github.com/linuxserver/docker-baseimage-alpine.git
|
|
||||||
cd docker-baseimage-alpine
|
|
||||||
docker build \
|
|
||||||
--no-cache \
|
|
||||||
--pull \
|
|
||||||
-t linuxserver/baseimage-alpine:latest .
|
|
||||||
```
|
|
||||||
|
|
||||||
The ARM variants can be built on x86_64 hardware using `multiarch/qemu-user-static`
|
|
||||||
|
|
||||||
```bash
|
|
||||||
docker run --rm --privileged multiarch/qemu-user-static:register --reset
|
|
||||||
```
|
|
||||||
|
|
||||||
Once registered you can define the dockerfile to use with `-f Dockerfile.aarch64`.
|
|
||||||
|
|
||||||
## Update the changelog
|
|
||||||
|
|
||||||
If you are modifying the Dockerfiles or any of the startup scripts in [root](https://github.com/linuxserver/docker-baseimage-alpine/tree/master/root), add an entry to the changelog
|
|
||||||
|
|
||||||
```yml
|
|
||||||
changelogs:
|
|
||||||
- { date: "DD.MM.YY:", desc: "Added some love to templates" }
|
|
||||||
```
|
|
||||||
2
.github/FUNDING.yml
vendored
2
.github/FUNDING.yml
vendored
|
|
@ -1,2 +0,0 @@
|
||||||
github: linuxserver
|
|
||||||
open_collective: linuxserver
|
|
||||||
13
.github/ISSUE_TEMPLATE/config.yml
vendored
13
.github/ISSUE_TEMPLATE/config.yml
vendored
|
|
@ -1,13 +0,0 @@
|
||||||
blank_issues_enabled: false
|
|
||||||
contact_links:
|
|
||||||
- name: Discord chat support
|
|
||||||
url: https://discord.gg/YWrKVTn
|
|
||||||
about: Realtime support / chat with the community and the team.
|
|
||||||
|
|
||||||
- name: Discourse discussion forum
|
|
||||||
url: https://discourse.linuxserver.io
|
|
||||||
about: Post on our community forum.
|
|
||||||
|
|
||||||
- name: Documentation
|
|
||||||
url: https://docs.linuxserver.io
|
|
||||||
about: Documentation - information about all of our containers.
|
|
||||||
68
.github/ISSUE_TEMPLATE/issue.bug.yml
vendored
68
.github/ISSUE_TEMPLATE/issue.bug.yml
vendored
|
|
@ -1,68 +0,0 @@
|
||||||
# Based on the issue template
|
|
||||||
name: Bug report
|
|
||||||
description: Create a report to help us improve
|
|
||||||
title: "[BUG] <title>"
|
|
||||||
labels: [Bug]
|
|
||||||
body:
|
|
||||||
- type: checkboxes
|
|
||||||
attributes:
|
|
||||||
label: Is there an existing issue for this?
|
|
||||||
description: Please search to see if an issue already exists for the bug you encountered.
|
|
||||||
options:
|
|
||||||
- label: I have searched the existing issues
|
|
||||||
required: true
|
|
||||||
- type: textarea
|
|
||||||
attributes:
|
|
||||||
label: Current Behavior
|
|
||||||
description: Tell us what happens instead of the expected behavior.
|
|
||||||
validations:
|
|
||||||
required: true
|
|
||||||
- type: textarea
|
|
||||||
attributes:
|
|
||||||
label: Expected Behavior
|
|
||||||
description: Tell us what should happen.
|
|
||||||
validations:
|
|
||||||
required: false
|
|
||||||
- type: textarea
|
|
||||||
attributes:
|
|
||||||
label: Steps To Reproduce
|
|
||||||
description: Steps to reproduce the behavior.
|
|
||||||
placeholder: |
|
|
||||||
1. In this environment...
|
|
||||||
2. With this config...
|
|
||||||
3. Run '...'
|
|
||||||
4. See error...
|
|
||||||
validations:
|
|
||||||
required: true
|
|
||||||
- type: textarea
|
|
||||||
attributes:
|
|
||||||
label: Environment
|
|
||||||
description: |
|
|
||||||
examples:
|
|
||||||
- **OS**: Ubuntu 20.04
|
|
||||||
- **How docker service was installed**: distro's packagemanager
|
|
||||||
value: |
|
|
||||||
- OS:
|
|
||||||
- How docker service was installed:
|
|
||||||
render: markdown
|
|
||||||
validations:
|
|
||||||
required: false
|
|
||||||
- type: textarea
|
|
||||||
attributes:
|
|
||||||
label: Docker creation
|
|
||||||
description: |
|
|
||||||
Command used to create docker container
|
|
||||||
Provide your docker create/run command or compose yaml snippet, or a screenshot of settings if using a gui to create the container
|
|
||||||
render: bash
|
|
||||||
validations:
|
|
||||||
required: true
|
|
||||||
- type: textarea
|
|
||||||
attributes:
|
|
||||||
description: |
|
|
||||||
Provide a full docker log, output of "docker logs baseimage-alpine"
|
|
||||||
label: Container logs
|
|
||||||
placeholder: |
|
|
||||||
Output of `docker logs baseimage-alpine`
|
|
||||||
render: bash
|
|
||||||
validations:
|
|
||||||
required: true
|
|
||||||
31
.github/ISSUE_TEMPLATE/issue.feature.yml
vendored
31
.github/ISSUE_TEMPLATE/issue.feature.yml
vendored
|
|
@ -1,31 +0,0 @@
|
||||||
# Based on the issue template
|
|
||||||
name: Feature request
|
|
||||||
description: Suggest an idea for this project
|
|
||||||
title: "[FEAT] <title>"
|
|
||||||
labels: [enhancement]
|
|
||||||
body:
|
|
||||||
- type: checkboxes
|
|
||||||
attributes:
|
|
||||||
label: Is this a new feature request?
|
|
||||||
description: Please search to see if a feature request already exists.
|
|
||||||
options:
|
|
||||||
- label: I have searched the existing issues
|
|
||||||
required: true
|
|
||||||
- type: textarea
|
|
||||||
attributes:
|
|
||||||
label: Wanted change
|
|
||||||
description: Tell us what you want to happen.
|
|
||||||
validations:
|
|
||||||
required: true
|
|
||||||
- type: textarea
|
|
||||||
attributes:
|
|
||||||
label: Reason for change
|
|
||||||
description: Justify your request, why do you want it, what is the benefit.
|
|
||||||
validations:
|
|
||||||
required: true
|
|
||||||
- type: textarea
|
|
||||||
attributes:
|
|
||||||
label: Proposed code change
|
|
||||||
description: Do you have a potential code change in mind?
|
|
||||||
validations:
|
|
||||||
required: false
|
|
||||||
43
.github/PULL_REQUEST_TEMPLATE.md
vendored
43
.github/PULL_REQUEST_TEMPLATE.md
vendored
|
|
@ -1,43 +0,0 @@
|
||||||
<!--- Provide a general summary of your changes in the Title above -->
|
|
||||||
|
|
||||||
[linuxserverurl]: https://linuxserver.io
|
|
||||||
[][linuxserverurl]
|
|
||||||
|
|
||||||
|
|
||||||
<!--- Before submitting a pull request please check the following -->
|
|
||||||
|
|
||||||
<!--- If this is a fix for a typo (in code, documentation, or the README) please file an issue and let us sort it out. We do not need a PR -->
|
|
||||||
<!--- Ask yourself if this modification is something the whole userbase will benefit from, if this is a specific change for corner case functionality or plugins please look at making a Docker Mod or local script https://blog.linuxserver.io/2019/09/14/customizing-our-containers/ -->
|
|
||||||
<!--- That if the PR is addressing an existing issue include, closes #<issue number> , in the body of the PR commit message -->
|
|
||||||
<!--- You have included links to any files / patches etc your PR may be using in the body of the PR commit message -->
|
|
||||||
<!--- We maintain a changelog of major revisions to the container at the end of readme-vars.yml in the root of this repository, please add your changes there if appropriate -->
|
|
||||||
|
|
||||||
|
|
||||||
<!--- Coding guidelines: -->
|
|
||||||
<!--- 1. Installed packages in the Dockerfiles should be in alphabetical order -->
|
|
||||||
<!--- 2. Changes to Dockerfile should be replicated in Dockerfile.armhf and Dockerfile.aarch64 if applicable -->
|
|
||||||
<!--- 3. Indentation style (tabs vs 4 spaces vs 1 space) should match the rest of the document -->
|
|
||||||
<!--- 4. Readme is auto generated from readme-vars.yml, make your changes there -->
|
|
||||||
|
|
||||||
------------------------------
|
|
||||||
|
|
||||||
- [ ] I have read the [contributing](https://github.com/linuxserver/docker-baseimage-alpine/blob/master/.github/CONTRIBUTING.md) guideline and understand that I have made the correct modifications
|
|
||||||
|
|
||||||
------------------------------
|
|
||||||
|
|
||||||
<!--- We welcome all PR’s though this doesn’t guarantee it will be accepted. -->
|
|
||||||
|
|
||||||
## Description:
|
|
||||||
<!--- Describe your changes in detail -->
|
|
||||||
|
|
||||||
## Benefits of this PR and context:
|
|
||||||
<!--- Please explain why we should accept this PR. If this fixes an outstanding bug, please reference the issue # -->
|
|
||||||
|
|
||||||
## How Has This Been Tested?
|
|
||||||
<!--- Please describe in detail how you tested your changes. -->
|
|
||||||
<!--- Include details of your testing environment, and the tests you ran to -->
|
|
||||||
<!--- see how your change affects other areas of the code, etc. -->
|
|
||||||
|
|
||||||
|
|
||||||
## Source / References:
|
|
||||||
<!--- Please include any forum posts/github links relevant to the PR -->
|
|
||||||
16
.github/workflows/call_issue_pr_tracker.yml
vendored
16
.github/workflows/call_issue_pr_tracker.yml
vendored
|
|
@ -1,16 +0,0 @@
|
||||||
name: Issue & PR Tracker
|
|
||||||
|
|
||||||
on:
|
|
||||||
issues:
|
|
||||||
types: [opened,reopened,labeled,unlabeled,closed]
|
|
||||||
pull_request_target:
|
|
||||||
types: [opened,reopened,review_requested,review_request_removed,labeled,unlabeled,closed]
|
|
||||||
pull_request_review:
|
|
||||||
types: [submitted,edited,dismissed]
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
manage-project:
|
|
||||||
permissions:
|
|
||||||
issues: write
|
|
||||||
uses: linuxserver/github-workflows/.github/workflows/issue-pr-tracker.yml@v1
|
|
||||||
secrets: inherit
|
|
||||||
13
.github/workflows/call_issues_cron.yml
vendored
13
.github/workflows/call_issues_cron.yml
vendored
|
|
@ -1,13 +0,0 @@
|
||||||
name: Mark stale issues and pull requests
|
|
||||||
on:
|
|
||||||
schedule:
|
|
||||||
- cron: '9 11 * * *'
|
|
||||||
workflow_dispatch:
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
stale:
|
|
||||||
permissions:
|
|
||||||
issues: write
|
|
||||||
pull-requests: write
|
|
||||||
uses: linuxserver/github-workflows/.github/workflows/issues-cron.yml@v1
|
|
||||||
secrets: inherit
|
|
||||||
17
.github/workflows/external_trigger.yml
vendored
17
.github/workflows/external_trigger.yml
vendored
|
|
@ -1,17 +0,0 @@
|
||||||
name: External Trigger Main
|
|
||||||
|
|
||||||
on:
|
|
||||||
workflow_dispatch:
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
external-trigger-master:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v4.1.1
|
|
||||||
|
|
||||||
- name: External Trigger
|
|
||||||
if: github.ref == 'refs/heads/master'
|
|
||||||
run: |
|
|
||||||
echo "**** No external release, exiting ****"
|
|
||||||
echo "No external release, exiting" >> $GITHUB_STEP_SUMMARY
|
|
||||||
exit 0
|
|
||||||
45
.github/workflows/external_trigger_scheduler.yml
vendored
45
.github/workflows/external_trigger_scheduler.yml
vendored
|
|
@ -1,45 +0,0 @@
|
||||||
name: External Trigger Scheduler
|
|
||||||
|
|
||||||
on:
|
|
||||||
schedule:
|
|
||||||
- cron: '20 * * * *'
|
|
||||||
workflow_dispatch:
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
external-trigger-scheduler:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v4.1.1
|
|
||||||
with:
|
|
||||||
fetch-depth: '0'
|
|
||||||
|
|
||||||
- name: External Trigger Scheduler
|
|
||||||
run: |
|
|
||||||
echo "**** Branches found: ****"
|
|
||||||
git for-each-ref --format='%(refname:short)' refs/remotes
|
|
||||||
for br in $(git for-each-ref --format='%(refname:short)' refs/remotes)
|
|
||||||
do
|
|
||||||
br=$(echo "$br" | sed 's|origin/||g')
|
|
||||||
echo "**** Evaluating branch ${br} ****"
|
|
||||||
ls_jenkins_vars=$(curl -sX GET https://raw.githubusercontent.com/linuxserver/docker-baseimage-alpine/${br}/jenkins-vars.yml)
|
|
||||||
ls_branch=$(echo "${ls_jenkins_vars}" | yq -r '.ls_branch')
|
|
||||||
ls_trigger=$(echo "${ls_jenkins_vars}" | yq -r '.external_type')
|
|
||||||
if [[ "${br}" == "${ls_branch}" ]] && [[ "${ls_trigger}" != "os" ]]; then
|
|
||||||
echo "**** Branch ${br} appears to be live and trigger is not os; checking workflow. ****"
|
|
||||||
if curl -sfX GET https://raw.githubusercontent.com/linuxserver/docker-baseimage-alpine/${br}/.github/workflows/external_trigger.yml > /dev/null 2>&1; then
|
|
||||||
echo "**** Workflow exists. Triggering external trigger workflow for branch ${br} ****."
|
|
||||||
echo "Triggering external trigger workflow for branch ${br}" >> $GITHUB_STEP_SUMMARY
|
|
||||||
curl -iX POST \
|
|
||||||
-H "Authorization: token ${{ secrets.CR_PAT }}" \
|
|
||||||
-H "Accept: application/vnd.github.v3+json" \
|
|
||||||
-d "{\"ref\":\"refs/heads/${br}\"}" \
|
|
||||||
https://api.github.com/repos/linuxserver/docker-baseimage-alpine/actions/workflows/external_trigger.yml/dispatches
|
|
||||||
else
|
|
||||||
echo "**** Workflow doesn't exist; skipping trigger. ****"
|
|
||||||
echo "Skipping branch ${br} due to no external trigger workflow present." >> $GITHUB_STEP_SUMMARY
|
|
||||||
fi
|
|
||||||
else
|
|
||||||
echo "**** ${br} is either a dev branch, or has no external version; skipping trigger. ****"
|
|
||||||
echo "Skipping branch ${br} due to being detected as dev branch or having no external version." >> $GITHUB_STEP_SUMMARY
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
13
.github/workflows/greetings.yml
vendored
13
.github/workflows/greetings.yml
vendored
|
|
@ -1,13 +0,0 @@
|
||||||
name: Greetings
|
|
||||||
|
|
||||||
on: [pull_request_target, issues]
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
greeting:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- uses: actions/first-interaction@v1
|
|
||||||
with:
|
|
||||||
issue-message: 'Thanks for opening your first issue here! Be sure to follow the 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-baseimage-alpine/blob/master/.github/PULL_REQUEST_TEMPLATE.md)!'
|
|
||||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
42
.github/workflows/package_trigger.yml
vendored
42
.github/workflows/package_trigger.yml
vendored
|
|
@ -1,42 +0,0 @@
|
||||||
name: Package Trigger Main
|
|
||||||
|
|
||||||
on:
|
|
||||||
workflow_dispatch:
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
package-trigger-master:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v4.1.1
|
|
||||||
|
|
||||||
- name: Package Trigger
|
|
||||||
if: github.ref == 'refs/heads/master'
|
|
||||||
run: |
|
|
||||||
if [ -n "${{ secrets.PAUSE_PACKAGE_TRIGGER_BASEIMAGE_ALPINE_MASTER }}" ]; then
|
|
||||||
echo "**** Github secret PAUSE_PACKAGE_TRIGGER_BASEIMAGE_ALPINE_MASTER is set; skipping trigger. ****"
|
|
||||||
echo "Github secret \`PAUSE_PACKAGE_TRIGGER_BASEIMAGE_ALPINE_MASTER\` is set; skipping trigger." >> $GITHUB_STEP_SUMMARY
|
|
||||||
exit 0
|
|
||||||
fi
|
|
||||||
if [ $(curl -s https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-baseimage-alpine/job/master/lastBuild/api/json | jq -r '.building') == "true" ]; then
|
|
||||||
echo "**** There already seems to be an active build on Jenkins; skipping package trigger ****"
|
|
||||||
echo "There already seems to be an active build on Jenkins; skipping package trigger" >> $GITHUB_STEP_SUMMARY
|
|
||||||
exit 0
|
|
||||||
fi
|
|
||||||
echo "**** Package trigger running off of master branch. To disable, set a Github secret named \"PAUSE_PACKAGE_TRIGGER_BASEIMAGE_ALPINE_MASTER\". ****"
|
|
||||||
echo "Package trigger running off of master branch. To disable, set a Github secret named \`PAUSE_PACKAGE_TRIGGER_BASEIMAGE_ALPINE_MASTER\`" >> $GITHUB_STEP_SUMMARY
|
|
||||||
response=$(curl -iX POST \
|
|
||||||
https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-baseimage-alpine/job/master/buildWithParameters?PACKAGE_CHECK=true \
|
|
||||||
--user ${{ secrets.JENKINS_USER }}:${{ secrets.JENKINS_TOKEN }} | grep -i location | sed "s|^[L|l]ocation: \(.*\)|\1|")
|
|
||||||
echo "**** Jenkins job queue url: ${response%$'\r'} ****"
|
|
||||||
echo "**** Sleeping 10 seconds until job starts ****"
|
|
||||||
sleep 10
|
|
||||||
buildurl=$(curl -s "${response%$'\r'}api/json" | jq -r '.executable.url')
|
|
||||||
buildurl="${buildurl%$'\r'}"
|
|
||||||
echo "**** Jenkins job build url: ${buildurl} ****"
|
|
||||||
echo "Jenkins job build url: ${buildurl}" >> $GITHUB_STEP_SUMMARY
|
|
||||||
echo "**** Attempting to change the Jenkins job description ****"
|
|
||||||
curl -iX POST \
|
|
||||||
"${buildurl}submitDescription" \
|
|
||||||
--user ${{ secrets.JENKINS_USER }}:${{ secrets.JENKINS_TOKEN }} \
|
|
||||||
--data-urlencode "description=GHA package trigger https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" \
|
|
||||||
--data-urlencode "Submit=Submit"
|
|
||||||
50
.github/workflows/package_trigger_scheduler.yml
vendored
50
.github/workflows/package_trigger_scheduler.yml
vendored
|
|
@ -1,50 +0,0 @@
|
||||||
name: Package Trigger Scheduler
|
|
||||||
|
|
||||||
on:
|
|
||||||
schedule:
|
|
||||||
- cron: '15 13 * * 6'
|
|
||||||
workflow_dispatch:
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
package-trigger-scheduler:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v4.1.1
|
|
||||||
with:
|
|
||||||
fetch-depth: '0'
|
|
||||||
|
|
||||||
- name: Package Trigger Scheduler
|
|
||||||
run: |
|
|
||||||
echo "**** Branches found: ****"
|
|
||||||
git for-each-ref --format='%(refname:short)' refs/remotes
|
|
||||||
for br in $(git for-each-ref --format='%(refname:short)' refs/remotes)
|
|
||||||
do
|
|
||||||
br=$(echo "$br" | sed 's|origin/||g')
|
|
||||||
echo "**** Evaluating branch ${br} ****"
|
|
||||||
ls_branch=$(curl -sX GET https://raw.githubusercontent.com/linuxserver/docker-baseimage-alpine/${br}/jenkins-vars.yml | yq -r '.ls_branch')
|
|
||||||
if [ "${br}" == "${ls_branch}" ]; then
|
|
||||||
echo "**** Branch ${br} appears to be live; checking workflow. ****"
|
|
||||||
if curl -sfX GET https://raw.githubusercontent.com/linuxserver/docker-baseimage-alpine/${br}/.github/workflows/package_trigger.yml > /dev/null 2>&1; then
|
|
||||||
echo "**** Workflow exists. Triggering package trigger workflow for branch ${br}. ****"
|
|
||||||
echo "Triggering package trigger workflow for branch ${br}" >> $GITHUB_STEP_SUMMARY
|
|
||||||
triggered_branches="${triggered_branches}${br} "
|
|
||||||
curl -iX POST \
|
|
||||||
-H "Authorization: token ${{ secrets.CR_PAT }}" \
|
|
||||||
-H "Accept: application/vnd.github.v3+json" \
|
|
||||||
-d "{\"ref\":\"refs/heads/${br}\"}" \
|
|
||||||
https://api.github.com/repos/linuxserver/docker-baseimage-alpine/actions/workflows/package_trigger.yml/dispatches
|
|
||||||
sleep 30
|
|
||||||
else
|
|
||||||
echo "**** Workflow doesn't exist; skipping trigger. ****"
|
|
||||||
echo "Skipping branch ${br} due to no package trigger workflow present." >> $GITHUB_STEP_SUMMARY
|
|
||||||
fi
|
|
||||||
else
|
|
||||||
echo "**** ${br} appears to be a dev branch; skipping trigger. ****"
|
|
||||||
echo "Skipping branch ${br} due to being detected as dev branch." >> $GITHUB_STEP_SUMMARY
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
echo "**** Package check build(s) triggered for branch(es): ${triggered_branches} ****"
|
|
||||||
echo "**** Notifying Discord ****"
|
|
||||||
curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://cdn.discordapp.com/avatars/354986384542662657/df91181b3f1cf0ef1592fbe18e0962d7.png","embeds": [{"color": 9802903,
|
|
||||||
"description": "**Package Check Build(s) Triggered for baseimage-alpine** \n**Branch(es):** '"${triggered_branches}"' \n**Build URL:** '"https://ci.linuxserver.io/blue/organizations/jenkins/Docker-Pipeline-Builders%2Fdocker-baseimage-alpine/activity/"' \n"}],
|
|
||||||
"username": "Github Actions"}' ${{ secrets.DISCORD_WEBHOOK }}
|
|
||||||
10
.github/workflows/permissions.yml
vendored
10
.github/workflows/permissions.yml
vendored
|
|
@ -1,10 +0,0 @@
|
||||||
name: Permission check
|
|
||||||
on:
|
|
||||||
pull_request_target:
|
|
||||||
paths:
|
|
||||||
- '**/run'
|
|
||||||
- '**/finish'
|
|
||||||
- '**/check'
|
|
||||||
jobs:
|
|
||||||
permission_check:
|
|
||||||
uses: linuxserver/github-workflows/.github/workflows/init-svc-executable-permissions.yml@v1
|
|
||||||
16
Dockerfile
16
Dockerfile
|
|
@ -1,10 +1,10 @@
|
||||||
# syntax=docker/dockerfile:1
|
# syntax=docker/dockerfile:1
|
||||||
|
|
||||||
FROM alpine:3.18 as rootfs-stage
|
FROM alpine:3.20 AS rootfs-stage
|
||||||
|
|
||||||
# environment
|
# environment
|
||||||
ENV ROOTFS=/root-out
|
ENV ROOTFS=/root-out
|
||||||
ENV REL=v3.19
|
ENV REL=v3.21
|
||||||
ENV ARCH=x86_64
|
ENV ARCH=x86_64
|
||||||
ENV MIRROR=http://dl-cdn.alpinelinux.org/alpine
|
ENV MIRROR=http://dl-cdn.alpinelinux.org/alpine
|
||||||
ENV PACKAGES=alpine-baselayout,\
|
ENV PACKAGES=alpine-baselayout,\
|
||||||
|
|
@ -30,7 +30,7 @@ RUN \
|
||||||
sed -i -e 's/^root::/root:!:/' /root-out/etc/shadow
|
sed -i -e 's/^root::/root:!:/' /root-out/etc/shadow
|
||||||
|
|
||||||
# set version for s6 overlay
|
# set version for s6 overlay
|
||||||
ARG S6_OVERLAY_VERSION="3.1.6.2"
|
ARG S6_OVERLAY_VERSION="3.2.0.2"
|
||||||
ARG S6_OVERLAY_ARCH="x86_64"
|
ARG S6_OVERLAY_ARCH="x86_64"
|
||||||
|
|
||||||
# add s6 overlay
|
# add s6 overlay
|
||||||
|
|
@ -41,7 +41,7 @@ RUN tar -C /root-out -Jxpf /tmp/s6-overlay-${S6_OVERLAY_ARCH}.tar.xz
|
||||||
|
|
||||||
# add s6 optional symlinks
|
# add s6 optional symlinks
|
||||||
ADD https://github.com/just-containers/s6-overlay/releases/download/v${S6_OVERLAY_VERSION}/s6-overlay-symlinks-noarch.tar.xz /tmp
|
ADD https://github.com/just-containers/s6-overlay/releases/download/v${S6_OVERLAY_VERSION}/s6-overlay-symlinks-noarch.tar.xz /tmp
|
||||||
RUN tar -C /root-out -Jxpf /tmp/s6-overlay-symlinks-noarch.tar.xz
|
RUN tar -C /root-out -Jxpf /tmp/s6-overlay-symlinks-noarch.tar.xz && unlink /root-out/usr/bin/with-contenv
|
||||||
ADD https://github.com/just-containers/s6-overlay/releases/download/v${S6_OVERLAY_VERSION}/s6-overlay-symlinks-arch.tar.xz /tmp
|
ADD https://github.com/just-containers/s6-overlay/releases/download/v${S6_OVERLAY_VERSION}/s6-overlay-symlinks-arch.tar.xz /tmp
|
||||||
RUN tar -C /root-out -Jxpf /tmp/s6-overlay-symlinks-arch.tar.xz
|
RUN tar -C /root-out -Jxpf /tmp/s6-overlay-symlinks-arch.tar.xz
|
||||||
|
|
||||||
|
|
@ -52,11 +52,15 @@ ARG BUILD_DATE
|
||||||
ARG VERSION
|
ARG VERSION
|
||||||
ARG MODS_VERSION="v3"
|
ARG MODS_VERSION="v3"
|
||||||
ARG PKG_INST_VERSION="v1"
|
ARG PKG_INST_VERSION="v1"
|
||||||
|
ARG LSIOWN_VERSION="v1"
|
||||||
|
ARG WITHCONTENV_VERSION="v1"
|
||||||
LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DATE}"
|
LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DATE}"
|
||||||
LABEL maintainer="TheLamer"
|
LABEL maintainer="TheLamer"
|
||||||
|
|
||||||
ADD --chmod=744 "https://raw.githubusercontent.com/linuxserver/docker-mods/mod-scripts/docker-mods.${MODS_VERSION}" "/docker-mods"
|
ADD --chmod=755 "https://raw.githubusercontent.com/linuxserver/docker-mods/mod-scripts/docker-mods.${MODS_VERSION}" "/docker-mods"
|
||||||
ADD --chmod=744 "https://raw.githubusercontent.com/linuxserver/docker-mods/mod-scripts/package-install.${PKG_INST_VERSION}" "/etc/s6-overlay/s6-rc.d/init-mods-package-install/run"
|
ADD --chmod=755 "https://raw.githubusercontent.com/linuxserver/docker-mods/mod-scripts/package-install.${PKG_INST_VERSION}" "/etc/s6-overlay/s6-rc.d/init-mods-package-install/run"
|
||||||
|
ADD --chmod=755 "https://raw.githubusercontent.com/linuxserver/docker-mods/mod-scripts/lsiown.${LSIOWN_VERSION}" "/usr/bin/lsiown"
|
||||||
|
ADD --chmod=755 "https://raw.githubusercontent.com/linuxserver/docker-mods/mod-scripts/with-contenv.${WITHCONTENV_VERSION}" "/usr/bin/with-contenv"
|
||||||
|
|
||||||
# environment variables
|
# environment variables
|
||||||
ENV PS1="$(whoami)@$(hostname):$(pwd)\\$ " \
|
ENV PS1="$(whoami)@$(hostname):$(pwd)\\$ " \
|
||||||
|
|
|
||||||
|
|
@ -1,10 +1,10 @@
|
||||||
# syntax=docker/dockerfile:1
|
# syntax=docker/dockerfile:1
|
||||||
|
|
||||||
FROM alpine:3.18 as rootfs-stage
|
FROM alpine:3.20 AS rootfs-stage
|
||||||
|
|
||||||
# environment
|
# environment
|
||||||
ENV ROOTFS=/root-out
|
ENV ROOTFS=/root-out
|
||||||
ENV REL=v3.19
|
ENV REL=v3.21
|
||||||
ENV ARCH=aarch64
|
ENV ARCH=aarch64
|
||||||
ENV MIRROR=http://dl-cdn.alpinelinux.org/alpine
|
ENV MIRROR=http://dl-cdn.alpinelinux.org/alpine
|
||||||
ENV PACKAGES=alpine-baselayout,\
|
ENV PACKAGES=alpine-baselayout,\
|
||||||
|
|
@ -30,7 +30,7 @@ RUN \
|
||||||
sed -i -e 's/^root::/root:!:/' /root-out/etc/shadow
|
sed -i -e 's/^root::/root:!:/' /root-out/etc/shadow
|
||||||
|
|
||||||
# set version for s6 overlay
|
# set version for s6 overlay
|
||||||
ARG S6_OVERLAY_VERSION="3.1.6.2"
|
ARG S6_OVERLAY_VERSION="3.2.0.2"
|
||||||
ARG S6_OVERLAY_ARCH="aarch64"
|
ARG S6_OVERLAY_ARCH="aarch64"
|
||||||
|
|
||||||
# add s6 overlay
|
# add s6 overlay
|
||||||
|
|
@ -41,7 +41,7 @@ RUN tar -C /root-out -Jxpf /tmp/s6-overlay-${S6_OVERLAY_ARCH}.tar.xz
|
||||||
|
|
||||||
# add s6 optional symlinks
|
# add s6 optional symlinks
|
||||||
ADD https://github.com/just-containers/s6-overlay/releases/download/v${S6_OVERLAY_VERSION}/s6-overlay-symlinks-noarch.tar.xz /tmp
|
ADD https://github.com/just-containers/s6-overlay/releases/download/v${S6_OVERLAY_VERSION}/s6-overlay-symlinks-noarch.tar.xz /tmp
|
||||||
RUN tar -C /root-out -Jxpf /tmp/s6-overlay-symlinks-noarch.tar.xz
|
RUN tar -C /root-out -Jxpf /tmp/s6-overlay-symlinks-noarch.tar.xz && unlink /root-out/usr/bin/with-contenv
|
||||||
ADD https://github.com/just-containers/s6-overlay/releases/download/v${S6_OVERLAY_VERSION}/s6-overlay-symlinks-arch.tar.xz /tmp
|
ADD https://github.com/just-containers/s6-overlay/releases/download/v${S6_OVERLAY_VERSION}/s6-overlay-symlinks-arch.tar.xz /tmp
|
||||||
RUN tar -C /root-out -Jxpf /tmp/s6-overlay-symlinks-arch.tar.xz
|
RUN tar -C /root-out -Jxpf /tmp/s6-overlay-symlinks-arch.tar.xz
|
||||||
|
|
||||||
|
|
@ -52,11 +52,15 @@ ARG BUILD_DATE
|
||||||
ARG VERSION
|
ARG VERSION
|
||||||
ARG MODS_VERSION="v3"
|
ARG MODS_VERSION="v3"
|
||||||
ARG PKG_INST_VERSION="v1"
|
ARG PKG_INST_VERSION="v1"
|
||||||
|
ARG LSIOWN_VERSION="v1"
|
||||||
|
ARG WITHCONTENV_VERSION="v1"
|
||||||
LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DATE}"
|
LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DATE}"
|
||||||
LABEL maintainer="TheLamer"
|
LABEL maintainer="TheLamer"
|
||||||
|
|
||||||
ADD --chmod=744 "https://raw.githubusercontent.com/linuxserver/docker-mods/mod-scripts/docker-mods.${MODS_VERSION}" "/docker-mods"
|
ADD --chmod=755 "https://raw.githubusercontent.com/linuxserver/docker-mods/mod-scripts/docker-mods.${MODS_VERSION}" "/docker-mods"
|
||||||
ADD --chmod=744 "https://raw.githubusercontent.com/linuxserver/docker-mods/mod-scripts/package-install.${PKG_INST_VERSION}" "/etc/s6-overlay/s6-rc.d/init-mods-package-install/run"
|
ADD --chmod=755 "https://raw.githubusercontent.com/linuxserver/docker-mods/mod-scripts/package-install.${PKG_INST_VERSION}" "/etc/s6-overlay/s6-rc.d/init-mods-package-install/run"
|
||||||
|
ADD --chmod=755 "https://raw.githubusercontent.com/linuxserver/docker-mods/mod-scripts/lsiown.${LSIOWN_VERSION}" "/usr/bin/lsiown"
|
||||||
|
ADD --chmod=755 "https://raw.githubusercontent.com/linuxserver/docker-mods/mod-scripts/with-contenv.${WITHCONTENV_VERSION}" "/usr/bin/with-contenv"
|
||||||
|
|
||||||
# environment variables
|
# environment variables
|
||||||
ENV PS1="$(whoami)@$(hostname):$(pwd)\\$ " \
|
ENV PS1="$(whoami)@$(hostname):$(pwd)\\$ " \
|
||||||
|
|
|
||||||
455
Jenkinsfile
vendored
455
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 {
|
||||||
|
|
@ -17,6 +17,8 @@ pipeline {
|
||||||
GITLAB_TOKEN=credentials('b6f0f1dd-6952-4cf6-95d1-9c06380283f0')
|
GITLAB_TOKEN=credentials('b6f0f1dd-6952-4cf6-95d1-9c06380283f0')
|
||||||
GITLAB_NAMESPACE=credentials('gitlab-namespace-id')
|
GITLAB_NAMESPACE=credentials('gitlab-namespace-id')
|
||||||
DOCKERHUB_TOKEN=credentials('docker-hub-ci-pat')
|
DOCKERHUB_TOKEN=credentials('docker-hub-ci-pat')
|
||||||
|
QUAYIO_API_TOKEN=credentials('quayio-repo-api-token')
|
||||||
|
GIT_SIGNING_KEY=credentials('484fbca6-9a4f-455e-b9e3-97ac98785f5f')
|
||||||
BUILD_VERSION_ARG = 'OS'
|
BUILD_VERSION_ARG = 'OS'
|
||||||
LS_USER = 'linuxserver'
|
LS_USER = 'linuxserver'
|
||||||
LS_REPO = 'docker-baseimage-alpine'
|
LS_REPO = 'docker-baseimage-alpine'
|
||||||
|
|
@ -31,24 +33,50 @@ pipeline {
|
||||||
CI_PORT='80'
|
CI_PORT='80'
|
||||||
CI_SSL='true'
|
CI_SSL='true'
|
||||||
CI_DELAY='30'
|
CI_DELAY='30'
|
||||||
CI_DOCKERENV='TZ=US/Pacific|LSIO_FIRST_PARTY=true'
|
CI_DOCKERENV='LSIO_FIRST_PARTY=true'
|
||||||
CI_AUTH='user:password'
|
CI_AUTH=''
|
||||||
CI_WEBPATH=''
|
CI_WEBPATH=''
|
||||||
}
|
}
|
||||||
stages {
|
stages {
|
||||||
|
stage("Set git config"){
|
||||||
|
steps{
|
||||||
|
sh '''#!/bin/bash
|
||||||
|
cat ${GIT_SIGNING_KEY} > /config/.ssh/id_sign
|
||||||
|
chmod 600 /config/.ssh/id_sign
|
||||||
|
ssh-keygen -y -f /config/.ssh/id_sign > /config/.ssh/id_sign.pub
|
||||||
|
echo "Using $(ssh-keygen -lf /config/.ssh/id_sign) to sign commits"
|
||||||
|
git config --global gpg.format ssh
|
||||||
|
git config --global user.signingkey /config/.ssh/id_sign
|
||||||
|
git config --global commit.gpgsign true
|
||||||
|
'''
|
||||||
|
}
|
||||||
|
}
|
||||||
// Setup all the basic environment variables needed for the build
|
// Setup all the basic environment variables needed for the build
|
||||||
stage("Set ENV Variables base"){
|
stage("Set ENV Variables base"){
|
||||||
steps{
|
steps{
|
||||||
|
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}:3.19 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}:3.21 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' ''',
|
||||||
|
|
@ -65,7 +93,7 @@ pipeline {
|
||||||
env.CODE_URL = 'https://github.com/' + env.LS_USER + '/' + env.LS_REPO + '/commit/' + env.GIT_COMMIT
|
env.CODE_URL = 'https://github.com/' + env.LS_USER + '/' + env.LS_REPO + '/commit/' + env.GIT_COMMIT
|
||||||
env.DOCKERHUB_LINK = 'https://hub.docker.com/r/' + env.DOCKERHUB_IMAGE + '/tags/'
|
env.DOCKERHUB_LINK = 'https://hub.docker.com/r/' + env.DOCKERHUB_IMAGE + '/tags/'
|
||||||
env.PULL_REQUEST = env.CHANGE_ID
|
env.PULL_REQUEST = env.CHANGE_ID
|
||||||
env.TEMPLATED_FILES = 'Jenkinsfile README.md LICENSE .editorconfig ./.github/CONTRIBUTING.md ./.github/FUNDING.yml ./.github/ISSUE_TEMPLATE/config.yml ./.github/ISSUE_TEMPLATE/issue.bug.yml ./.github/ISSUE_TEMPLATE/issue.feature.yml ./.github/PULL_REQUEST_TEMPLATE.md ./.github/workflows/external_trigger_scheduler.yml ./.github/workflows/greetings.yml ./.github/workflows/package_trigger_scheduler.yml ./.github/workflows/call_issue_pr_tracker.yml ./.github/workflows/call_issues_cron.yml ./.github/workflows/permissions.yml ./.github/workflows/external_trigger.yml ./.github/workflows/package_trigger.yml'
|
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'
|
||||||
}
|
}
|
||||||
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}" '''
|
||||||
|
|
@ -77,7 +105,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 3.19-${LS_RELEASE} 2>/dev/null)
|
tagsha=$(git rev-list -n 1 3.21-${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
|
||||||
|
|
@ -166,13 +194,14 @@ 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-3.19-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER + '|arm64v8-3.19-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER
|
env.CI_TAGS = 'amd64-3.21-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER + '|arm64v8-3.21-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER
|
||||||
} else {
|
} else {
|
||||||
env.CI_TAGS = '3.19-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER
|
env.CI_TAGS = '3.21-' + 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 = '3.19-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER
|
env.META_TAG = '3.21-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER
|
||||||
env.EXT_RELEASE_TAG = '3.19-version-' + env.EXT_RELEASE_CLEAN
|
env.EXT_RELEASE_TAG = '3.21-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'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -189,14 +218,15 @@ 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-3.19-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA + '|arm64v8-3.19-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA
|
env.CI_TAGS = 'amd64-3.21-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA + '|arm64v8-3.21-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA
|
||||||
} else {
|
} else {
|
||||||
env.CI_TAGS = '3.19-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA
|
env.CI_TAGS = '3.21-' + 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 = '3.19-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA
|
env.META_TAG = '3.21-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA
|
||||||
env.EXT_RELEASE_TAG = '3.19-version-' + env.EXT_RELEASE_CLEAN
|
env.EXT_RELEASE_TAG = '3.21-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'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -212,15 +242,16 @@ 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-3.19-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA + '-pr-' + env.PULL_REQUEST + '|arm64v8-3.19-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA + '-pr-' + env.PULL_REQUEST
|
env.CI_TAGS = 'amd64-3.21-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA + '-pr-' + env.PULL_REQUEST + '|arm64v8-3.21-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA + '-pr-' + env.PULL_REQUEST
|
||||||
} else {
|
} else {
|
||||||
env.CI_TAGS = '3.19-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA + '-pr-' + env.PULL_REQUEST
|
env.CI_TAGS = '3.21-' + 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 = '3.19-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA + '-pr-' + env.PULL_REQUEST
|
env.META_TAG = '3.21-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA + '-pr-' + env.PULL_REQUEST
|
||||||
env.EXT_RELEASE_TAG = '3.19-version-' + env.EXT_RELEASE_CLEAN
|
env.EXT_RELEASE_TAG = '3.21-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'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -243,7 +274,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.19 s6-envdir -fn -- /var/run/s6/container_environment /bin/bash -c "\
|
ghcr.io/linuxserver/baseimage-alpine:3.20 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 && \
|
||||||
|
|
@ -293,7 +324,7 @@ pipeline {
|
||||||
echo "Jenkinsfile is up to date."
|
echo "Jenkinsfile is up to date."
|
||||||
fi
|
fi
|
||||||
echo "Starting Stage 2 - Delete old templates"
|
echo "Starting Stage 2 - Delete old templates"
|
||||||
OLD_TEMPLATES=".github/ISSUE_TEMPLATE.md .github/ISSUE_TEMPLATE/issue.bug.md .github/ISSUE_TEMPLATE/issue.feature.md .github/workflows/call_invalid_helper.yml .github/workflows/stale.yml Dockerfile.armhf"
|
OLD_TEMPLATES=".github/ISSUE_TEMPLATE.md .github/ISSUE_TEMPLATE/issue.bug.md .github/ISSUE_TEMPLATE/issue.feature.md .github/workflows/call_invalid_helper.yml .github/workflows/stale.yml .github/workflows/package_trigger.yml"
|
||||||
for i in ${OLD_TEMPLATES}; do
|
for i in ${OLD_TEMPLATES}; do
|
||||||
if [[ -f "${i}" ]]; then
|
if [[ -f "${i}" ]]; then
|
||||||
TEMPLATES_TO_DELETE="${i} ${TEMPLATES_TO_DELETE}"
|
TEMPLATES_TO_DELETE="${i} ${TEMPLATES_TO_DELETE}"
|
||||||
|
|
@ -350,7 +381,7 @@ pipeline {
|
||||||
fi
|
fi
|
||||||
echo "Starting Stage 4 - External repo updates: Docs, Unraid Template and Readme Sync to Docker Hub"
|
echo "Starting Stage 4 - External repo updates: Docs, Unraid Template and Readme Sync to Docker Hub"
|
||||||
mkdir -p ${TEMPDIR}/docs
|
mkdir -p ${TEMPDIR}/docs
|
||||||
git clone https://github.com/linuxserver/docker-documentation.git ${TEMPDIR}/docs/docker-documentation
|
git clone --depth=1 https://github.com/linuxserver/docker-documentation.git ${TEMPDIR}/docs/docker-documentation
|
||||||
if [[ "${BRANCH_NAME}" == "${GH_DEFAULT_BRANCH}" ]] && [[ (! -f ${TEMPDIR}/docs/docker-documentation/docs/images/docker-${CONTAINER_NAME}.md) || ("$(md5sum ${TEMPDIR}/docs/docker-documentation/docs/images/docker-${CONTAINER_NAME}.md | awk '{ print $1 }')" != "$(md5sum ${TEMPDIR}/docker-${CONTAINER_NAME}/.jenkins-external/docker-${CONTAINER_NAME}.md | awk '{ print $1 }')") ]]; then
|
if [[ "${BRANCH_NAME}" == "${GH_DEFAULT_BRANCH}" ]] && [[ (! -f ${TEMPDIR}/docs/docker-documentation/docs/images/docker-${CONTAINER_NAME}.md) || ("$(md5sum ${TEMPDIR}/docs/docker-documentation/docs/images/docker-${CONTAINER_NAME}.md | awk '{ print $1 }')" != "$(md5sum ${TEMPDIR}/docker-${CONTAINER_NAME}/.jenkins-external/docker-${CONTAINER_NAME}.md | awk '{ print $1 }')") ]]; then
|
||||||
cp ${TEMPDIR}/docker-${CONTAINER_NAME}/.jenkins-external/docker-${CONTAINER_NAME}.md ${TEMPDIR}/docs/docker-documentation/docs/images/
|
cp ${TEMPDIR}/docker-${CONTAINER_NAME}/.jenkins-external/docker-${CONTAINER_NAME}.md ${TEMPDIR}/docs/docker-documentation/docs/images/
|
||||||
cd ${TEMPDIR}/docs/docker-documentation
|
cd ${TEMPDIR}/docs/docker-documentation
|
||||||
|
|
@ -440,10 +471,10 @@ pipeline {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/* #######################
|
/* #######################
|
||||||
GitLab Mirroring
|
GitLab Mirroring and Quay.io Repo Visibility
|
||||||
####################### */
|
####################### */
|
||||||
// Ping into Gitlab to mirror this repo and have a registry endpoint
|
// Ping into Gitlab to mirror this repo and have a registry endpoint & mark this repo on Quay.io as public
|
||||||
stage("GitLab Mirror"){
|
stage("GitLab Mirror and Quay.io Visibility"){
|
||||||
when {
|
when {
|
||||||
environment name: 'EXIT_STATUS', value: ''
|
environment name: 'EXIT_STATUS', value: ''
|
||||||
}
|
}
|
||||||
|
|
@ -459,6 +490,8 @@ pipeline {
|
||||||
"visibility":"public"}' '''
|
"visibility":"public"}' '''
|
||||||
sh '''curl -H "Private-Token: ${GITLAB_TOKEN}" -X PUT "https://gitlab.com/api/v4/projects/Linuxserver.io%2F${LS_REPO}" \
|
sh '''curl -H "Private-Token: ${GITLAB_TOKEN}" -X PUT "https://gitlab.com/api/v4/projects/Linuxserver.io%2F${LS_REPO}" \
|
||||||
-d "mirror=true&import_url=https://github.com/linuxserver/${LS_REPO}.git" '''
|
-d "mirror=true&import_url=https://github.com/linuxserver/${LS_REPO}.git" '''
|
||||||
|
sh '''curl -H "Content-Type: application/json" -H "Authorization: Bearer ${QUAYIO_API_TOKEN}" -X POST "https://quay.io/api/v1/repository${QUAYIMAGE/quay.io/}/changevisibility" \
|
||||||
|
-d '{"visibility":"public"}' ||: '''
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/* ###############
|
/* ###############
|
||||||
|
|
@ -488,7 +521,42 @@ pipeline {
|
||||||
--label \"org.opencontainers.image.title=Baseimage-alpine\" \
|
--label \"org.opencontainers.image.title=Baseimage-alpine\" \
|
||||||
--label \"org.opencontainers.image.description=baseimage-alpine image by linuxserver.io\" \
|
--label \"org.opencontainers.image.description=baseimage-alpine image by linuxserver.io\" \
|
||||||
--no-cache --pull -t ${IMAGE}:${META_TAG} --platform=linux/amd64 \
|
--no-cache --pull -t ${IMAGE}:${META_TAG} --platform=linux/amd64 \
|
||||||
|
--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
|
||||||
|
IFS=',' read -ra CACHE <<< "$BUILDCACHE"
|
||||||
|
for i in "${CACHE[@]}"; do
|
||||||
|
docker push ${i}:amd64-${COMMIT_SHA}-${BUILD_NUMBER} &
|
||||||
|
done
|
||||||
|
for p in $(jobs -p); do
|
||||||
|
wait "$p" || { echo "job $p failed" >&2; exit 1; }
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
'''
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// Build MultiArch Docker containers for push to LS Repo
|
// Build MultiArch Docker containers for push to LS Repo
|
||||||
|
|
@ -518,7 +586,42 @@ pipeline {
|
||||||
--label \"org.opencontainers.image.title=Baseimage-alpine\" \
|
--label \"org.opencontainers.image.title=Baseimage-alpine\" \
|
||||||
--label \"org.opencontainers.image.description=baseimage-alpine image by linuxserver.io\" \
|
--label \"org.opencontainers.image.description=baseimage-alpine image by linuxserver.io\" \
|
||||||
--no-cache --pull -t ${IMAGE}:amd64-${META_TAG} --platform=linux/amd64 \
|
--no-cache --pull -t ${IMAGE}:amd64-${META_TAG} --platform=linux/amd64 \
|
||||||
|
--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
|
||||||
|
IFS=',' read -ra CACHE <<< "$BUILDCACHE"
|
||||||
|
for i in "${CACHE[@]}"; do
|
||||||
|
docker push ${i}:amd64-${COMMIT_SHA}-${BUILD_NUMBER} &
|
||||||
|
done
|
||||||
|
for p in $(jobs -p); do
|
||||||
|
wait "$p" || { echo "job $p failed" >&2; exit 1; }
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
'''
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
stage('Build ARM64') {
|
stage('Build ARM64') {
|
||||||
|
|
@ -527,10 +630,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 "docker buildx build \
|
sh "docker buildx build \
|
||||||
--label \"org.opencontainers.image.created=${GITHUB_DATE}\" \
|
--label \"org.opencontainers.image.created=${GITHUB_DATE}\" \
|
||||||
--label \"org.opencontainers.image.authors=linuxserver.io\" \
|
--label \"org.opencontainers.image.authors=linuxserver.io\" \
|
||||||
|
|
@ -545,17 +644,50 @@ pipeline {
|
||||||
--label \"org.opencontainers.image.title=Baseimage-alpine\" \
|
--label \"org.opencontainers.image.title=Baseimage-alpine\" \
|
||||||
--label \"org.opencontainers.image.description=baseimage-alpine image by linuxserver.io\" \
|
--label \"org.opencontainers.image.description=baseimage-alpine image by linuxserver.io\" \
|
||||||
--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=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(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
|
||||||
|
IFS=',' read -ra CACHE <<< "$BUILDCACHE"
|
||||||
|
for i in "${CACHE[@]}"; do
|
||||||
|
docker push ${i}:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER} &
|
||||||
|
done
|
||||||
|
for p in $(jobs -p); do
|
||||||
|
wait "$p" || { echo "job $p failed" >&2; 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 || :
|
||||||
|
'''
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -659,27 +791,37 @@ pipeline {
|
||||||
}
|
}
|
||||||
sh '''#! /bin/bash
|
sh '''#! /bin/bash
|
||||||
set -e
|
set -e
|
||||||
|
if grep -q 'docker-baseimage' <<< "${LS_REPO}"; then
|
||||||
|
echo "Detected baseimage, setting LSIO_FIRST_PARTY=true"
|
||||||
|
if [ -n "${CI_DOCKERENV}" ]; then
|
||||||
|
CI_DOCKERENV="LSIO_FIRST_PARTY=true|${CI_DOCKERENV}"
|
||||||
|
else
|
||||||
|
CI_DOCKERENV="LSIO_FIRST_PARTY=true"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
docker pull ghcr.io/linuxserver/ci:latest
|
docker pull ghcr.io/linuxserver/ci:latest
|
||||||
if [ "${MULTIARCH}" == "true" ]; then
|
if [ "${MULTIARCH}" == "true" ]; then
|
||||||
docker pull ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER}
|
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}
|
||||||
fi
|
fi
|
||||||
docker run --rm \
|
docker run --rm \
|
||||||
--shm-size=1gb \
|
--shm-size=1gb \
|
||||||
-v /var/run/docker.sock:/var/run/docker.sock \
|
-v /var/run/docker.sock:/var/run/docker.sock \
|
||||||
-e IMAGE=\"${IMAGE}\" \
|
-e IMAGE=\"${IMAGE}\" \
|
||||||
-e DELAY_START=\"${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=\"3.21\" \
|
||||||
-e PORT=\"${CI_PORT}\" \
|
-e PORT=\"${CI_PORT}\" \
|
||||||
-e SSL=\"${CI_SSL}\" \
|
-e SSL=\"${CI_SSL}\" \
|
||||||
-e BASE=\"${DIST_IMAGE}\" \
|
-e BASE=\"${DIST_IMAGE}\" \
|
||||||
-e SECRET_KEY=\"${S3_SECRET}\" \
|
-e SECRET_KEY=\"${S3_SECRET}\" \
|
||||||
-e ACCESS_KEY=\"${S3_KEY}\" \
|
-e ACCESS_KEY=\"${S3_KEY}\" \
|
||||||
-e DOCKER_ENV=\"LSIO_FIRST_PARTY=true|${CI_DOCKERENV}\" \
|
-e DOCKER_ENV=\"${CI_DOCKERENV}\" \
|
||||||
-e WEB_SCREENSHOT=\"${CI_WEB}\" \
|
-e WEB_SCREENSHOT=\"${CI_WEB}\" \
|
||||||
-e WEB_AUTH=\"${CI_AUTH}\" \
|
-e WEB_AUTH=\"${CI_AUTH}\" \
|
||||||
-e WEB_PATH=\"${CI_WEBPATH}\" \
|
-e WEB_PATH=\"${CI_WEBPATH}\" \
|
||||||
|
-e NODE_NAME=\"${NODE_NAME}\" \
|
||||||
-t ghcr.io/linuxserver/ci:latest \
|
-t ghcr.io/linuxserver/ci:latest \
|
||||||
python3 test_build.py'''
|
python3 test_build.py'''
|
||||||
}
|
}
|
||||||
|
|
@ -695,37 +837,23 @@ 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(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}:3.19
|
|
||||||
docker tag ${PUSHIMAGE}:${META_TAG} ${PUSHIMAGE}:${EXT_RELEASE_TAG}
|
|
||||||
if [ -n "${SEMVER}" ]; then
|
|
||||||
docker tag ${PUSHIMAGE}:${META_TAG} ${PUSHIMAGE}:${SEMVER}
|
|
||||||
fi
|
|
||||||
docker push ${PUSHIMAGE}:3.19
|
|
||||||
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}:3.21 -t ${PUSHIMAGE}:${EXT_RELEASE_TAG} ${CACHEIMAGE}:amd64-${COMMIT_SHA}-${BUILD_NUMBER}
|
||||||
}
|
if [ -n "${SEMVER}" ]; then
|
||||||
|
docker buildx imagetools create --prefer-index=false -t ${PUSHIMAGE}:${SEMVER} ${CACHEIMAGE}:amd64-${COMMIT_SHA}-${BUILD_NUMBER}
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
'''
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -736,79 +864,34 @@ 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(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
|
|
||||||
if [ "${CI}" == "false" ]; then
|
|
||||||
docker pull ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER}
|
|
||||||
docker tag ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER} ${IMAGE}:arm64v8-${META_TAG}
|
|
||||||
fi
|
|
||||||
for MANIFESTIMAGE in "${IMAGE}" "${GITLABIMAGE}" "${GITHUBIMAGE}" "${QUAYIMAGE}"; do
|
|
||||||
docker tag ${IMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-${META_TAG}
|
|
||||||
docker tag ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-3.19
|
|
||||||
docker tag ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-${EXT_RELEASE_TAG}
|
|
||||||
docker tag ${IMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${META_TAG}
|
|
||||||
docker tag ${MANIFESTIMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-3.19
|
|
||||||
docker tag ${MANIFESTIMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${EXT_RELEASE_TAG}
|
|
||||||
if [ -n "${SEMVER}" ]; then
|
|
||||||
docker tag ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-${SEMVER}
|
|
||||||
docker tag ${MANIFESTIMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${SEMVER}
|
|
||||||
fi
|
|
||||||
docker push ${MANIFESTIMAGE}:amd64-${META_TAG}
|
|
||||||
docker push ${MANIFESTIMAGE}:amd64-${EXT_RELEASE_TAG}
|
|
||||||
docker push ${MANIFESTIMAGE}:amd64-3.19
|
|
||||||
docker push ${MANIFESTIMAGE}:arm64v8-${META_TAG}
|
|
||||||
docker push ${MANIFESTIMAGE}:arm64v8-3.19
|
|
||||||
docker push ${MANIFESTIMAGE}:arm64v8-${EXT_RELEASE_TAG}
|
|
||||||
if [ -n "${SEMVER}" ]; then
|
|
||||||
docker push ${MANIFESTIMAGE}:amd64-${SEMVER}
|
|
||||||
docker push ${MANIFESTIMAGE}:arm64v8-${SEMVER}
|
|
||||||
fi
|
|
||||||
docker manifest push --purge ${MANIFESTIMAGE}:3.19 || :
|
|
||||||
docker manifest create ${MANIFESTIMAGE}:3.19 ${MANIFESTIMAGE}:amd64-3.19 ${MANIFESTIMAGE}:arm64v8-3.19
|
|
||||||
docker manifest annotate ${MANIFESTIMAGE}:3.19 ${MANIFESTIMAGE}:arm64v8-3.19 --os linux --arch arm64 --variant v8
|
|
||||||
docker manifest push --purge ${MANIFESTIMAGE}:${META_TAG} || :
|
|
||||||
docker manifest create ${MANIFESTIMAGE}:${META_TAG} ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${META_TAG}
|
|
||||||
docker manifest annotate ${MANIFESTIMAGE}:${META_TAG} ${MANIFESTIMAGE}:arm64v8-${META_TAG} --os linux --arch arm64 --variant v8
|
|
||||||
docker manifest push --purge ${MANIFESTIMAGE}:${EXT_RELEASE_TAG} || :
|
|
||||||
docker manifest create ${MANIFESTIMAGE}:${EXT_RELEASE_TAG} ${MANIFESTIMAGE}:amd64-${EXT_RELEASE_TAG} ${MANIFESTIMAGE}:arm64v8-${EXT_RELEASE_TAG}
|
|
||||||
docker manifest annotate ${MANIFESTIMAGE}:${EXT_RELEASE_TAG} ${MANIFESTIMAGE}:arm64v8-${EXT_RELEASE_TAG} --os linux --arch arm64 --variant v8
|
|
||||||
if [ -n "${SEMVER}" ]; then
|
|
||||||
docker manifest push --purge ${MANIFESTIMAGE}:${SEMVER} || :
|
|
||||||
docker manifest create ${MANIFESTIMAGE}:${SEMVER} ${MANIFESTIMAGE}:amd64-${SEMVER} ${MANIFESTIMAGE}:arm64v8-${SEMVER}
|
|
||||||
docker manifest annotate ${MANIFESTIMAGE}:${SEMVER} ${MANIFESTIMAGE}:arm64v8-${SEMVER} --os linux --arch arm64 --variant v8
|
|
||||||
fi
|
|
||||||
token=$(curl -sX GET "https://ghcr.io/token?scope=repository%3Alinuxserver%2F${CONTAINER_NAME}%3Apull" | jq -r '.token')
|
|
||||||
digest=$(curl -s \
|
|
||||||
--header "Accept: application/vnd.docker.distribution.manifest.v2+json" \
|
|
||||||
--header "Authorization: Bearer ${token}" \
|
|
||||||
"https://ghcr.io/v2/linuxserver/${CONTAINER_NAME}/manifests/arm32v7-3.19")
|
|
||||||
if [[ $(echo "$digest" | jq -r '.layers') != "null" ]]; then
|
|
||||||
docker manifest push --purge ${MANIFESTIMAGE}:arm32v7-3.19 || :
|
|
||||||
docker manifest create ${MANIFESTIMAGE}:arm32v7-3.19 ${MANIFESTIMAGE}:amd64-3.19
|
|
||||||
docker manifest push --purge ${MANIFESTIMAGE}:arm32v7-3.19
|
|
||||||
fi
|
|
||||||
docker manifest push --purge ${MANIFESTIMAGE}:3.19
|
|
||||||
docker manifest push --purge ${MANIFESTIMAGE}:${META_TAG}
|
|
||||||
docker manifest push --purge ${MANIFESTIMAGE}:${EXT_RELEASE_TAG}
|
|
||||||
if [ -n "${SEMVER}" ]; then
|
|
||||||
docker manifest push --purge ${MANIFESTIMAGE}:${SEMVER}
|
|
||||||
fi
|
|
||||||
done
|
done
|
||||||
'''
|
docker buildx imagetools create --prefer-index=false -t ${MANIFESTIMAGE}:amd64-${META_TAG} -t ${MANIFESTIMAGE}:amd64-3.21 -t ${MANIFESTIMAGE}:amd64-${EXT_RELEASE_TAG} ${CACHEIMAGE}:amd64-${COMMIT_SHA}-${BUILD_NUMBER}
|
||||||
}
|
docker buildx imagetools create --prefer-index=false -t ${MANIFESTIMAGE}:arm64v8-${META_TAG} -t ${MANIFESTIMAGE}:arm64v8-3.21 -t ${MANIFESTIMAGE}:arm64v8-${EXT_RELEASE_TAG} ${CACHEIMAGE}:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER}
|
||||||
|
if [ -n "${SEMVER}" ]; then
|
||||||
|
docker buildx imagetools create --prefer-index=false -t ${MANIFESTIMAGE}:amd64-${SEMVER} ${CACHEIMAGE}:amd64-${COMMIT_SHA}-${BUILD_NUMBER}
|
||||||
|
docker buildx imagetools create --prefer-index=false -t ${MANIFESTIMAGE}:arm64v8-${SEMVER} ${CACHEIMAGE}:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER}
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
for MANIFESTIMAGE in "${IMAGE}" "${GITLABIMAGE}" "${GITHUBIMAGE}" "${QUAYIMAGE}"; do
|
||||||
|
docker buildx imagetools create -t ${MANIFESTIMAGE}:3.21 ${MANIFESTIMAGE}:amd64-3.21 ${MANIFESTIMAGE}:arm64v8-3.21
|
||||||
|
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
|
||||||
|
'''
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -829,14 +912,14 @@ pipeline {
|
||||||
"object": "'${COMMIT_SHA}'",\
|
"object": "'${COMMIT_SHA}'",\
|
||||||
"message": "Tagging Release '${EXT_RELEASE_CLEAN}'-ls'${LS_TAG_NUMBER}' to master",\
|
"message": "Tagging Release '${EXT_RELEASE_CLEAN}'-ls'${LS_TAG_NUMBER}' to master",\
|
||||||
"type": "commit",\
|
"type": "commit",\
|
||||||
"tagger": {"name": "LinuxServer Jenkins","email": "jenkins@linuxserver.io","date": "'${GITHUB_DATE}'"}}' '''
|
"tagger": {"name": "LinuxServer-CI","email": "ci@linuxserver.io","date": "'${GITHUB_DATE}'"}}' '''
|
||||||
echo "Pushing New release for Tag"
|
echo "Pushing New release for Tag"
|
||||||
sh '''#! /bin/bash
|
sh '''#! /bin/bash
|
||||||
echo "Updating base packages to ${PACKAGE_TAG}" > releasebody.json
|
echo "Updating base packages to ${PACKAGE_TAG}" > releasebody.json
|
||||||
echo '{"tag_name":"'${META_TAG}'",\
|
echo '{"tag_name":"'${META_TAG}'",\
|
||||||
"target_commitish": "master",\
|
"target_commitish": "master",\
|
||||||
"name": "'${META_TAG}'",\
|
"name": "'${META_TAG}'",\
|
||||||
"body": "**LinuxServer Changes:**\\n\\n'${LS_RELEASE_NOTES}'\\n\\n**OS Changes:**\\n\\n' > start
|
"body": "**CI Report:**\\n\\n'${CI_URL:-N/A}'\\n\\n**LinuxServer Changes:**\\n\\n'${LS_RELEASE_NOTES}'\\n\\n**Remote Changes:**\\n\\n' > start
|
||||||
printf '","draft": false,"prerelease": false}' >> releasebody.json
|
printf '","draft": false,"prerelease": false}' >> releasebody.json
|
||||||
paste -d'\\0' start releasebody.json > releasebody.json.done
|
paste -d'\\0' start releasebody.json > releasebody.json.done
|
||||||
curl -H "Authorization: token ${GITHUB_TOKEN}" -X POST https://api.github.com/repos/${LS_USER}/${LS_REPO}/releases -d @releasebody.json.done'''
|
curl -H "Authorization: token ${GITHUB_TOKEN}" -X POST https://api.github.com/repos/${LS_USER}/${LS_REPO}/releases -d @releasebody.json.done'''
|
||||||
|
|
@ -961,32 +1044,94 @@ EOF
|
||||||
###################### */
|
###################### */
|
||||||
post {
|
post {
|
||||||
always {
|
always {
|
||||||
|
sh '''#!/bin/bash
|
||||||
|
rm -rf /config/.ssh/id_sign
|
||||||
|
rm -rf /config/.ssh/id_sign.pub
|
||||||
|
git config --global --unset gpg.format
|
||||||
|
git config --global --unset user.signingkey
|
||||||
|
git config --global --unset commit.gpgsign
|
||||||
|
'''
|
||||||
script{
|
script{
|
||||||
|
env.JOB_DATE = sh(
|
||||||
|
script: '''date '+%Y-%m-%dT%H:%M:%S%:z' ''',
|
||||||
|
returnStdout: true).trim()
|
||||||
if (env.EXIT_STATUS == "ABORTED"){
|
if (env.EXIT_STATUS == "ABORTED"){
|
||||||
sh 'echo "build aborted"'
|
sh 'echo "build aborted"'
|
||||||
}
|
}else{
|
||||||
else if (currentBuild.currentResult == "SUCCESS"){
|
if (currentBuild.currentResult == "SUCCESS"){
|
||||||
sh ''' curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://raw.githubusercontent.com/linuxserver/docker-templates/master/linuxserver.io/img/jenkins-avatar.png","embeds": [{"color": 1681177,\
|
if (env.GITHUBIMAGE =~ /lspipepr/){
|
||||||
"description": "**Build:** '${BUILD_NUMBER}'\\n**CI Results:** '${CI_URL}'\\n**ShellCheck Results:** '${SHELLCHECK_URL}'\\n**Status:** Success\\n**Job:** '${RUN_DISPLAY_URL}'\\n**Change:** '${CODE_URL}'\\n**External Release:**: '${RELEASE_LINK}'\\n**DockerHub:** '${DOCKERHUB_LINK}'\\n"}],\
|
env.JOB_WEBHOOK_STATUS='Success'
|
||||||
"username": "Jenkins"}' ${BUILDS_DISCORD} '''
|
env.JOB_WEBHOOK_COLOUR=3957028
|
||||||
}
|
env.JOB_WEBHOOK_FOOTER='PR Build'
|
||||||
else {
|
}else if (env.GITHUBIMAGE =~ /lsiodev/){
|
||||||
sh ''' curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://raw.githubusercontent.com/linuxserver/docker-templates/master/linuxserver.io/img/jenkins-avatar.png","embeds": [{"color": 16711680,\
|
env.JOB_WEBHOOK_STATUS='Success'
|
||||||
"description": "**Build:** '${BUILD_NUMBER}'\\n**CI Results:** '${CI_URL}'\\n**ShellCheck Results:** '${SHELLCHECK_URL}'\\n**Status:** failure\\n**Job:** '${RUN_DISPLAY_URL}'\\n**Change:** '${CODE_URL}'\\n**External Release:**: '${RELEASE_LINK}'\\n**DockerHub:** '${DOCKERHUB_LINK}'\\n"}],\
|
env.JOB_WEBHOOK_COLOUR=3957028
|
||||||
|
env.JOB_WEBHOOK_FOOTER='Dev Build'
|
||||||
|
}else{
|
||||||
|
env.JOB_WEBHOOK_STATUS='Success'
|
||||||
|
env.JOB_WEBHOOK_COLOUR=1681177
|
||||||
|
env.JOB_WEBHOOK_FOOTER='Live Build'
|
||||||
|
}
|
||||||
|
}else{
|
||||||
|
if (env.GITHUBIMAGE =~ /lspipepr/){
|
||||||
|
env.JOB_WEBHOOK_STATUS='Failure'
|
||||||
|
env.JOB_WEBHOOK_COLOUR=12669523
|
||||||
|
env.JOB_WEBHOOK_FOOTER='PR Build'
|
||||||
|
}else if (env.GITHUBIMAGE =~ /lsiodev/){
|
||||||
|
env.JOB_WEBHOOK_STATUS='Failure'
|
||||||
|
env.JOB_WEBHOOK_COLOUR=12669523
|
||||||
|
env.JOB_WEBHOOK_FOOTER='Dev Build'
|
||||||
|
}else{
|
||||||
|
env.JOB_WEBHOOK_STATUS='Failure'
|
||||||
|
env.JOB_WEBHOOK_COLOUR=16711680
|
||||||
|
env.JOB_WEBHOOK_FOOTER='Live Build'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
sh ''' curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://raw.githubusercontent.com/linuxserver/docker-templates/master/linuxserver.io/img/jenkins-avatar.png","embeds": [{"'color'": '${JOB_WEBHOOK_COLOUR}',\
|
||||||
|
"footer": {"text" : "'"${JOB_WEBHOOK_FOOTER}"'"},\
|
||||||
|
"timestamp": "'${JOB_DATE}'",\
|
||||||
|
"description": "**Build:** '${BUILD_NUMBER}'\\n**CI Results:** '${CI_URL}'\\n**ShellCheck Results:** '${SHELLCHECK_URL}'\\n**Status:** '${JOB_WEBHOOK_STATUS}'\\n**Job:** '${RUN_DISPLAY_URL}'\\n**Change:** '${CODE_URL}'\\n**External Release:**: '${RELEASE_LINK}'\\n**DockerHub:** '${DOCKERHUB_LINK}'\\n"}],\
|
||||||
"username": "Jenkins"}' ${BUILDS_DISCORD} '''
|
"username": "Jenkins"}' ${BUILDS_DISCORD} '''
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
cleanup {
|
cleanup {
|
||||||
sh '''#! /bin/bash
|
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()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
def retry_backoff(int max_attempts, int power_base, Closure c) {
|
||||||
|
int n = 0
|
||||||
|
while (n < max_attempts) {
|
||||||
|
try {
|
||||||
|
c()
|
||||||
|
return
|
||||||
|
} catch (err) {
|
||||||
|
if ((n + 1) >= max_attempts) {
|
||||||
|
throw err
|
||||||
|
}
|
||||||
|
sleep(power_base ** n)
|
||||||
|
n++
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
|
||||||
30
README.md
30
README.md
|
|
@ -1,29 +1 @@
|
||||||
<!-- DO NOT EDIT THIS FILE MANUALLY -->
|
A custom base image built with [Alpine Linux](https://alpinelinux.org) and [s6-overlay](https://github.com/just-containers/s6-overlay).
|
||||||
<!-- Please read https://github.com/linuxserver/docker-baseimage-alpine/blob/master/.github/CONTRIBUTING.md -->
|
|
||||||
[linuxserverurl]: https://linuxserver.io
|
|
||||||
[forumurl]: https://forum.linuxserver.io
|
|
||||||
[ircurl]: https://mibbit.com/?server=irc.libera.chat&channel=%23linuxserver.io
|
|
||||||
[appurl]: https://alpinelinux.org
|
|
||||||
|
|
||||||
[][linuxserverurl]
|
|
||||||
|
|
||||||
## Contact information:-
|
|
||||||
|
|
||||||
| Type | Address/Details |
|
|
||||||
| :---: | --- |
|
|
||||||
| Discord | [Discord](https://discord.gg/YWrKVTn) |
|
|
||||||
| IRC | libera at `#linuxserver.io` more information at:- [IRC][ircurl]
|
|
||||||
| Forum | [LinuxServer.io forum][forumurl] |
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
[](https://microbadger.com/images/lsiobase/alpine "Get your own image badge on microbadger.com")
|
|
||||||
|
|
||||||
[](https://github.com/linuxserver/docker-baseimage-alpine/blob/master/Dockerfile)
|
|
||||||
|
|
||||||
A custom base image built with [Alpine linux][appurl] and [S6 overlay](https://github.com/just-containers/s6-overlay)..
|
|
||||||
|
|
||||||
The following line is only in this repo for loop testing:
|
|
||||||
|
|
||||||
- { date: "01.01.50:", desc: "I am the release message for this internal repo." }
|
|
||||||
|
|
|
||||||
|
|
@ -4,8 +4,10 @@
|
||||||
project_name: docker-baseimage-alpine
|
project_name: docker-baseimage-alpine
|
||||||
external_type: os
|
external_type: os
|
||||||
release_type: stable
|
release_type: stable
|
||||||
release_tag: "3.19"
|
release_tag: "3.21"
|
||||||
ls_branch: master
|
ls_branch: master
|
||||||
|
image_sbom: true
|
||||||
|
image_provenance: true
|
||||||
repo_vars:
|
repo_vars:
|
||||||
- BUILD_VERSION_ARG = 'OS'
|
- BUILD_VERSION_ARG = 'OS'
|
||||||
- LS_USER = 'linuxserver'
|
- LS_USER = 'linuxserver'
|
||||||
|
|
@ -21,6 +23,6 @@ repo_vars:
|
||||||
- CI_PORT='80'
|
- CI_PORT='80'
|
||||||
- CI_SSL='true'
|
- CI_SSL='true'
|
||||||
- CI_DELAY='30'
|
- CI_DELAY='30'
|
||||||
- CI_DOCKERENV='TZ=US/Pacific|LSIO_FIRST_PARTY=true'
|
- CI_DOCKERENV='LSIO_FIRST_PARTY=true'
|
||||||
- CI_AUTH='user:password'
|
- CI_AUTH=''
|
||||||
- CI_WEBPATH=''
|
- CI_WEBPATH=''
|
||||||
|
|
|
||||||
|
|
@ -1,50 +1,51 @@
|
||||||
NAME VERSION TYPE
|
NAME VERSION TYPE
|
||||||
alpine-baselayout 3.4.3-r2 apk
|
acl-libs 2.3.2-r1 apk
|
||||||
alpine-baselayout-data 3.4.3-r2 apk
|
alpine-baselayout 3.6.8-r1 apk
|
||||||
alpine-keys 2.4-r1 apk
|
alpine-baselayout-data 3.6.8-r1 apk
|
||||||
alpine-release 3.19.1-r0 apk
|
alpine-keys 2.5-r0 apk
|
||||||
apk-tools 2.14.4-r0 apk
|
alpine-release 3.21.3-r0 apk
|
||||||
bash 5.2.21-r0 apk
|
apk-tools 2.14.6-r3 apk
|
||||||
brotli-libs 1.1.0-r1 apk
|
bash 5.2.37-r0 apk
|
||||||
busybox 1.36.1-r15 apk
|
brotli-libs 1.1.0-r2 apk
|
||||||
busybox-binsh 1.36.1-r15 apk
|
busybox 1.37.0-r12 apk
|
||||||
c-ares 1.27.0-r0 apk
|
busybox-binsh 1.37.0-r12 apk
|
||||||
ca-certificates 20240226-r0 apk
|
c-ares 1.34.5-r0 apk
|
||||||
ca-certificates-bundle 20240226-r0 apk
|
ca-certificates 20241121-r1 apk
|
||||||
catatonit 0.2.0-r0 apk
|
ca-certificates-bundle 20241121-r1 apk
|
||||||
coreutils 9.4-r2 apk
|
catatonit 0.2.0-r0 apk
|
||||||
coreutils-env 9.4-r2 apk
|
coreutils 9.5-r2 apk
|
||||||
coreutils-fmt 9.4-r2 apk
|
coreutils-env 9.5-r2 apk
|
||||||
coreutils-sha512sum 9.4-r2 apk
|
coreutils-fmt 9.5-r2 apk
|
||||||
curl 8.5.0-r0 apk
|
coreutils-sha512sum 9.5-r2 apk
|
||||||
findutils 4.9.0-r5 apk
|
curl 8.12.1-r1 apk
|
||||||
jq 1.7.1-r0 apk
|
findutils 4.10.0-r0 apk
|
||||||
libacl 2.3.1-r4 apk
|
jq 1.7.1-r0 apk
|
||||||
libattr 2.5.1-r5 apk
|
libattr 2.5.2-r2 apk
|
||||||
libbsd 0.11.7-r3 apk
|
libbsd 0.12.2-r0 apk
|
||||||
libc-utils 0.7.2-r5 apk
|
libcrypto3 3.3.3-r0 apk
|
||||||
libcrypto3 3.1.4-r6 apk
|
libcurl 8.12.1-r1 apk
|
||||||
libcurl 8.5.0-r0 apk
|
libidn2 2.3.7-r0 apk
|
||||||
libidn2 2.3.4-r4 apk
|
libintl 0.22.5-r0 apk
|
||||||
libintl 0.22.3-r0 apk
|
libmd 1.1.0-r0 apk
|
||||||
libmd 1.1.0-r0 apk
|
libncursesw 6.5_p20241006-r3 apk
|
||||||
libncursesw 6.4_p20231125-r0 apk
|
libproc2 4.0.4-r2 apk
|
||||||
libproc2 4.0.4-r0 apk
|
libpsl 0.21.5-r3 apk
|
||||||
libssl3 3.1.4-r6 apk
|
libssl3 3.3.3-r0 apk
|
||||||
libunistring 1.1-r2 apk
|
libunistring 1.2-r0 apk
|
||||||
linux-pam 1.5.3-r7 apk
|
linux-pam 1.6.1-r1 apk
|
||||||
musl 1.2.4_git20230717-r4 apk
|
musl 1.2.5-r9 apk
|
||||||
musl-utils 1.2.4_git20230717-r4 apk
|
musl-utils 1.2.5-r9 apk
|
||||||
ncurses-terminfo-base 6.4_p20231125-r0 apk
|
ncurses-terminfo-base 6.5_p20241006-r3 apk
|
||||||
netcat-openbsd 1.226-r0 apk
|
netcat-openbsd 1.226.1.1-r0 apk
|
||||||
nghttp2-libs 1.58.0-r0 apk
|
nghttp2-libs 1.64.0-r0 apk
|
||||||
oniguruma 6.9.9-r0 apk
|
oniguruma 6.9.9-r0 apk
|
||||||
procps-ng 4.0.4-r0 apk
|
procps-ng 4.0.4-r2 apk
|
||||||
readline 8.2.1-r2 apk
|
readline 8.2.13-r0 apk
|
||||||
scanelf 1.3.7-r2 apk
|
scanelf 1.3.8-r1 apk
|
||||||
shadow 4.14.2-r0 apk
|
shadow 4.16.0-r1 apk
|
||||||
skalibs 2.14.0.1-r0 apk
|
skalibs-libs 2.14.3.0-r0 apk
|
||||||
ssl_client 1.36.1-r15 apk
|
ssl_client 1.37.0-r12 apk
|
||||||
tzdata 2024a-r0 apk
|
tzdata 2025b-r0 apk
|
||||||
utmps-libs 0.1.2.2-r0 apk
|
utmps-libs 0.1.2.3-r2 apk
|
||||||
zlib 1.3.1-r0 apk
|
zlib 1.3.1-r2 apk
|
||||||
|
zstd-libs 1.5.6-r2 apk
|
||||||
|
|
|
||||||
|
|
@ -4,29 +4,22 @@
|
||||||
project_name: baseimage-alpine
|
project_name: baseimage-alpine
|
||||||
full_custom_readme: |
|
full_custom_readme: |
|
||||||
{% raw -%}
|
{% raw -%}
|
||||||
[linuxserverurl]: https://linuxserver.io
|
[](https://linuxserver.io)
|
||||||
[forumurl]: https://forum.linuxserver.io
|
|
||||||
[ircurl]: https://mibbit.com/?server=irc.libera.chat&channel=%23linuxserver.io
|
|
||||||
[appurl]: https://alpinelinux.org
|
|
||||||
|
|
||||||
[][linuxserverurl]
|
|
||||||
|
|
||||||
## Contact information:-
|
## Contact information:-
|
||||||
|
|
||||||
| Type | Address/Details |
|
| Type | Address/Details |
|
||||||
| :---: | --- |
|
| :---: | --- |
|
||||||
| Discord | [Discord](https://discord.gg/YWrKVTn) |
|
| Discord | [Discord](https://linuxserver.io/discord) |
|
||||||
| IRC | libera at `#linuxserver.io` more information at:- [IRC][ircurl]
|
| IRC | `#linuxserver.io` on irc.libera.chat |
|
||||||
| Forum | [LinuxServer.io forum][forumurl] |
|
| Forum | [Discourse](https://discourse.linuxserver.io/) |
|
||||||
|
|
||||||
|
A custom base image built with [Alpine Linux](https://alpinelinux.org) and [s6-overlay](https://github.com/just-containers/s6-overlay).
|
||||||
|
|
||||||
|
|
||||||
[](https://microbadger.com/images/lsiobase/alpine "Get your own image badge on microbadger.com")
|
- Support for using our base images in your own projects is provided on a Reasonable Endeavours basis, please see our [Support Policy](https://www.linuxserver.io/supportpolicy) for details.
|
||||||
|
- There is no `latest` tag for any of our base images, by design. We often make breaking changes between versions, and we don't publish release notes like we do for the downstream images.
|
||||||
[](https://github.com/linuxserver/docker-baseimage-alpine/blob/master/Dockerfile)
|
- If you're intending to distribute an image using one of our bases, please read our [docs on container branding](https://docs.linuxserver.io/general/container-branding/) first.
|
||||||
|
- Alpine releases are supported for 2 years, after which we will stop building new base images for that version.
|
||||||
A custom base image built with [Alpine linux][appurl] and [S6 overlay](https://github.com/just-containers/s6-overlay)..
|
|
||||||
|
|
||||||
The following line is only in this repo for loop testing:
|
The following line is only in this repo for loop testing:
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,12 +1,3 @@
|
||||||
───────────────────────────────────────
|
───────
|
||||||
_____ __ __ _____ _____ _____ _____
|
meatbag
|
||||||
| | | | __|_ _| | |
|
───────
|
||||||
| --| | |__ | | | | | | | | |
|
|
||||||
|_____|_____|_____| |_| |_____|_|_|_|
|
|
||||||
_____ __ __ _ __ ____
|
|
||||||
| __ | | | | | | \
|
|
||||||
| __ -| | | | |__| | |
|
|
||||||
|_____|_____|_|_____|____/
|
|
||||||
|
|
||||||
Based on images from linuxserver.io
|
|
||||||
───────────────────────────────────────
|
|
||||||
|
|
|
||||||
|
|
@ -4,10 +4,21 @@
|
||||||
PUID=${PUID:-911}
|
PUID=${PUID:-911}
|
||||||
PGID=${PGID:-911}
|
PGID=${PGID:-911}
|
||||||
|
|
||||||
groupmod -o -g "$PGID" abc
|
if [[ -z ${LSIO_READ_ONLY_FS} ]] && [[ -z ${LSIO_NON_ROOT_USER} ]]; then
|
||||||
usermod -o -u "$PUID" abc
|
USERHOME=$(grep abc /etc/passwd | cut -d ":" -f6)
|
||||||
|
usermod -d "/root" abc
|
||||||
|
|
||||||
cat /etc/s6-overlay/s6-rc.d/init-adduser/branding
|
groupmod -o -g "${PGID}" abc
|
||||||
|
usermod -o -u "${PUID}" abc
|
||||||
|
|
||||||
|
usermod -d "${USERHOME}" abc
|
||||||
|
fi
|
||||||
|
|
||||||
|
if { [[ -z ${LSIO_READ_ONLY_FS} ]] && [[ -z ${LSIO_NON_ROOT_USER} ]]; } || [[ ! ${LSIO_FIRST_PARTY} = "true" ]]; then
|
||||||
|
cat /etc/s6-overlay/s6-rc.d/init-adduser/branding
|
||||||
|
else
|
||||||
|
cat /run/branding
|
||||||
|
fi
|
||||||
|
|
||||||
if [[ -f /donate.txt ]]; then
|
if [[ -f /donate.txt ]]; then
|
||||||
echo '
|
echo '
|
||||||
|
|
@ -21,12 +32,26 @@ https://www.linuxserver.io/donate/
|
||||||
───────────────────────────────────────
|
───────────────────────────────────────
|
||||||
GID/UID
|
GID/UID
|
||||||
───────────────────────────────────────'
|
───────────────────────────────────────'
|
||||||
|
if [[ -z ${LSIO_NON_ROOT_USER} ]]; then
|
||||||
echo "
|
echo "
|
||||||
User UID: $(id -u abc)
|
User UID: $(id -u abc)
|
||||||
User GID: $(id -g abc)
|
User GID: $(id -g abc)
|
||||||
|
───────────────────────────────────────"
|
||||||
|
else
|
||||||
|
echo "
|
||||||
|
User UID: $(stat /run -c %u)
|
||||||
|
User GID: $(stat /run -c %g)
|
||||||
|
───────────────────────────────────────"
|
||||||
|
fi
|
||||||
|
if [[ -f /build_version ]]; then
|
||||||
|
cat /build_version
|
||||||
|
echo '
|
||||||
───────────────────────────────────────
|
───────────────────────────────────────
|
||||||
"
|
'
|
||||||
|
fi
|
||||||
|
|
||||||
lsiown abc:abc /app
|
if [[ -z ${LSIO_READ_ONLY_FS} ]] && [[ -z ${LSIO_NON_ROOT_USER} ]]; then
|
||||||
lsiown abc:abc /config
|
lsiown abc:abc /app
|
||||||
lsiown abc:abc /defaults
|
lsiown abc:abc /config
|
||||||
|
lsiown abc:abc /defaults
|
||||||
|
fi
|
||||||
|
|
|
||||||
|
|
@ -2,9 +2,11 @@
|
||||||
# shellcheck shell=bash
|
# shellcheck shell=bash
|
||||||
|
|
||||||
for cron_user in abc root; do
|
for cron_user in abc root; do
|
||||||
if [[ -f "/etc/crontabs/${cron_user}" ]]; then
|
if [[ -z ${LSIO_READ_ONLY_FS} ]] && [[ -z ${LSIO_NON_ROOT_USER} ]]; then
|
||||||
lsiown "${cron_user}":"${cron_user}" "/etc/crontabs/${cron_user}"
|
if [[ -f "/etc/crontabs/${cron_user}" ]]; then
|
||||||
crontab -u "${cron_user}" "/etc/crontabs/${cron_user}"
|
lsiown "${cron_user}":"${cron_user}" "/etc/crontabs/${cron_user}"
|
||||||
|
crontab -u "${cron_user}" "/etc/crontabs/${cron_user}"
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ -f "/defaults/crontabs/${cron_user}" ]]; then
|
if [[ -f "/defaults/crontabs/${cron_user}" ]]; then
|
||||||
|
|
|
||||||
|
|
@ -18,7 +18,6 @@ for MIGRATION in $(find ${MIGRATIONS_DIR}/* | sort -n); do
|
||||||
continue
|
continue
|
||||||
fi
|
fi
|
||||||
echo "[migrations] ${NAME}: executing..."
|
echo "[migrations] ${NAME}: executing..."
|
||||||
chmod +x "${MIGRATION}"
|
|
||||||
# Execute migration script in a subshell to prevent it from modifying the current environment
|
# Execute migration script in a subshell to prevent it from modifying the current environment
|
||||||
("${MIGRATION}")
|
("${MIGRATION}")
|
||||||
EXIT_CODE=$?
|
EXIT_CODE=$?
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue