Compare commits

..

70 Commits

Author SHA1 Message Date
LinuxServer-CI
c55fc69b87 Bot Updating Package Versions 2022-07-17 14:32:18 +02:00
LinuxServer-CI
60465428f3 Bot Updating Package Versions 2022-07-10 07:31:19 -05:00
LinuxServer-CI
5851388cf4 Bot Updating Package Versions 2022-07-01 23:48:00 +02:00
LinuxServer-CI
0f0354ded4 Bot Updating Package Versions 2022-06-26 07:30:52 -05:00
LinuxServer-CI
d41e959c3f Bot Updating Package Versions 2022-06-19 14:30:24 +02:00
LinuxServer-CI
393806fd5e Bot Updating Package Versions 2022-06-12 07:28:56 -05:00
LinuxServer-CI
a87b1ef82d Bot Updating Package Versions 2022-05-29 07:32:11 -05:00
LinuxServer-CI
fd84ed821b Bot Updating Package Versions 2022-05-22 14:31:52 +02:00
LinuxServer-CI
a56e57ea9b Bot Updating Package Versions 2022-05-15 07:35:21 -05:00
LinuxServer-CI
302fdc380d Bot Updating Package Versions 2022-05-06 22:50:48 +02:00
LinuxServer-CI
20eda117c2 Bot Updating Templated Files 2022-05-06 15:47:11 -05:00
LinuxServer-CI
ad0b0c640a Bot Updating Package Versions 2022-05-01 14:34:59 +02:00
LinuxServer-CI
9a9f16ab3b Bot Updating Templated Files 2022-05-01 07:31:19 -05:00
LinuxServer-CI
67211293ab Bot Updating Templated Files 2022-05-01 07:30:02 -05:00
LinuxServer-CI
0b620f304c Bot Updating Package Versions 2022-04-15 00:49:00 +02:00
LinuxServer-CI
3c58da4f19 Bot Updating Package Versions 2022-04-03 14:28:49 +02:00
LinuxServer-CI
1cece84c50 Bot Updating Package Versions 2022-03-22 18:48:23 -05:00
LinuxServer-CI
69cf23d516 Bot Updating Package Versions 2022-03-13 07:27:31 -05:00
LinuxServer-CI
21f7dce24d Bot Updating Package Versions 2022-03-02 21:47:07 +01:00
LinuxServer-CI
da74981da3 Bot Updating Package Versions 2022-02-27 13:26:57 +01:00
LinuxServer-CI
e4e82382a0 Bot Updating Package Versions 2022-02-21 04:46:30 +01:00
aptalca
e9822d8efc copy pasta fail 2022-02-20 19:40:20 -08:00
aptalca
b087315336 use official tarballs and patch arm builds 2022-02-20 19:40:20 -08:00
aptalca
29c861029a add libatomic 2022-02-20 19:40:20 -08:00
aptalca
a1fa7f021e install using official debs 2022-02-20 19:40:20 -08:00
LinuxServer-CI
16909c6274 Bot Updating Package Versions 2022-02-20 12:33:41 +00:00
LinuxServer-CI
f381942942 Bot Updating Package Versions 2022-02-06 13:30:23 +01:00
LinuxServer-CI
b419ebcce8 Bot Updating Package Versions 2022-01-23 13:33:34 +01:00
LinuxServer-CI
5724f5ad54 Bot Updating Package Versions 2022-01-16 13:34:14 +01:00
LinuxServer-CI
e522af0d30 Bot Updating Package Versions 2022-01-09 13:35:17 +01:00
aptalca
0a12acb21e
Merge pull request #95 from linuxserver/mod-helper
Add helper for mods
2021-12-29 16:18:57 -05:00
Roxedus
237f55187a
Add helper for mods 2021-12-29 21:01:59 +01:00
LinuxServer-CI
7163312453 Bot Updating Package Versions 2021-12-26 13:32:43 +01:00
LinuxServer-CI
bc847738ca Bot Updating Package Versions 2021-12-19 13:41:51 +01:00
LinuxServer-CI
6e319e7d5d Bot Updating Templated Files 2021-12-19 13:27:35 +01:00
LinuxServer-CI
e9fe1226be Bot Updating Templated Files 2021-12-19 13:26:26 +01:00
LinuxServer-CI
7f87bd95fb Bot Updating Templated Files 2021-12-06 16:21:29 +01:00
aptalca
eca17040a8
Merge pull request #87 from lrstanley/feature/directory-override
add DEFAULT_WORKSPACE support to override default workspace
2021-12-06 10:20:05 -05:00
Liam Stanley
6a7313bb87
Merge branch 'master' into feature/directory-override 2021-12-06 09:46:34 -05:00
LinuxServer-CI
992c04ee9f Bot Updating Package Versions 2021-12-05 13:32:29 +01:00
LinuxServer-CI
63d982abe2 Bot Updating Package Versions 2021-11-29 19:59:18 +01:00
Roxedus
66754831ab
Merge pull request #91 from linuxserver/master-focal
Rebase to focal
2021-11-29 18:44:24 +00:00
aptalca
f6bd33a6c7 typo 2021-11-29 13:01:52 -05:00
aptalca
24e81f2952 rebase to focal 2021-11-29 13:00:15 -05:00
LinuxServer-CI
fb68e8ec88 Bot Updating Package Versions 2021-11-07 13:32:31 +01:00
Liam Stanley
42094309d9 add DEFAULT_WORKSPACE support 2021-11-04 22:51:01 -04:00
LinuxServer-CI
65509e965e Bot Updating Templated Files 2021-10-26 23:48:51 +02:00
Roxedus
3e3ed6e20f
Merge pull request #86 from linuxserver/master-fix 2021-10-26 23:47:27 +02:00
Roxedus
9b7a3aba52
Announce focal 2021-10-26 22:45:47 +02:00
LinuxServer-CI
d418e2444a Bot Updating Package Versions 2021-10-17 14:29:34 +02:00
LinuxServer-CI
ad2469e77d Bot Updating Package Versions 2021-10-03 14:32:30 +02:00
LinuxServer-CI
580ad0130e Bot Updating Templated Files 2021-10-03 14:24:15 +02:00
LinuxServer-CI
aa8b978f9a Bot Updating Templated Files 2021-10-03 14:23:17 +02:00
LinuxServer-CI
7fe76cb84f Bot Updating Package Versions 2021-09-26 14:28:20 +02:00
aptalca
44f7b9fc5f
Merge pull request #73 from gjrtimmer/fix/chown
fix apply chown permissions in parallel for large workspace
2021-09-16 13:43:44 -04:00
aptalca
442dac7b54 update changelog 2021-09-16 13:08:53 -04:00
G.J.R. Timmer
2ef2329327 fix chown 2021-09-16 16:56:35 +02:00
LinuxServer-CI
e95b42b57a Bot Updating Package Versions 2021-09-15 22:51:44 +02:00
LinuxServer-CI
2dee5b2a47 Bot Updating Package Versions 2021-09-05 14:29:07 +02:00
LinuxServer-CI
17e0bbf080 Bot Updating Package Versions 2021-08-29 14:30:51 +02:00
LinuxServer-CI
a9ea1fe773 Bot Updating Templated Files 2021-08-29 14:22:54 +02:00
LinuxServer-CI
323745a36d Bot Updating Package Versions 2021-08-22 14:31:27 +02:00
LinuxServer-CI
17af5070b3 Bot Updating Package Versions 2021-08-15 14:29:27 +02:00
LinuxServer-CI
514f668726 Bot Updating Package Versions 2021-08-11 23:51:47 +02:00
LinuxServer-CI
a5fa8c5058 Bot Updating Package Versions 2021-08-08 14:34:36 +02:00
LinuxServer-CI
3e5681a624 Bot Updating Package Versions 2021-08-01 14:30:01 +02:00
LinuxServer-CI
d721fd11f9 Bot Updating Package Versions 2021-07-25 14:29:17 +02:00
G.J.R. Timmer
d76a6d56cd Fix xargs do not run if empty 2021-07-14 10:08:05 +02:00
G.J.R. Timmer
a1608a1d3c Fix shellcheck warnings 2021-07-14 10:08:05 +02:00
G.J.R. Timmer
b54982550b fix apply chown permissions in parallel for large workspace 2021-07-14 10:08:05 +02:00
16 changed files with 250 additions and 244 deletions

View File

@ -24,7 +24,7 @@
## Readme ## Readme
If you would like to change our readme, please __**do not**__ directly edit the readme, as it is auto-generated on each commit. If you would like to change our readme, please __**do not**__ directly edit the readme, as it is auto-generated on each commit.
Instead edit the [readme-vars.yml](https://github.com/linuxserver/docker-code-server/edit/focal/readme-vars.yml). Instead edit the [readme-vars.yml](https://github.com/linuxserver/docker-code-server/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. These variables are used in a template for our [Jenkins Builder](https://github.com/linuxserver/docker-jenkins-builder) as part of an ansible play.
Most of these variables are also carried over to [docs.linuxserver.io](https://docs.linuxserver.io/images/docker-code-server) Most of these variables are also carried over to [docs.linuxserver.io](https://docs.linuxserver.io/images/docker-code-server)
@ -115,7 +115,7 @@ Once registered you can define the dockerfile to use with `-f Dockerfile.aarch64
## Update the changelog ## Update the changelog
If you are modifying the Dockerfiles or any of the startup scripts in [root](https://github.com/linuxserver/docker-code-server/tree/focal/root), add an entry to the changelog If you are modifying the Dockerfiles or any of the startup scripts in [root](https://github.com/linuxserver/docker-code-server/tree/master/root), add an entry to the changelog
```yml ```yml
changelogs: changelogs:

View File

@ -21,7 +21,7 @@
------------------------------ ------------------------------
- [ ] I have read the [contributing](https://github.com/linuxserver/docker-code-server/blob/focal/.github/CONTRIBUTING.md) guideline and understand that I have made the correct modifications - [ ] I have read the [contributing](https://github.com/linuxserver/docker-code-server/blob/master/.github/CONTRIBUTING.md) guideline and understand that I have made the correct modifications
------------------------------ ------------------------------

View File

@ -4,24 +4,24 @@ on:
workflow_dispatch: workflow_dispatch:
jobs: jobs:
external-trigger-focal: external-trigger-master:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v2.3.3 - uses: actions/checkout@v2.3.3
- name: External Trigger - name: External Trigger
if: github.ref == 'refs/heads/focal' if: github.ref == 'refs/heads/master'
run: | run: |
if [ -n "${{ secrets.PAUSE_EXTERNAL_TRIGGER_CODE_SERVER_FOCAL }}" ]; then if [ -n "${{ secrets.PAUSE_EXTERNAL_TRIGGER_CODE_SERVER_MASTER }}" ]; then
echo "**** Github secret PAUSE_EXTERNAL_TRIGGER_CODE_SERVER_FOCAL is set; skipping trigger. ****" echo "**** Github secret PAUSE_EXTERNAL_TRIGGER_CODE_SERVER_MASTER is set; skipping trigger. ****"
exit 0 exit 0
fi fi
echo "**** External trigger running off of focal branch. To disable this trigger, set a Github secret named \"PAUSE_EXTERNAL_TRIGGER_CODE_SERVER_FOCAL\". ****" echo "**** External trigger running off of master branch. To disable this trigger, set a Github secret named \"PAUSE_EXTERNAL_TRIGGER_CODE_SERVER_MASTER\". ****"
echo "**** Retrieving external version ****" echo "**** Retrieving external version ****"
EXT_RELEASE=$(curl -sX GET https://registry.yarnpkg.com/code-server | jq -r '."dist-tags".latest' | sed 's|^|v|') EXT_RELEASE=$(curl -u ${{ secrets.CR_USER }}:${{ secrets.CR_PAT }} -sX GET https://api.github.com/repos/coder/code-server/releases/latest | jq -r '.tag_name' | sed 's|^v||')
if [ -z "${EXT_RELEASE}" ] || [ "${EXT_RELEASE}" == "null" ]; then if [ -z "${EXT_RELEASE}" ] || [ "${EXT_RELEASE}" == "null" ]; then
echo "**** Can't retrieve external version, exiting ****" echo "**** Can't retrieve external version, exiting ****"
FAILURE_REASON="Can't retrieve external version for code-server branch focal" FAILURE_REASON="Can't retrieve external version for code-server branch master"
GHA_TRIGGER_URL="https://github.com/linuxserver/docker-code-server/actions/runs/${{ github.run_id }}" GHA_TRIGGER_URL="https://github.com/linuxserver/docker-code-server/actions/runs/${{ github.run_id }}"
curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://cdn.discordapp.com/avatars/354986384542662657/df91181b3f1cf0ef1592fbe18e0962d7.png","embeds": [{"color": 16711680, curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://cdn.discordapp.com/avatars/354986384542662657/df91181b3f1cf0ef1592fbe18e0962d7.png","embeds": [{"color": 16711680,
"description": "**Trigger Failed** \n**Reason:** '"${FAILURE_REASON}"' \n**Trigger URL:** '"${GHA_TRIGGER_URL}"' \n"}], "description": "**Trigger Failed** \n**Reason:** '"${FAILURE_REASON}"' \n**Trigger URL:** '"${GHA_TRIGGER_URL}"' \n"}],
@ -32,7 +32,7 @@ jobs:
echo "**** External version: ${EXT_RELEASE} ****" echo "**** External version: ${EXT_RELEASE} ****"
echo "**** Retrieving last pushed version ****" echo "**** Retrieving last pushed version ****"
image="linuxserver/code-server" image="linuxserver/code-server"
tag="focal" tag="latest"
token=$(curl -sX GET \ token=$(curl -sX GET \
"https://ghcr.io/token?scope=repository%3Alinuxserver%2Fcode-server%3Apull" \ "https://ghcr.io/token?scope=repository%3Alinuxserver%2Fcode-server%3Apull" \
| jq -r '.token') | jq -r '.token')
@ -54,7 +54,7 @@ jobs:
IMAGE_VERSION=$(echo ${IMAGE_RELEASE} | awk -F'-ls' '{print $1}') IMAGE_VERSION=$(echo ${IMAGE_RELEASE} | awk -F'-ls' '{print $1}')
if [ -z "${IMAGE_VERSION}" ]; then if [ -z "${IMAGE_VERSION}" ]; then
echo "**** Can't retrieve last pushed version, exiting ****" echo "**** Can't retrieve last pushed version, exiting ****"
FAILURE_REASON="Can't retrieve last pushed version for code-server tag focal" FAILURE_REASON="Can't retrieve last pushed version for code-server tag latest"
curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://cdn.discordapp.com/avatars/354986384542662657/df91181b3f1cf0ef1592fbe18e0962d7.png","embeds": [{"color": 16711680, curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://cdn.discordapp.com/avatars/354986384542662657/df91181b3f1cf0ef1592fbe18e0962d7.png","embeds": [{"color": 16711680,
"description": "**Trigger Failed** \n**Reason:** '"${FAILURE_REASON}"' \n"}], "description": "**Trigger Failed** \n**Reason:** '"${FAILURE_REASON}"' \n"}],
"username": "Github Actions"}' ${{ secrets.DISCORD_WEBHOOK }} "username": "Github Actions"}' ${{ secrets.DISCORD_WEBHOOK }}
@ -64,13 +64,13 @@ jobs:
if [ "${EXT_RELEASE}" == "${IMAGE_VERSION}" ]; then if [ "${EXT_RELEASE}" == "${IMAGE_VERSION}" ]; then
echo "**** Version ${EXT_RELEASE} already pushed, exiting ****" echo "**** Version ${EXT_RELEASE} already pushed, exiting ****"
exit 0 exit 0
elif [ $(curl -s https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-code-server/job/focal/lastBuild/api/json | jq -r '.building') == "true" ]; then elif [ $(curl -s https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-code-server/job/master/lastBuild/api/json | jq -r '.building') == "true" ]; then
echo "**** New version ${EXT_RELEASE} found; but there already seems to be an active build on Jenkins; exiting ****" echo "**** New version ${EXT_RELEASE} found; but there already seems to be an active build on Jenkins; exiting ****"
exit 0 exit 0
else else
echo "**** New version ${EXT_RELEASE} found; old version was ${IMAGE_VERSION}. Triggering new build ****" echo "**** New version ${EXT_RELEASE} found; old version was ${IMAGE_VERSION}. Triggering new build ****"
response=$(curl -iX POST \ response=$(curl -iX POST \
https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-code-server/job/focal/buildWithParameters?PACKAGE_CHECK=false \ https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-code-server/job/master/buildWithParameters?PACKAGE_CHECK=false \
--user ${{ secrets.JENKINS_USER }}:${{ secrets.JENKINS_TOKEN }} | grep -i location | sed "s|^[L|l]ocation: \(.*\)|\1|") --user ${{ secrets.JENKINS_USER }}:${{ secrets.JENKINS_TOKEN }} | grep -i location | sed "s|^[L|l]ocation: \(.*\)|\1|")
echo "**** Jenkins job queue url: ${response%$'\r'} ****" echo "**** Jenkins job queue url: ${response%$'\r'} ****"
echo "**** Sleeping 10 seconds until job starts ****" echo "**** Sleeping 10 seconds until job starts ****"
@ -85,7 +85,7 @@ jobs:
--data-urlencode "description=GHA external trigger https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" \ --data-urlencode "description=GHA external trigger https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" \
--data-urlencode "Submit=Submit" --data-urlencode "Submit=Submit"
echo "**** Notifying Discord ****" echo "**** Notifying Discord ****"
TRIGGER_REASON="A version change was detected for code-server tag focal. Old version:${IMAGE_VERSION} New version:${EXT_RELEASE}" TRIGGER_REASON="A version change was detected for code-server tag latest. Old version:${IMAGE_VERSION} New version:${EXT_RELEASE}"
curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://cdn.discordapp.com/avatars/354986384542662657/df91181b3f1cf0ef1592fbe18e0962d7.png","embeds": [{"color": 9802903, curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://cdn.discordapp.com/avatars/354986384542662657/df91181b3f1cf0ef1592fbe18e0962d7.png","embeds": [{"color": 9802903,
"description": "**Build Triggered** \n**Reason:** '"${TRIGGER_REASON}"' \n**Build URL:** '"${buildurl}display/redirect"' \n"}], "description": "**Build Triggered** \n**Reason:** '"${TRIGGER_REASON}"' \n**Build URL:** '"${buildurl}display/redirect"' \n"}],
"username": "Github Actions"}' ${{ secrets.DISCORD_WEBHOOK }} "username": "Github Actions"}' ${{ secrets.DISCORD_WEBHOOK }}

View File

@ -8,6 +8,6 @@ jobs:
steps: steps:
- uses: actions/first-interaction@v1 - uses: actions/first-interaction@v1
with: with:
issue-message: 'Thanks for opening your first issue here! Be sure to follow the [bug](https://github.com/linuxserver/docker-code-server/blob/focal/.github/ISSUE_TEMPLATE/issue.bug.md) or [feature](https://github.com/linuxserver/docker-code-server/blob/focal/.github/ISSUE_TEMPLATE/issue.feature.md) issue templates!' issue-message: 'Thanks for opening your first issue here! Be sure to follow the [bug](https://github.com/linuxserver/docker-code-server/blob/master/.github/ISSUE_TEMPLATE/issue.bug.md) or [feature](https://github.com/linuxserver/docker-code-server/blob/master/.github/ISSUE_TEMPLATE/issue.feature.md) issue templates!'
pr-message: 'Thanks for opening this pull request! Be sure to follow the [pull request template](https://github.com/linuxserver/docker-code-server/blob/focal/.github/PULL_REQUEST_TEMPLATE.md)!' pr-message: 'Thanks for opening this pull request! Be sure to follow the [pull request template](https://github.com/linuxserver/docker-code-server/blob/master/.github/PULL_REQUEST_TEMPLATE.md)!'
repo-token: ${{ secrets.GITHUB_TOKEN }} repo-token: ${{ secrets.GITHUB_TOKEN }}

View File

@ -4,25 +4,25 @@ on:
workflow_dispatch: workflow_dispatch:
jobs: jobs:
package-trigger-focal: package-trigger-master:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v2.3.3 - uses: actions/checkout@v2.3.3
- name: Package Trigger - name: Package Trigger
if: github.ref == 'refs/heads/focal' if: github.ref == 'refs/heads/master'
run: | run: |
if [ -n "${{ secrets.PAUSE_PACKAGE_TRIGGER_CODE_SERVER_FOCAL }}" ]; then if [ -n "${{ secrets.PAUSE_PACKAGE_TRIGGER_CODE_SERVER_MASTER }}" ]; then
echo "**** Github secret PAUSE_PACKAGE_TRIGGER_CODE_SERVER_FOCAL is set; skipping trigger. ****" echo "**** Github secret PAUSE_PACKAGE_TRIGGER_CODE_SERVER_MASTER is set; skipping trigger. ****"
exit 0 exit 0
fi fi
if [ $(curl -s https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-code-server/job/focal/lastBuild/api/json | jq -r '.building') == "true" ]; then if [ $(curl -s https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-code-server/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 ****"
exit 0 exit 0
fi fi
echo "**** Package trigger running off of focal branch. To disable, set a Github secret named \"PAUSE_PACKAGE_TRIGGER_CODE_SERVER_FOCAL\". ****" echo "**** Package trigger running off of master branch. To disable, set a Github secret named \"PAUSE_PACKAGE_TRIGGER_CODE_SERVER_MASTER\". ****"
response=$(curl -iX POST \ response=$(curl -iX POST \
https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-code-server/job/focal/buildWithParameters?PACKAGE_CHECK=true \ https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-code-server/job/master/buildWithParameters?PACKAGE_CHECK=true \
--user ${{ secrets.JENKINS_USER }}:${{ secrets.JENKINS_TOKEN }} | grep -i location | sed "s|^[L|l]ocation: \(.*\)|\1|") --user ${{ secrets.JENKINS_USER }}:${{ secrets.JENKINS_TOKEN }} | grep -i location | sed "s|^[L|l]ocation: \(.*\)|\1|")
echo "**** Jenkins job queue url: ${response%$'\r'} ****" echo "**** Jenkins job queue url: ${response%$'\r'} ****"
echo "**** Sleeping 10 seconds until job starts ****" echo "**** Sleeping 10 seconds until job starts ****"

View File

@ -12,56 +12,49 @@ ENV HOME="/config"
RUN \ RUN \
echo "**** install node repo ****" && \ echo "**** install node repo ****" && \
apt-get update && \
apt-get install -y \
gnupg && \
curl -s https://deb.nodesource.com/gpgkey/nodesource.gpg.key | apt-key add - && \ curl -s https://deb.nodesource.com/gpgkey/nodesource.gpg.key | apt-key add - && \
echo 'deb https://deb.nodesource.com/node_14.x focal main' \ echo 'deb https://deb.nodesource.com/node_14.x focal main' \
> /etc/apt/sources.list.d/nodesource.list && \ > /etc/apt/sources.list.d/nodesource.list && \
curl -s https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - && \
echo 'deb https://dl.yarnpkg.com/debian/ stable main' \
> /etc/apt/sources.list.d/yarn.list && \
echo "**** install build dependencies ****" && \ echo "**** install build dependencies ****" && \
apt-get update && \ apt-get update && \
apt-get install -y \ apt-get install -y \
build-essential \ build-essential \
libsecret-1-dev \ nodejs && \
libx11-dev \
libxkbfile-dev \
pkg-config \
python3 && \
echo "**** install runtime dependencies ****" && \ echo "**** install runtime dependencies ****" && \
apt-get install -y \ apt-get install -y \
git \ git \
jq \ jq \
libatomic1 \
nano \ nano \
net-tools \ net-tools \
nodejs \ sudo && \
sudo \
yarn && \
echo "**** install code-server ****" && \ echo "**** install code-server ****" && \
if [ -z ${CODE_RELEASE+x} ]; then \ if [ -z ${CODE_RELEASE+x} ]; then \
CODE_RELEASE=$(curl -sX GET https://registry.yarnpkg.com/code-server \ CODE_RELEASE=$(curl -sX GET https://api.github.com/repos/coder/code-server/releases/latest \
| jq -r '."dist-tags".latest' | sed 's|^|v|'); \ | awk '/tag_name/{print $4;exit}' FS='[""]' | sed 's|^v||'); \
fi && \
mkdir -p /app/code-server && \
curl -o \
/tmp/code-server.tar.gz -L \
"https://github.com/coder/code-server/releases/download/v${CODE_RELEASE}/code-server-${CODE_RELEASE}-linux-amd64.tar.gz" && \
tar xf /tmp/code-server.tar.gz -C \
/app/code-server --strip-components=1 && \
echo "**** patch 4.0.2 ****" && \
if [ "${CODE_RELEASE}" = "4.0.2" ] && [ "$(uname -m)" != "x86_64" ]; then \
cd /app/code-server && \
npm i --production @node-rs/argon2; \
fi && \ fi && \
CODE_VERSION=$(echo "$CODE_RELEASE" | awk '{print substr($1,2); }') && \
npm config set python python3 \
yarn config set network-timeout 600000 -g && \
yarn --production --verbose --frozen-lockfile global add code-server@"$CODE_VERSION" && \
yarn cache clean && \
echo "**** clean up ****" && \ echo "**** clean up ****" && \
apt-get purge --auto-remove -y \ apt-get purge --auto-remove -y \
build-essential \ build-essential \
libx11-dev \ nodejs && \
libxkbfile-dev \
libsecret-1-dev \
pkg-config && \
apt-get clean && \ apt-get clean && \
rm -rf \ rm -rf \
/config/* \ /config/* \
/tmp/* \ /tmp/* \
/var/lib/apt/lists/* \ /var/lib/apt/lists/* \
/var/tmp/* /var/tmp/* \
/etc/apt/sources.list.d/nodesource.list
# add local files # add local files
COPY /root / COPY /root /

View File

@ -12,56 +12,49 @@ ENV HOME="/config"
RUN \ RUN \
echo "**** install node repo ****" && \ echo "**** install node repo ****" && \
apt-get update && \
apt-get install -y \
gnupg && \
curl -s https://deb.nodesource.com/gpgkey/nodesource.gpg.key | apt-key add - && \ curl -s https://deb.nodesource.com/gpgkey/nodesource.gpg.key | apt-key add - && \
echo 'deb https://deb.nodesource.com/node_14.x focal main' \ echo 'deb https://deb.nodesource.com/node_14.x focal main' \
> /etc/apt/sources.list.d/nodesource.list && \ > /etc/apt/sources.list.d/nodesource.list && \
curl -s https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - && \
echo 'deb https://dl.yarnpkg.com/debian/ stable main' \
> /etc/apt/sources.list.d/yarn.list && \
echo "**** install build dependencies ****" && \ echo "**** install build dependencies ****" && \
apt-get update && \ apt-get update && \
apt-get install -y \ apt-get install -y \
build-essential \ build-essential \
libsecret-1-dev \ nodejs && \
libx11-dev \
libxkbfile-dev \
pkg-config \
python3 && \
echo "**** install runtime dependencies ****" && \ echo "**** install runtime dependencies ****" && \
apt-get install -y \ apt-get install -y \
git \ git \
jq \ jq \
libatomic1 \
nano \ nano \
net-tools \ net-tools \
nodejs \ sudo && \
sudo \
yarn && \
echo "**** install code-server ****" && \ echo "**** install code-server ****" && \
if [ -z ${CODE_RELEASE+x} ]; then \ if [ -z ${CODE_RELEASE+x} ]; then \
CODE_RELEASE=$(curl -sX GET https://registry.yarnpkg.com/code-server \ CODE_RELEASE=$(curl -sX GET https://api.github.com/repos/coder/code-server/releases/latest \
| jq -r '."dist-tags".latest' | sed 's|^|v|'); \ | awk '/tag_name/{print $4;exit}' FS='[""]' | sed 's|^v||'); \
fi && \
mkdir -p /app/code-server && \
curl -o \
/tmp/code-server.tar.gz -L \
"https://github.com/coder/code-server/releases/download/v${CODE_RELEASE}/code-server-${CODE_RELEASE}-linux-arm64.tar.gz" && \
tar xf /tmp/code-server.tar.gz -C \
/app/code-server --strip-components=1 && \
echo "**** patch 4.0.2 ****" && \
if [ "${CODE_RELEASE}" = "4.0.2" ] && [ "$(uname -m)" != "x86_64" ]; then \
cd /app/code-server && \
npm i --production @node-rs/argon2; \
fi && \ fi && \
CODE_VERSION=$(echo "$CODE_RELEASE" | awk '{print substr($1,2); }') && \
npm config set python python3 \
yarn config set network-timeout 600000 -g && \
yarn --production --verbose --frozen-lockfile global add code-server@"$CODE_VERSION" && \
yarn cache clean && \
echo "**** clean up ****" && \ echo "**** clean up ****" && \
apt-get purge --auto-remove -y \ apt-get purge --auto-remove -y \
build-essential \ build-essential \
libx11-dev \ nodejs && \
libxkbfile-dev \
libsecret-1-dev \
pkg-config && \
apt-get clean && \ apt-get clean && \
rm -rf \ rm -rf \
/config/* \ /config/* \
/tmp/* \ /tmp/* \
/var/lib/apt/lists/* \ /var/lib/apt/lists/* \
/var/tmp/* /var/tmp/* \
/etc/apt/sources.list.d/nodesource.list
# add local files # add local files
COPY /root / COPY /root /

View File

@ -12,56 +12,49 @@ ENV HOME="/config"
RUN \ RUN \
echo "**** install node repo ****" && \ echo "**** install node repo ****" && \
apt-get update && \
apt-get install -y \
gnupg && \
curl -s https://deb.nodesource.com/gpgkey/nodesource.gpg.key | apt-key add - && \ curl -s https://deb.nodesource.com/gpgkey/nodesource.gpg.key | apt-key add - && \
echo 'deb https://deb.nodesource.com/node_14.x focal main' \ echo 'deb https://deb.nodesource.com/node_14.x focal main' \
> /etc/apt/sources.list.d/nodesource.list && \ > /etc/apt/sources.list.d/nodesource.list && \
curl -s https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - && \
echo 'deb https://dl.yarnpkg.com/debian/ stable main' \
> /etc/apt/sources.list.d/yarn.list && \
echo "**** install build dependencies ****" && \ echo "**** install build dependencies ****" && \
apt-get update && \ apt-get update && \
apt-get install -y \ apt-get install -y \
build-essential \ build-essential \
libsecret-1-dev \ nodejs && \
libx11-dev \
libxkbfile-dev \
pkg-config \
python3 && \
echo "**** install runtime dependencies ****" && \ echo "**** install runtime dependencies ****" && \
apt-get install -y \ apt-get install -y \
git \ git \
jq \ jq \
libatomic1 \
nano \ nano \
net-tools \ net-tools \
nodejs \ sudo && \
sudo \
yarn && \
echo "**** install code-server ****" && \ echo "**** install code-server ****" && \
if [ -z ${CODE_RELEASE+x} ]; then \ if [ -z ${CODE_RELEASE+x} ]; then \
CODE_RELEASE=$(curl -sX GET https://registry.yarnpkg.com/code-server \ CODE_RELEASE=$(curl -sX GET https://api.github.com/repos/coder/code-server/releases/latest \
| jq -r '."dist-tags".latest' | sed 's|^|v|'); \ | awk '/tag_name/{print $4;exit}' FS='[""]' | sed 's|^v||'); \
fi && \
mkdir -p /app/code-server && \
curl -o \
/tmp/code-server.tar.gz -L \
"https://github.com/coder/code-server/releases/download/v${CODE_RELEASE}/code-server-${CODE_RELEASE}-linux-armv7l.tar.gz" && \
tar xf /tmp/code-server.tar.gz -C \
/app/code-server --strip-components=1 && \
echo "**** patch 4.0.2 ****" && \
if [ "${CODE_RELEASE}" = "4.0.2" ] && [ "$(uname -m)" != "x86_64" ]; then \
cd /app/code-server && \
npm i --production @node-rs/argon2; \
fi && \ fi && \
CODE_VERSION=$(echo "$CODE_RELEASE" | awk '{print substr($1,2); }') && \
npm config set python python3 \
yarn config set network-timeout 600000 -g && \
yarn --production --verbose --frozen-lockfile global add code-server@"$CODE_VERSION" && \
yarn cache clean && \
echo "**** clean up ****" && \ echo "**** clean up ****" && \
apt-get purge --auto-remove -y \ apt-get purge --auto-remove -y \
build-essential \ build-essential \
libx11-dev \ nodejs && \
libxkbfile-dev \
libsecret-1-dev \
pkg-config && \
apt-get clean && \ apt-get clean && \
rm -rf \ rm -rf \
/config/* \ /config/* \
/tmp/* \ /tmp/* \
/var/lib/apt/lists/* \ /var/lib/apt/lists/* \
/var/tmp/* /var/tmp/* \
/etc/apt/sources.list.d/nodesource.list
# add local files # add local files
COPY /root / COPY /root /

104
Jenkinsfile vendored
View File

@ -42,7 +42,7 @@ pipeline {
script{ script{
env.EXIT_STATUS = '' env.EXIT_STATUS = ''
env.LS_RELEASE = sh( env.LS_RELEASE = sh(
script: '''docker run --rm ghcr.io/linuxserver/alexeiled-skopeo sh -c 'skopeo inspect docker://docker.io/'${DOCKERHUB_IMAGE}':focal 2>/dev/null' | jq -r '.Labels.build_version' | awk '{print $3}' | grep '\\-ls' || : ''', script: '''docker run --rm ghcr.io/linuxserver/alexeiled-skopeo sh -c 'skopeo inspect docker://docker.io/'${DOCKERHUB_IMAGE}':latest 2>/dev/null' | jq -r '.Labels.build_version' | awk '{print $3}' | grep '\\-ls' || : ''',
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' ''',
@ -104,7 +104,7 @@ pipeline {
steps{ steps{
script{ script{
env.EXT_RELEASE = sh( env.EXT_RELEASE = sh(
script: ''' curl -sX GET https://registry.yarnpkg.com/code-server | jq -r '."dist-tags".latest' | sed 's|^|v|' ''', script: ''' curl -sX GET https://api.github.com/repos/coder/code-server/releases/latest | jq -r '.tag_name' | sed 's|^v||' ''',
returnStdout: true).trim() returnStdout: true).trim()
env.RELEASE_LINK = 'custom_command' env.RELEASE_LINK = 'custom_command'
} }
@ -144,10 +144,10 @@ pipeline {
} }
} }
} }
// If this is a focal build use live docker endpoints // If this is a master build use live docker endpoints
stage("Set ENV live build"){ stage("Set ENV live build"){
when { when {
branch "focal" branch "master"
environment name: 'CHANGE_ID', value: '' environment name: 'CHANGE_ID', value: ''
} }
steps { steps {
@ -157,20 +157,20 @@ pipeline {
env.GITLABIMAGE = 'registry.gitlab.com/linuxserver.io/' + env.LS_REPO + '/' + env.CONTAINER_NAME env.GITLABIMAGE = 'registry.gitlab.com/linuxserver.io/' + env.LS_REPO + '/' + env.CONTAINER_NAME
env.QUAYIMAGE = 'quay.io/linuxserver.io/' + env.CONTAINER_NAME env.QUAYIMAGE = 'quay.io/linuxserver.io/' + env.CONTAINER_NAME
if (env.MULTIARCH == 'true') { if (env.MULTIARCH == 'true') {
env.CI_TAGS = 'amd64-focal-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER + '|arm32v7-focal-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER + '|arm64v8-focal-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER env.CI_TAGS = 'amd64-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER + '|arm32v7-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER + '|arm64v8-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER
} else { } else {
env.CI_TAGS = 'focal-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER env.CI_TAGS = 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 = 'focal-' + env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER env.META_TAG = env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER
env.EXT_RELEASE_TAG = 'focal-version-' + env.EXT_RELEASE_CLEAN env.EXT_RELEASE_TAG = 'version-' + env.EXT_RELEASE_CLEAN
} }
} }
} }
// If this is a dev build use dev docker endpoints // If this is a dev build use dev docker endpoints
stage("Set ENV dev build"){ stage("Set ENV dev build"){
when { when {
not {branch "focal"} not {branch "master"}
environment name: 'CHANGE_ID', value: '' environment name: 'CHANGE_ID', value: ''
} }
steps { steps {
@ -180,13 +180,13 @@ pipeline {
env.GITLABIMAGE = 'registry.gitlab.com/linuxserver.io/' + env.LS_REPO + '/lsiodev-' + env.CONTAINER_NAME env.GITLABIMAGE = 'registry.gitlab.com/linuxserver.io/' + env.LS_REPO + '/lsiodev-' + env.CONTAINER_NAME
env.QUAYIMAGE = 'quay.io/linuxserver.io/lsiodev-' + env.CONTAINER_NAME env.QUAYIMAGE = 'quay.io/linuxserver.io/lsiodev-' + env.CONTAINER_NAME
if (env.MULTIARCH == 'true') { if (env.MULTIARCH == 'true') {
env.CI_TAGS = 'amd64-focal-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA + '|arm32v7-focal-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA + '|arm64v8-focal-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA env.CI_TAGS = 'amd64-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA + '|arm32v7-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA + '|arm64v8-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA
} else { } else {
env.CI_TAGS = 'focal-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA env.CI_TAGS = 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 = 'focal-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA env.META_TAG = env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-dev-' + env.COMMIT_SHA
env.EXT_RELEASE_TAG = 'focal-version-' + env.EXT_RELEASE_CLEAN env.EXT_RELEASE_TAG = 'version-' + env.EXT_RELEASE_CLEAN
env.DOCKERHUB_LINK = 'https://hub.docker.com/r/' + env.DEV_DOCKERHUB_IMAGE + '/tags/' env.DOCKERHUB_LINK = 'https://hub.docker.com/r/' + env.DEV_DOCKERHUB_IMAGE + '/tags/'
} }
} }
@ -203,13 +203,13 @@ pipeline {
env.GITLABIMAGE = 'registry.gitlab.com/linuxserver.io/' + env.LS_REPO + '/lspipepr-' + env.CONTAINER_NAME env.GITLABIMAGE = 'registry.gitlab.com/linuxserver.io/' + env.LS_REPO + '/lspipepr-' + env.CONTAINER_NAME
env.QUAYIMAGE = 'quay.io/linuxserver.io/lspipepr-' + env.CONTAINER_NAME env.QUAYIMAGE = 'quay.io/linuxserver.io/lspipepr-' + env.CONTAINER_NAME
if (env.MULTIARCH == 'true') { if (env.MULTIARCH == 'true') {
env.CI_TAGS = 'amd64-focal-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-pr-' + env.PULL_REQUEST + '|arm32v7-focal-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-pr-' + env.PULL_REQUEST + '|arm64v8-focal-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-pr-' + env.PULL_REQUEST env.CI_TAGS = 'amd64-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-pr-' + env.PULL_REQUEST + '|arm32v7-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-pr-' + env.PULL_REQUEST + '|arm64v8-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-pr-' + env.PULL_REQUEST
} else { } else {
env.CI_TAGS = 'focal-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-pr-' + env.PULL_REQUEST env.CI_TAGS = env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-pr-' + env.PULL_REQUEST
} }
env.VERSION_TAG = env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-pr-' + env.PULL_REQUEST env.VERSION_TAG = env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-pr-' + env.PULL_REQUEST
env.META_TAG = 'focal-' + env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-pr-' + env.PULL_REQUEST env.META_TAG = env.EXT_RELEASE_CLEAN + '-pkg-' + env.PACKAGE_TAG + '-pr-' + env.PULL_REQUEST
env.EXT_RELEASE_TAG = 'focal-version-' + env.EXT_RELEASE_CLEAN env.EXT_RELEASE_TAG = '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/'
} }
@ -247,7 +247,7 @@ pipeline {
// Use helper containers to render templated files // Use helper containers to render templated files
stage('Update-Templates') { stage('Update-Templates') {
when { when {
branch "focal" branch "master"
environment name: 'CHANGE_ID', value: '' environment name: 'CHANGE_ID', value: ''
expression { expression {
env.CONTAINER_NAME != null env.CONTAINER_NAME != null
@ -258,13 +258,13 @@ pipeline {
set -e set -e
TEMPDIR=$(mktemp -d) TEMPDIR=$(mktemp -d)
docker pull ghcr.io/linuxserver/jenkins-builder:latest docker pull ghcr.io/linuxserver/jenkins-builder:latest
docker run --rm -e CONTAINER_NAME=${CONTAINER_NAME} -e GITHUB_BRANCH=focal -v ${TEMPDIR}:/ansible/jenkins ghcr.io/linuxserver/jenkins-builder:latest docker run --rm -e CONTAINER_NAME=${CONTAINER_NAME} -e GITHUB_BRANCH=master -v ${TEMPDIR}:/ansible/jenkins ghcr.io/linuxserver/jenkins-builder:latest
# Stage 1 - Jenkinsfile update # Stage 1 - Jenkinsfile update
if [[ "$(md5sum Jenkinsfile | awk '{ print $1 }')" != "$(md5sum ${TEMPDIR}/docker-${CONTAINER_NAME}/Jenkinsfile | awk '{ print $1 }')" ]]; then if [[ "$(md5sum Jenkinsfile | awk '{ print $1 }')" != "$(md5sum ${TEMPDIR}/docker-${CONTAINER_NAME}/Jenkinsfile | awk '{ print $1 }')" ]]; then
mkdir -p ${TEMPDIR}/repo mkdir -p ${TEMPDIR}/repo
git clone https://github.com/${LS_USER}/${LS_REPO}.git ${TEMPDIR}/repo/${LS_REPO} git clone https://github.com/${LS_USER}/${LS_REPO}.git ${TEMPDIR}/repo/${LS_REPO}
cd ${TEMPDIR}/repo/${LS_REPO} cd ${TEMPDIR}/repo/${LS_REPO}
git checkout -f focal git checkout -f master
cp ${TEMPDIR}/docker-${CONTAINER_NAME}/Jenkinsfile ${TEMPDIR}/repo/${LS_REPO}/ cp ${TEMPDIR}/docker-${CONTAINER_NAME}/Jenkinsfile ${TEMPDIR}/repo/${LS_REPO}/
git add Jenkinsfile git add Jenkinsfile
git commit -m 'Bot Updating Templated Files' git commit -m 'Bot Updating Templated Files'
@ -287,7 +287,7 @@ pipeline {
mkdir -p ${TEMPDIR}/repo mkdir -p ${TEMPDIR}/repo
git clone https://github.com/${LS_USER}/${LS_REPO}.git ${TEMPDIR}/repo/${LS_REPO} git clone https://github.com/${LS_USER}/${LS_REPO}.git ${TEMPDIR}/repo/${LS_REPO}
cd ${TEMPDIR}/repo/${LS_REPO} cd ${TEMPDIR}/repo/${LS_REPO}
git checkout -f focal git checkout -f master
for i in ${TEMPLATES_TO_DELETE}; do for i in ${TEMPLATES_TO_DELETE}; do
git rm "${i}" git rm "${i}"
done done
@ -308,7 +308,7 @@ pipeline {
mkdir -p ${TEMPDIR}/repo mkdir -p ${TEMPDIR}/repo
git clone https://github.com/${LS_USER}/${LS_REPO}.git ${TEMPDIR}/repo/${LS_REPO} git clone https://github.com/${LS_USER}/${LS_REPO}.git ${TEMPDIR}/repo/${LS_REPO}
cd ${TEMPDIR}/repo/${LS_REPO} cd ${TEMPDIR}/repo/${LS_REPO}
git checkout -f focal git checkout -f master
cd ${TEMPDIR}/docker-${CONTAINER_NAME} cd ${TEMPDIR}/docker-${CONTAINER_NAME}
mkdir -p ${TEMPDIR}/repo/${LS_REPO}/.github/workflows mkdir -p ${TEMPDIR}/repo/${LS_REPO}/.github/workflows
mkdir -p ${TEMPDIR}/repo/${LS_REPO}/.github/ISSUE_TEMPLATE mkdir -p ${TEMPDIR}/repo/${LS_REPO}/.github/ISSUE_TEMPLATE
@ -343,9 +343,11 @@ pipeline {
if [[ ("${BRANCH_NAME}" == "master") || ("${BRANCH_NAME}" == "main") ]] && [[ (! -f ${TEMPDIR}/unraid/templates/unraid/${CONTAINER_NAME}.xml) || ("$(md5sum ${TEMPDIR}/unraid/templates/unraid/${CONTAINER_NAME}.xml | awk '{ print $1 }')" != "$(md5sum ${TEMPDIR}/docker-${CONTAINER_NAME}/.jenkins-external/${CONTAINER_NAME}.xml | awk '{ print $1 }')") ]]; then if [[ ("${BRANCH_NAME}" == "master") || ("${BRANCH_NAME}" == "main") ]] && [[ (! -f ${TEMPDIR}/unraid/templates/unraid/${CONTAINER_NAME}.xml) || ("$(md5sum ${TEMPDIR}/unraid/templates/unraid/${CONTAINER_NAME}.xml | awk '{ print $1 }')" != "$(md5sum ${TEMPDIR}/docker-${CONTAINER_NAME}/.jenkins-external/${CONTAINER_NAME}.xml | awk '{ print $1 }')") ]]; then
cd ${TEMPDIR}/unraid/templates/ cd ${TEMPDIR}/unraid/templates/
if grep -wq "${CONTAINER_NAME}" ${TEMPDIR}/unraid/templates/unraid/ignore.list; then if grep -wq "${CONTAINER_NAME}" ${TEMPDIR}/unraid/templates/unraid/ignore.list; then
echo "Image is on the ignore list, removing Unraid template" echo "Image is on the ignore list, marking Unraid template as deprecated"
git rm unraid/${CONTAINER_NAME}.xml || : cp ${TEMPDIR}/docker-${CONTAINER_NAME}/.jenkins-external/${CONTAINER_NAME}.xml ${TEMPDIR}/unraid/templates/unraid/
git commit -m 'Bot Removing Deprecated Unraid Template' || : git add -u unraid/${CONTAINER_NAME}.xml
git mv unraid/${CONTAINER_NAME}.xml unraid/deprecated/${CONTAINER_NAME}.xml || :
git commit -m 'Bot Moving Deprecated Unraid Template' || :
else else
cp ${TEMPDIR}/docker-${CONTAINER_NAME}/.jenkins-external/${CONTAINER_NAME}.xml ${TEMPDIR}/unraid/templates/unraid/ cp ${TEMPDIR}/docker-${CONTAINER_NAME}/.jenkins-external/${CONTAINER_NAME}.xml ${TEMPDIR}/unraid/templates/unraid/
git add unraid/${CONTAINER_NAME}.xml git add unraid/${CONTAINER_NAME}.xml
@ -364,7 +366,7 @@ pipeline {
// Exit the build if the Templated files were just updated // Exit the build if the Templated files were just updated
stage('Template-exit') { stage('Template-exit') {
when { when {
branch "focal" branch "master"
environment name: 'CHANGE_ID', value: '' environment name: 'CHANGE_ID', value: ''
environment name: 'FILES_UPDATED', value: 'true' environment name: 'FILES_UPDATED', value: 'true'
expression { expression {
@ -403,7 +405,7 @@ pipeline {
// Add package to Scarf.sh and set permissions // Add package to Scarf.sh and set permissions
stage("Scarf.sh package registry"){ stage("Scarf.sh package registry"){
when { when {
branch "focal" branch "master"
environment name: 'EXIT_STATUS', value: '' environment name: 'EXIT_STATUS', value: ''
} }
steps{ steps{
@ -560,7 +562,7 @@ pipeline {
// Take the image we just built and dump package versions for comparison // Take the image we just built and dump package versions for comparison
stage('Update-packages') { stage('Update-packages') {
when { when {
branch "focal" branch "master"
environment name: 'CHANGE_ID', value: '' environment name: 'CHANGE_ID', value: ''
environment name: 'EXIT_STATUS', value: '' environment name: 'EXIT_STATUS', value: ''
} }
@ -597,7 +599,7 @@ pipeline {
echo "Package tag sha from current packages in buit container is ${NEW_PACKAGE_TAG} comparing to old ${PACKAGE_TAG} from github" echo "Package tag sha from current packages in buit container is ${NEW_PACKAGE_TAG} comparing to old ${PACKAGE_TAG} from github"
if [ "${NEW_PACKAGE_TAG}" != "${PACKAGE_TAG}" ]; then if [ "${NEW_PACKAGE_TAG}" != "${PACKAGE_TAG}" ]; then
git clone https://github.com/${LS_USER}/${LS_REPO}.git ${TEMPDIR}/${LS_REPO} git clone https://github.com/${LS_USER}/${LS_REPO}.git ${TEMPDIR}/${LS_REPO}
git --git-dir ${TEMPDIR}/${LS_REPO}/.git checkout -f focal git --git-dir ${TEMPDIR}/${LS_REPO}/.git checkout -f master
cp ${TEMPDIR}/package_versions.txt ${TEMPDIR}/${LS_REPO}/ cp ${TEMPDIR}/package_versions.txt ${TEMPDIR}/${LS_REPO}/
cd ${TEMPDIR}/${LS_REPO}/ cd ${TEMPDIR}/${LS_REPO}/
wait wait
@ -621,7 +623,7 @@ pipeline {
// Exit the build if the package file was just updated // Exit the build if the package file was just updated
stage('PACKAGE-exit') { stage('PACKAGE-exit') {
when { when {
branch "focal" branch "master"
environment name: 'CHANGE_ID', value: '' environment name: 'CHANGE_ID', value: ''
environment name: 'PACKAGE_UPDATED', value: 'true' environment name: 'PACKAGE_UPDATED', value: 'true'
environment name: 'EXIT_STATUS', value: '' environment name: 'EXIT_STATUS', value: ''
@ -642,7 +644,7 @@ pipeline {
// Exit the build if this is just a package check and there are no changes to push // Exit the build if this is just a package check and there are no changes to push
stage('PACKAGECHECK-exit') { stage('PACKAGECHECK-exit') {
when { when {
branch "focal" branch "master"
environment name: 'CHANGE_ID', value: '' environment name: 'CHANGE_ID', value: ''
environment name: 'PACKAGE_UPDATED', value: 'false' environment name: 'PACKAGE_UPDATED', value: 'false'
environment name: 'EXIT_STATUS', value: '' environment name: 'EXIT_STATUS', value: ''
@ -745,12 +747,12 @@ pipeline {
echo $QUAYPASS | docker login quay.io -u $QUAYUSER --password-stdin echo $QUAYPASS | docker login quay.io -u $QUAYUSER --password-stdin
for PUSHIMAGE in "${GITHUBIMAGE}" "${GITLABIMAGE}" "${QUAYIMAGE}" "${IMAGE}"; do for PUSHIMAGE in "${GITHUBIMAGE}" "${GITLABIMAGE}" "${QUAYIMAGE}" "${IMAGE}"; do
docker tag ${IMAGE}:${META_TAG} ${PUSHIMAGE}:${META_TAG} docker tag ${IMAGE}:${META_TAG} ${PUSHIMAGE}:${META_TAG}
docker tag ${PUSHIMAGE}:${META_TAG} ${PUSHIMAGE}:focal docker tag ${PUSHIMAGE}:${META_TAG} ${PUSHIMAGE}:latest
docker tag ${PUSHIMAGE}:${META_TAG} ${PUSHIMAGE}:${EXT_RELEASE_TAG} docker tag ${PUSHIMAGE}:${META_TAG} ${PUSHIMAGE}:${EXT_RELEASE_TAG}
if [ -n "${SEMVER}" ]; then if [ -n "${SEMVER}" ]; then
docker tag ${PUSHIMAGE}:${META_TAG} ${PUSHIMAGE}:${SEMVER} docker tag ${PUSHIMAGE}:${META_TAG} ${PUSHIMAGE}:${SEMVER}
fi fi
docker push ${PUSHIMAGE}:focal docker push ${PUSHIMAGE}:latest
docker push ${PUSHIMAGE}:${META_TAG} docker push ${PUSHIMAGE}:${META_TAG}
docker push ${PUSHIMAGE}:${EXT_RELEASE_TAG} docker push ${PUSHIMAGE}:${EXT_RELEASE_TAG}
if [ -n "${SEMVER}" ]; then if [ -n "${SEMVER}" ]; then
@ -764,7 +766,7 @@ pipeline {
docker rmi \ docker rmi \
${DELETEIMAGE}:${META_TAG} \ ${DELETEIMAGE}:${META_TAG} \
${DELETEIMAGE}:${EXT_RELEASE_TAG} \ ${DELETEIMAGE}:${EXT_RELEASE_TAG} \
${DELETEIMAGE}:focal || : ${DELETEIMAGE}:latest || :
if [ -n "${SEMVER}" ]; then if [ -n "${SEMVER}" ]; then
docker rmi ${DELETEIMAGE}:${SEMVER} || : docker rmi ${DELETEIMAGE}:${SEMVER} || :
fi fi
@ -811,9 +813,9 @@ pipeline {
docker tag ${IMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-${META_TAG} docker tag ${IMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-${META_TAG}
docker tag ${IMAGE}:arm32v7-${META_TAG} ${MANIFESTIMAGE}:arm32v7-${META_TAG} docker tag ${IMAGE}:arm32v7-${META_TAG} ${MANIFESTIMAGE}:arm32v7-${META_TAG}
docker tag ${IMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${META_TAG} docker tag ${IMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${META_TAG}
docker tag ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-focal docker tag ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-latest
docker tag ${MANIFESTIMAGE}:arm32v7-${META_TAG} ${MANIFESTIMAGE}:arm32v7-focal docker tag ${MANIFESTIMAGE}:arm32v7-${META_TAG} ${MANIFESTIMAGE}:arm32v7-latest
docker tag ${MANIFESTIMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-focal docker tag ${MANIFESTIMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-latest
docker tag ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-${EXT_RELEASE_TAG} docker tag ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-${EXT_RELEASE_TAG}
docker tag ${MANIFESTIMAGE}:arm32v7-${META_TAG} ${MANIFESTIMAGE}:arm32v7-${EXT_RELEASE_TAG} docker tag ${MANIFESTIMAGE}:arm32v7-${META_TAG} ${MANIFESTIMAGE}:arm32v7-${EXT_RELEASE_TAG}
docker tag ${MANIFESTIMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${EXT_RELEASE_TAG} docker tag ${MANIFESTIMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${EXT_RELEASE_TAG}
@ -825,9 +827,9 @@ pipeline {
docker push ${MANIFESTIMAGE}:amd64-${META_TAG} docker push ${MANIFESTIMAGE}:amd64-${META_TAG}
docker push ${MANIFESTIMAGE}:arm32v7-${META_TAG} docker push ${MANIFESTIMAGE}:arm32v7-${META_TAG}
docker push ${MANIFESTIMAGE}:arm64v8-${META_TAG} docker push ${MANIFESTIMAGE}:arm64v8-${META_TAG}
docker push ${MANIFESTIMAGE}:amd64-focal docker push ${MANIFESTIMAGE}:amd64-latest
docker push ${MANIFESTIMAGE}:arm32v7-focal docker push ${MANIFESTIMAGE}:arm32v7-latest
docker push ${MANIFESTIMAGE}:arm64v8-focal docker push ${MANIFESTIMAGE}:arm64v8-latest
docker push ${MANIFESTIMAGE}:amd64-${EXT_RELEASE_TAG} docker push ${MANIFESTIMAGE}:amd64-${EXT_RELEASE_TAG}
docker push ${MANIFESTIMAGE}:arm32v7-${EXT_RELEASE_TAG} docker push ${MANIFESTIMAGE}:arm32v7-${EXT_RELEASE_TAG}
docker push ${MANIFESTIMAGE}:arm64v8-${EXT_RELEASE_TAG} docker push ${MANIFESTIMAGE}:arm64v8-${EXT_RELEASE_TAG}
@ -836,10 +838,10 @@ pipeline {
docker push ${MANIFESTIMAGE}:arm32v7-${SEMVER} docker push ${MANIFESTIMAGE}:arm32v7-${SEMVER}
docker push ${MANIFESTIMAGE}:arm64v8-${SEMVER} docker push ${MANIFESTIMAGE}:arm64v8-${SEMVER}
fi fi
docker manifest push --purge ${MANIFESTIMAGE}:focal || : docker manifest push --purge ${MANIFESTIMAGE}:latest || :
docker manifest create ${MANIFESTIMAGE}:focal ${MANIFESTIMAGE}:amd64-focal ${MANIFESTIMAGE}:arm32v7-focal ${MANIFESTIMAGE}:arm64v8-focal docker manifest create ${MANIFESTIMAGE}:latest ${MANIFESTIMAGE}:amd64-latest ${MANIFESTIMAGE}:arm32v7-latest ${MANIFESTIMAGE}:arm64v8-latest
docker manifest annotate ${MANIFESTIMAGE}:focal ${MANIFESTIMAGE}:arm32v7-focal --os linux --arch arm docker manifest annotate ${MANIFESTIMAGE}:latest ${MANIFESTIMAGE}:arm32v7-latest --os linux --arch arm
docker manifest annotate ${MANIFESTIMAGE}:focal ${MANIFESTIMAGE}:arm64v8-focal --os linux --arch arm64 --variant v8 docker manifest annotate ${MANIFESTIMAGE}:latest ${MANIFESTIMAGE}:arm64v8-latest --os linux --arch arm64 --variant v8
docker manifest push --purge ${MANIFESTIMAGE}:${META_TAG} || : docker manifest push --purge ${MANIFESTIMAGE}:${META_TAG} || :
docker manifest create ${MANIFESTIMAGE}:${META_TAG} ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:arm32v7-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${META_TAG} docker manifest create ${MANIFESTIMAGE}:${META_TAG} ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:arm32v7-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${META_TAG}
docker manifest annotate ${MANIFESTIMAGE}:${META_TAG} ${MANIFESTIMAGE}:arm32v7-${META_TAG} --os linux --arch arm docker manifest annotate ${MANIFESTIMAGE}:${META_TAG} ${MANIFESTIMAGE}:arm32v7-${META_TAG} --os linux --arch arm
@ -854,7 +856,7 @@ pipeline {
docker manifest annotate ${MANIFESTIMAGE}:${SEMVER} ${MANIFESTIMAGE}:arm32v7-${SEMVER} --os linux --arch arm docker manifest annotate ${MANIFESTIMAGE}:${SEMVER} ${MANIFESTIMAGE}:arm32v7-${SEMVER} --os linux --arch arm
docker manifest annotate ${MANIFESTIMAGE}:${SEMVER} ${MANIFESTIMAGE}:arm64v8-${SEMVER} --os linux --arch arm64 --variant v8 docker manifest annotate ${MANIFESTIMAGE}:${SEMVER} ${MANIFESTIMAGE}:arm64v8-${SEMVER} --os linux --arch arm64 --variant v8
fi fi
docker manifest push --purge ${MANIFESTIMAGE}:focal docker manifest push --purge ${MANIFESTIMAGE}:latest
docker manifest push --purge ${MANIFESTIMAGE}:${META_TAG} docker manifest push --purge ${MANIFESTIMAGE}:${META_TAG}
docker manifest push --purge ${MANIFESTIMAGE}:${EXT_RELEASE_TAG} docker manifest push --purge ${MANIFESTIMAGE}:${EXT_RELEASE_TAG}
if [ -n "${SEMVER}" ]; then if [ -n "${SEMVER}" ]; then
@ -867,13 +869,13 @@ pipeline {
for DELETEIMAGE in "${GITHUBIMAGE}" "${GITLABIMAGE}" "${QUAYIMAGE}" "${IMAGE}"; do for DELETEIMAGE in "${GITHUBIMAGE}" "${GITLABIMAGE}" "${QUAYIMAGE}" "${IMAGE}"; do
docker rmi \ docker rmi \
${DELETEIMAGE}:amd64-${META_TAG} \ ${DELETEIMAGE}:amd64-${META_TAG} \
${DELETEIMAGE}:amd64-focal \ ${DELETEIMAGE}:amd64-latest \
${DELETEIMAGE}:amd64-${EXT_RELEASE_TAG} \ ${DELETEIMAGE}:amd64-${EXT_RELEASE_TAG} \
${DELETEIMAGE}:arm32v7-${META_TAG} \ ${DELETEIMAGE}:arm32v7-${META_TAG} \
${DELETEIMAGE}:arm32v7-focal \ ${DELETEIMAGE}:arm32v7-latest \
${DELETEIMAGE}:arm32v7-${EXT_RELEASE_TAG} \ ${DELETEIMAGE}:arm32v7-${EXT_RELEASE_TAG} \
${DELETEIMAGE}:arm64v8-${META_TAG} \ ${DELETEIMAGE}:arm64v8-${META_TAG} \
${DELETEIMAGE}:arm64v8-focal \ ${DELETEIMAGE}:arm64v8-latest \
${DELETEIMAGE}:arm64v8-${EXT_RELEASE_TAG} || : ${DELETEIMAGE}:arm64v8-${EXT_RELEASE_TAG} || :
if [ -n "${SEMVER}" ]; then if [ -n "${SEMVER}" ]; then
docker rmi \ docker rmi \
@ -892,7 +894,7 @@ pipeline {
// If this is a public release tag it in the LS Github // If this is a public release tag it in the LS Github
stage('Github-Tag-Push-Release') { stage('Github-Tag-Push-Release') {
when { when {
branch "focal" branch "master"
expression { expression {
env.LS_RELEASE != env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER env.LS_RELEASE != env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER
} }
@ -904,14 +906,14 @@ pipeline {
sh '''curl -H "Authorization: token ${GITHUB_TOKEN}" -X POST https://api.github.com/repos/${LS_USER}/${LS_REPO}/git/tags \ sh '''curl -H "Authorization: token ${GITHUB_TOKEN}" -X POST https://api.github.com/repos/${LS_USER}/${LS_REPO}/git/tags \
-d '{"tag":"'${META_TAG}'",\ -d '{"tag":"'${META_TAG}'",\
"object": "'${COMMIT_SHA}'",\ "object": "'${COMMIT_SHA}'",\
"message": "Tagging Release '${EXT_RELEASE_CLEAN}'-ls'${LS_TAG_NUMBER}' to focal",\ "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 Jenkins","email": "jenkins@linuxserver.io","date": "'${GITHUB_DATE}'"}}' '''
echo "Pushing New release for Tag" echo "Pushing New release for Tag"
sh '''#! /bin/bash sh '''#! /bin/bash
echo "Updating to ${EXT_RELEASE_CLEAN}" > releasebody.json echo "Updating to ${EXT_RELEASE_CLEAN}" > releasebody.json
echo '{"tag_name":"'${META_TAG}'",\ echo '{"tag_name":"'${META_TAG}'",\
"target_commitish": "focal",\ "target_commitish": "master",\
"name": "'${META_TAG}'",\ "name": "'${META_TAG}'",\
"body": "**LinuxServer Changes:**\\n\\n'${LS_RELEASE_NOTES}'\\n\\n**Remote Changes:**\\n\\n' > start "body": "**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

View File

@ -1,5 +1,5 @@
<!-- DO NOT EDIT THIS FILE MANUALLY --> <!-- DO NOT EDIT THIS FILE MANUALLY -->
<!-- Please read the https://github.com/linuxserver/docker-code-server/blob/focal/.github/CONTRIBUTING.md --> <!-- Please read the https://github.com/linuxserver/docker-code-server/blob/master/.github/CONTRIBUTING.md -->
[![linuxserver.io](https://raw.githubusercontent.com/linuxserver/docker-templates/master/linuxserver.io/img/linuxserver_medium.png)](https://linuxserver.io) [![linuxserver.io](https://raw.githubusercontent.com/linuxserver/docker-templates/master/linuxserver.io/img/linuxserver_medium.png)](https://linuxserver.io)
@ -37,7 +37,7 @@ Find us at:
[![Quay.io](https://img.shields.io/static/v1.svg?color=94398d&labelColor=555555&logoColor=ffffff&style=for-the-badge&label=linuxserver.io&message=Quay.io)](https://quay.io/repository/linuxserver.io/code-server) [![Quay.io](https://img.shields.io/static/v1.svg?color=94398d&labelColor=555555&logoColor=ffffff&style=for-the-badge&label=linuxserver.io&message=Quay.io)](https://quay.io/repository/linuxserver.io/code-server)
[![Docker Pulls](https://img.shields.io/docker/pulls/linuxserver/code-server.svg?color=94398d&labelColor=555555&logoColor=ffffff&style=for-the-badge&label=pulls&logo=docker)](https://hub.docker.com/r/linuxserver/code-server) [![Docker Pulls](https://img.shields.io/docker/pulls/linuxserver/code-server.svg?color=94398d&labelColor=555555&logoColor=ffffff&style=for-the-badge&label=pulls&logo=docker)](https://hub.docker.com/r/linuxserver/code-server)
[![Docker Stars](https://img.shields.io/docker/stars/linuxserver/code-server.svg?color=94398d&labelColor=555555&logoColor=ffffff&style=for-the-badge&label=stars&logo=docker)](https://hub.docker.com/r/linuxserver/code-server) [![Docker Stars](https://img.shields.io/docker/stars/linuxserver/code-server.svg?color=94398d&labelColor=555555&logoColor=ffffff&style=for-the-badge&label=stars&logo=docker)](https://hub.docker.com/r/linuxserver/code-server)
[![Jenkins Build](https://img.shields.io/jenkins/build?labelColor=555555&logoColor=ffffff&style=for-the-badge&jobUrl=https%3A%2F%2Fci.linuxserver.io%2Fjob%2FDocker-Pipeline-Builders%2Fjob%2Fdocker-code-server%2Fjob%2Ffocal%2F&logo=jenkins)](https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-code-server/job/focal/) [![Jenkins Build](https://img.shields.io/jenkins/build?labelColor=555555&logoColor=ffffff&style=for-the-badge&jobUrl=https%3A%2F%2Fci.linuxserver.io%2Fjob%2FDocker-Pipeline-Builders%2Fjob%2Fdocker-code-server%2Fjob%2Fmaster%2F&logo=jenkins)](https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-code-server/job/master/)
[![LSIO CI](https://img.shields.io/badge/dynamic/yaml?color=94398d&labelColor=555555&logoColor=ffffff&style=for-the-badge&label=CI&query=CI&url=https%3A%2F%2Fci-tests.linuxserver.io%2Flinuxserver%2Fcode-server%2Flatest%2Fci-status.yml)](https://ci-tests.linuxserver.io/linuxserver/code-server/latest/index.html) [![LSIO CI](https://img.shields.io/badge/dynamic/yaml?color=94398d&labelColor=555555&logoColor=ffffff&style=for-the-badge&label=CI&query=CI&url=https%3A%2F%2Fci-tests.linuxserver.io%2Flinuxserver%2Fcode-server%2Flatest%2Fci-status.yml)](https://ci-tests.linuxserver.io/linuxserver/code-server/latest/index.html)
[Code-server](https://coder.com) is VS Code running on a remote server, accessible through the browser. [Code-server](https://coder.com) is VS Code running on a remote server, accessible through the browser.
@ -52,26 +52,27 @@ Find us at:
## Supported Architectures ## Supported Architectures
Our images support multiple architectures such as `x86-64`, `arm64` and `armhf`. We utilise the docker manifest for multi-platform awareness. More information is available from docker [here](https://github.com/docker/distribution/blob/master/docs/spec/manifest-v2-2.md#manifest-list) and our announcement [here](https://blog.linuxserver.io/2019/02/21/the-lsio-pipeline-project/). We utilise the docker manifest for multi-platform awareness. More information is available from docker [here](https://github.com/docker/distribution/blob/master/docs/spec/manifest-v2-2.md#manifest-list) and our announcement [here](https://blog.linuxserver.io/2019/02/21/the-lsio-pipeline-project/).
Simply pulling `lscr.io/linuxserver/code-server` should retrieve the correct image for your arch, but you can also pull specific arch images via tags. Simply pulling `lscr.io/linuxserver/code-server:latest` should retrieve the correct image for your arch, but you can also pull specific arch images via tags.
The architectures supported by this image are: The architectures supported by this image are:
| Architecture | Tag | | Architecture | Available | Tag |
| :----: | --- | | :----: | :----: | ---- |
| x86-64 | amd64-latest | | x86-64 | ✅ | amd64-\<version tag\> |
| arm64 | arm64v8-latest | | arm64 | ✅ | arm64v8-\<version tag\> |
| armhf | arm32v7-latest | | armhf| ✅ | arm32v7-\<version tag\> |
## Version Tags ## Version Tags
This image provides various versions that are available via tags. `latest` tag usually provides the latest stable version. Others are considered under development and caution must be exercised when using them. This image provides various versions that are available via tags. Please read the descriptions carefully and exercise caution when using unstable or development tags.
| Tag | Description | | Tag | Available | Description |
| :----: | --- | | :----: | :----: |--- |
| latest | Stable releases | | latest | ✅ | Stable releases |
| focal | Stable releases, on a focal baseiamge | | focal | ✅ | DEPRECATED (no longer updated, `latest` is rebased on focal) - Stable releases, based on Ubuntu Focal |
| development | ✅ | DEPRECATED (no longer updated) - Prereleases from their GitHub |
## Application Setup ## Application Setup
@ -99,7 +100,7 @@ Here are some example snippets to help you get started creating a container.
version: "2.1" version: "2.1"
services: services:
code-server: code-server:
image: lscr.io/linuxserver/code-server image: lscr.io/linuxserver/code-server:latest
container_name: code-server container_name: code-server
environment: environment:
- PUID=1000 - PUID=1000
@ -110,6 +111,7 @@ services:
- SUDO_PASSWORD=password #optional - SUDO_PASSWORD=password #optional
- SUDO_PASSWORD_HASH= #optional - SUDO_PASSWORD_HASH= #optional
- PROXY_DOMAIN=code-server.my.domain #optional - PROXY_DOMAIN=code-server.my.domain #optional
- DEFAULT_WORKSPACE=/config/workspace #optional
volumes: volumes:
- /path/to/appdata/config:/config - /path/to/appdata/config:/config
ports: ports:
@ -130,10 +132,11 @@ docker run -d \
-e SUDO_PASSWORD=password `#optional` \ -e SUDO_PASSWORD=password `#optional` \
-e SUDO_PASSWORD_HASH= `#optional` \ -e SUDO_PASSWORD_HASH= `#optional` \
-e PROXY_DOMAIN=code-server.my.domain `#optional` \ -e PROXY_DOMAIN=code-server.my.domain `#optional` \
-e DEFAULT_WORKSPACE=/config/workspace `#optional` \
-p 8443:8443 \ -p 8443:8443 \
-v /path/to/appdata/config:/config \ -v /path/to/appdata/config:/config \
--restart unless-stopped \ --restart unless-stopped \
lscr.io/linuxserver/code-server lscr.io/linuxserver/code-server:latest
``` ```
## Parameters ## Parameters
@ -151,6 +154,7 @@ Container images are configured using parameters passed at runtime (such as thos
| `-e SUDO_PASSWORD=password` | If this optional variable is set, user will have sudo access in the code-server terminal with the specified password. | | `-e SUDO_PASSWORD=password` | If this optional variable is set, user will have sudo access in the code-server terminal with the specified password. |
| `-e SUDO_PASSWORD_HASH=` | Optionally set sudo password via hash (takes priority over `SUDO_PASSWORD` var). Format is `$type$salt$hashed`. | | `-e SUDO_PASSWORD_HASH=` | Optionally set sudo password via hash (takes priority over `SUDO_PASSWORD` var). Format is `$type$salt$hashed`. |
| `-e PROXY_DOMAIN=code-server.my.domain` | If this optional variable is set, this domain will be proxied for subdomain proxying. See [Documentation](https://github.com/cdr/code-server/blob/master/docs/FAQ.md#sub-domains) | | `-e PROXY_DOMAIN=code-server.my.domain` | If this optional variable is set, this domain will be proxied for subdomain proxying. See [Documentation](https://github.com/cdr/code-server/blob/master/docs/FAQ.md#sub-domains) |
| `-e DEFAULT_WORKSPACE=/config/workspace` | If this optional variable is set, code-server will open this directory by default |
| `-v /config` | Contains all relevant configuration files. | | `-v /config` | Contains all relevant configuration files. |
## Environment variables from files (Docker secrets) ## Environment variables from files (Docker secrets)
@ -196,7 +200,7 @@ We publish various [Docker Mods](https://github.com/linuxserver/docker-mods) to
* container version number * container version number
* `docker inspect -f '{{ index .Config.Labels "build_version" }}' code-server` * `docker inspect -f '{{ index .Config.Labels "build_version" }}' code-server`
* image version number * image version number
* `docker inspect -f '{{ index .Config.Labels "build_version" }}' lscr.io/linuxserver/code-server` * `docker inspect -f '{{ index .Config.Labels "build_version" }}' lscr.io/linuxserver/code-server:latest`
## Updating Info ## Updating Info
@ -214,7 +218,7 @@ Below are the instructions for updating containers:
### Via Docker Run ### Via Docker Run
* Update the image: `docker pull lscr.io/linuxserver/code-server` * Update the image: `docker pull lscr.io/linuxserver/code-server:latest`
* Stop the running container: `docker stop code-server` * Stop the running container: `docker stop code-server`
* Delete the container: `docker rm code-server` * Delete the container: `docker rm code-server`
* Recreate a new container with the same docker run parameters as instructed above (if mapped correctly to a host folder, your `/config` folder and settings will be preserved) * Recreate a new container with the same docker run parameters as instructed above (if mapped correctly to a host folder, your `/config` folder and settings will be preserved)
@ -262,7 +266,11 @@ Once registered you can define the dockerfile to use with `-f Dockerfile.aarch64
## Versions ## Versions
* **12.07.21:** - Rebase to focal * **20.02.22:** - Install using the official tarballs.
* **29.12.21:** - Add `install-extension` as a helper for mods to install extensions.
* **06.12.21:** - Add `DEFAULT_WORKSPACE` env var.
* **29.11.21:** - Rebase to Ubuntu focal.
* **16.09.21:** - Fix slow `chown` on large workspace (contents of workspace folder no longer chowned).
* **11.07.21:** - Bump node to 14 to fix builds * **11.07.21:** - Bump node to 14 to fix builds
* **08.05.21:** - Fix doc link * **08.05.21:** - Fix doc link
* **04.02.20:** - Allow setting gui password via hash using env var `HASHED_PASSWORD`. * **04.02.20:** - Allow setting gui password via hash using env var `HASHED_PASSWORD`.

View File

@ -3,10 +3,10 @@
# jenkins variables # jenkins variables
project_name: docker-code-server project_name: docker-code-server
external_type: na external_type: na
custom_version_command: "curl -sX GET https://registry.yarnpkg.com/code-server | jq -r '.\"dist-tags\".latest' | sed 's|^|v|'" custom_version_command: "curl -sX GET https://api.github.com/repos/coder/code-server/releases/latest | jq -r '.tag_name' | sed 's|^v||'"
release_type: stable release_type: stable
release_tag: focal release_tag: latest
ls_branch: focal ls_branch: master
repo_vars: repo_vars:
- CONTAINER_NAME = 'code-server' - CONTAINER_NAME = 'code-server'
- BUILD_VERSION_ARG = 'CODE_RELEASE' - BUILD_VERSION_ARG = 'CODE_RELEASE'

View File

@ -1,37 +1,36 @@
adduser3.118ubuntu2 adduser3.118ubuntu2
apt2.0.6 apt2.0.9
apt-utils2.0.6 apt-utils2.0.9
base-files11ubuntu5.4 base-files11ubuntu5.5
base-passwd3.5.47 base-passwd3.5.47
bash5.0-6ubuntu1.1 bash5.0-6ubuntu1.1
bsdutils1:2.34-0.1ubuntu9.1 bsdutils1:2.34-0.1ubuntu9.3
bzip21.0.8-2 bzip21.0.8-2
ca-certificates20210119~20.04.2 ca-certificates20211016~20.04.1
coreutils8.30-3ubuntu2 coreutils8.30-3ubuntu2
curl7.68.0-1ubuntu2.7 curl7.68.0-1ubuntu2.12
dash0.5.10.2-6 dash0.5.10.2-6
debconf1.5.73 debconf1.5.73
debianutils4.9.1 debianutils4.9.1
diffutils1:3.7-3 diffutils1:3.7-3
dirmngr2.2.19-3ubuntu2.1 dirmngr2.2.19-3ubuntu2.2
dpkg1.19.7ubuntu3 dpkg1.19.7ubuntu3
e2fsprogs1.45.5-2ubuntu1 e2fsprogs1.45.5-2ubuntu1
fdisk2.34-0.1ubuntu9.1 fdisk2.34-0.1ubuntu9.3
file1:5.38-4
findutils4.7.0-1ubuntu1 findutils4.7.0-1ubuntu1
gcc-10-base10.3.0-1ubuntu1~20.04 gcc-10-base10.3.0-1ubuntu1~20.04
git1:2.25.1-1ubuntu3.2 git1:2.25.1-1ubuntu3.5
git-man1:2.25.1-1ubuntu3.2 git-man1:2.25.1-1ubuntu3.5
gnupg2.2.19-3ubuntu2.1 gnupg2.2.19-3ubuntu2.2
gnupg-l10n2.2.19-3ubuntu2.1 gnupg-l10n2.2.19-3ubuntu2.2
gnupg-utils2.2.19-3ubuntu2.1 gnupg-utils2.2.19-3ubuntu2.2
gpg2.2.19-3ubuntu2.1 gpg2.2.19-3ubuntu2.2
gpg-agent2.2.19-3ubuntu2.1 gpg-agent2.2.19-3ubuntu2.2
gpgconf2.2.19-3ubuntu2.1 gpgconf2.2.19-3ubuntu2.2
gpgsm2.2.19-3ubuntu2.1 gpgsm2.2.19-3ubuntu2.2
gpgv2.2.19-3ubuntu2.1 gpgv2.2.19-3ubuntu2.2
gpg-wks-client2.2.19-3ubuntu2.1 gpg-wks-client2.2.19-3ubuntu2.2
gpg-wks-server2.2.19-3ubuntu2.1 gpg-wks-server2.2.19-3ubuntu2.2
grep3.4-1 grep3.4-1
gzip1.10-0ubuntu4 gzip1.10-0ubuntu4
hostname3.23 hostname3.23
@ -40,31 +39,32 @@ jq1.6-1ubuntu0.20.04.1
krb5-locales1.17-6ubuntu4.1 krb5-locales1.17-6ubuntu4.1
less551-1ubuntu0.1 less551-1ubuntu0.1
libacl12.2.53-6 libacl12.2.53-6
libapt-pkg6.02.0.6 libapt-pkg6.02.0.9
libasn1-8-heimdal7.7.0+dfsg-1ubuntu1 libasn1-8-heimdal7.7.0+dfsg-1ubuntu1
libassuan02.5.3-7ubuntu2 libassuan02.5.3-7ubuntu2
libatomic110.3.0-1ubuntu1~20.04
libattr11:2.4.48-5 libattr11:2.4.48-5
libaudit11:2.8.5-2ubuntu6 libaudit11:2.8.5-2ubuntu6
libaudit-common1:2.8.5-2ubuntu6 libaudit-common1:2.8.5-2ubuntu6
libblkid12.34-0.1ubuntu9.1 libblkid12.34-0.1ubuntu9.3
libbrotli11.0.7-6ubuntu0.1 libbrotli11.0.7-6ubuntu0.1
libbsd00.10.0-1 libbsd00.10.0-1
libbz2-1.01.0.8-2 libbz2-1.01.0.8-2
libc62.31-0ubuntu9.2 libc62.31-0ubuntu9.9
libcap-ng00.7.9-2.1build1 libcap-ng00.7.9-2.1build1
libc-bin2.31-0ubuntu9.2 libc-bin2.31-0ubuntu9.7
libcbor0.60.6.0-0ubuntu1 libcbor0.60.6.0-0ubuntu1
libcom-err21.45.5-2ubuntu1 libcom-err21.45.5-2ubuntu1
libcrypt11:4.4.10-10ubuntu4 libcrypt11:4.4.10-10ubuntu4
libcurl3-gnutls7.68.0-1ubuntu2.7 libcurl3-gnutls7.68.0-1ubuntu2.12
libcurl47.68.0-1ubuntu2.7 libcurl47.68.0-1ubuntu2.12
libdb5.35.3.28+dfsg1-0.6ubuntu2 libdb5.35.3.28+dfsg1-0.6ubuntu2
libdebconfclient00.251ubuntu1 libdebconfclient00.251ubuntu1
libedit23.1-20191231-1 libedit23.1-20191231-1
liberror-perl0.17029-1 liberror-perl0.17029-1
libexpat12.2.9-1build1 libexpat12.2.9-1ubuntu0.4
libext2fs21.45.5-2ubuntu1 libext2fs21.45.5-2ubuntu1
libfdisk12.34-0.1ubuntu9.1 libfdisk12.34-0.1ubuntu9.3
libffi73.3-4 libffi73.3-4
libfido2-11.3.1-1ubuntu2 libfido2-11.3.1-1ubuntu2
libgcc-s110.3.0-1ubuntu1~20.04 libgcc-s110.3.0-1ubuntu1~20.04
@ -84,19 +84,16 @@ libhx509-5-heimdal7.7.0+dfsg-1ubuntu1
libidn2-02.2.0-2 libidn2-02.2.0-2
libjq11.6-1ubuntu0.20.04.1 libjq11.6-1ubuntu0.20.04.1
libk5crypto31.17-6ubuntu4.1 libk5crypto31.17-6ubuntu4.1
libkeyutils11.6-6ubuntu1 libkeyutils11.6-6ubuntu1.1
libkrb5-26-heimdal7.7.0+dfsg-1ubuntu1 libkrb5-26-heimdal7.7.0+dfsg-1ubuntu1
libkrb5-31.17-6ubuntu4.1 libkrb5-31.17-6ubuntu4.1
libkrb5support01.17-6ubuntu4.1 libkrb5support01.17-6ubuntu4.1
libksba81.3.5-2 libksba81.3.5-2
libldap-2.4-22.4.49+dfsg-2ubuntu1.8 libldap-2.4-22.4.49+dfsg-2ubuntu1.9
libldap-common2.4.49+dfsg-2ubuntu1.8 libldap-common2.4.49+dfsg-2ubuntu1.9
liblz4-11.9.2-2ubuntu0.20.04.1 liblz4-11.9.2-2ubuntu0.20.04.1
liblzma55.2.4-1ubuntu1 liblzma55.2.4-1ubuntu1
libmagic11:5.38-4 libmount12.34-0.1ubuntu9.3
libmagic-mgc1:5.38-4
libmount12.34-0.1ubuntu9.1
libmpdec22.4.2-3
libncurses66.2-0ubuntu2 libncurses66.2-0ubuntu2
libncursesw66.2-0ubuntu2 libncursesw66.2-0ubuntu2
libnettle73.5.1+really3.5.1-2ubuntu0.2 libnettle73.5.1+really3.5.1-2ubuntu0.2
@ -113,32 +110,29 @@ libpcre32:8.39-12build1
libperl5.305.30.0-9ubuntu0.2 libperl5.305.30.0-9ubuntu0.2
libprocps82:3.3.16-1ubuntu2.3 libprocps82:3.3.16-1ubuntu2.3
libpsl50.21.0-1ubuntu1 libpsl50.21.0-1ubuntu1
libpython3.8-minimal3.8.10-0ubuntu1~20.04.2
libpython3.8-stdlib3.8.10-0ubuntu1~20.04.2
libpython3-stdlib3.8.2-0ubuntu2
libreadline88.0-4 libreadline88.0-4
libroken18-heimdal7.7.0+dfsg-1ubuntu1 libroken18-heimdal7.7.0+dfsg-1ubuntu1
librtmp12.4+20151223.gitfa8646d.1-2build1 librtmp12.4+20151223.gitfa8646d.1-2build1
libsasl2-22.1.27+dfsg-2 libsasl2-22.1.27+dfsg-2ubuntu0.1
libsasl2-modules2.1.27+dfsg-2 libsasl2-modules2.1.27+dfsg-2ubuntu0.1
libsasl2-modules-db2.1.27+dfsg-2 libsasl2-modules-db2.1.27+dfsg-2ubuntu0.1
libseccomp22.5.1-1ubuntu1~20.04.2 libseccomp22.5.1-1ubuntu1~20.04.2
libselinux13.0-1build2 libselinux13.0-1build2
libsemanage13.0-1build2 libsemanage13.0-1build2
libsemanage-common3.0-1build2 libsemanage-common3.0-1build2
libsepol13.0-1 libsepol13.0-1
libsmartcols12.34-0.1ubuntu9.1 libsmartcols12.34-0.1ubuntu9.3
libsqlite3-03.31.1-4ubuntu0.2 libsqlite3-03.31.1-4ubuntu0.3
libss21.45.5-2ubuntu1 libss21.45.5-2ubuntu1
libssh-40.9.3-2ubuntu2.2 libssh-40.9.3-2ubuntu2.2
libssl1.11.1.1f-1ubuntu2.10 libssl1.11.1.1f-1ubuntu2.16
libstdc++610.3.0-1ubuntu1~20.04 libstdc++610.3.0-1ubuntu1~20.04
libsystemd0245.4-4ubuntu3.13 libsystemd0245.4-4ubuntu3.15
libtasn1-64.16.0-2 libtasn1-64.16.0-2
libtinfo66.2-0ubuntu2 libtinfo66.2-0ubuntu2
libudev1245.4-4ubuntu3.13 libudev1245.4-4ubuntu3.15
libunistring20.9.10-2 libunistring20.9.10-2
libuuid12.34-0.1ubuntu9.1 libuuid12.34-0.1ubuntu9.3
libwind0-heimdal7.7.0+dfsg-1ubuntu1 libwind0-heimdal7.7.0+dfsg-1ubuntu1
libx11-62:1.6.9-2ubuntu1.2 libx11-62:1.6.9-2ubuntu1.2
libx11-data2:1.6.9-2ubuntu1.2 libx11-data2:1.6.9-2ubuntu1.2
@ -148,21 +142,19 @@ libxdmcp61:1.1.3-0ubuntu1
libxext62:1.3.4-0ubuntu1 libxext62:1.3.4-0ubuntu1
libxmuu12:1.1.3-0ubuntu1 libxmuu12:1.1.3-0ubuntu1
libzstd11.4.4+dfsg-3ubuntu0.1 libzstd11.4.4+dfsg-3ubuntu0.1
locales2.31-0ubuntu9.2 locales2.31-0ubuntu9.9
login1:4.8.1-1ubuntu5.20.04.1 login1:4.8.1-1ubuntu5.20.04.1
logsave1.45.5-2ubuntu1 logsave1.45.5-2ubuntu1
lsb-base11.1.0ubuntu2 lsb-base11.1.0ubuntu2
mawk1.3.4.20200120-2 mawk1.3.4.20200120-2
mime-support3.64ubuntu1 mount2.34-0.1ubuntu9.3
mount2.34-0.1ubuntu9.1
nano4.8-1ubuntu1 nano4.8-1ubuntu1
ncurses-base6.2-0ubuntu2 ncurses-base6.2-0ubuntu2
ncurses-bin6.2-0ubuntu2 ncurses-bin6.2-0ubuntu2
netbase6.1 netbase6.1
net-tools1.60+git20180626.aebd88e-1ubuntu1 net-tools1.60+git20180626.aebd88e-1ubuntu1
nodejs14.18.2-deb-1nodesource1 openssh-client1:8.2p1-4ubuntu0.5
openssh-client1:8.2p1-4ubuntu0.3 openssl1.1.1f-1ubuntu2.16
openssl1.1.1f-1ubuntu2.10
passwd1:4.8.1-1ubuntu5.20.04.1 passwd1:4.8.1-1ubuntu5.20.04.1
patch2.7.6-6 patch2.7.6-6
perl5.30.0-9ubuntu0.2 perl5.30.0-9ubuntu0.2
@ -171,20 +163,14 @@ perl-modules-5.305.30.0-9ubuntu0.2
pinentry-curses1.1.0-3build1 pinentry-curses1.1.0-3build1
procps2:3.3.16-1ubuntu2.3 procps2:3.3.16-1ubuntu2.3
publicsuffix20200303.0012-1 publicsuffix20200303.0012-1
python33.8.2-0ubuntu2
python3.83.8.10-0ubuntu1~20.04.2
python3.8-minimal3.8.10-0ubuntu1~20.04.2
python3-minimal3.8.2-0ubuntu2
readline-common8.0-4 readline-common8.0-4
sed4.7-1 sed4.7-1
sensible-utils0.0.12+nmu1 sensible-utils0.0.12+nmu1
sudo1.8.31-1ubuntu1.2 sudo1.8.31-1ubuntu1.2
sysvinit-utils2.96-2.1ubuntu1 sysvinit-utils2.96-2.1ubuntu1
tar1.30+dfsg-7ubuntu0.20.04.1 tar1.30+dfsg-7ubuntu0.20.04.2
tzdata2021e-0ubuntu0.20.04 tzdata2022a-0ubuntu0.20.04
ubuntu-keyring2020.02.11.4 ubuntu-keyring2020.02.11.4
util-linux2.34-0.1ubuntu9.1 util-linux2.34-0.1ubuntu9.3
xauth1:1.1-0ubuntu1 xauth1:1.1-0ubuntu1
xz-utils5.2.4-1ubuntu1
yarn1.22.17-1
zlib1g1:1.2.11.dfsg-2ubuntu1.2 zlib1g1:1.2.11.dfsg-2ubuntu1.2

View File

@ -29,7 +29,8 @@ available_architectures:
development_versions: true development_versions: true
development_versions_items: development_versions_items:
- { tag: "latest", desc: "Stable releases" } - { tag: "latest", desc: "Stable releases" }
- { tag: "focal", desc: "Stable releases, on a focal baseiamge" } - { tag: "focal", desc: "DEPRECATED (no longer updated, `latest` is rebased on focal) - Stable releases, based on Ubuntu Focal" }
- { tag: "development", desc: "DEPRECATED (no longer updated) - Prereleases from their GitHub" }
# container parameters # container parameters
common_param_env_vars_enabled: true common_param_env_vars_enabled: true
@ -52,6 +53,7 @@ opt_param_env_vars:
- { env_var: "SUDO_PASSWORD", env_value: "password", desc: "If this optional variable is set, user will have sudo access in the code-server terminal with the specified password." } - { env_var: "SUDO_PASSWORD", env_value: "password", desc: "If this optional variable is set, user will have sudo access in the code-server terminal with the specified password." }
- { env_var: "SUDO_PASSWORD_HASH", env_value: "", desc: "Optionally set sudo password via hash (takes priority over `SUDO_PASSWORD` var). Format is `$type$salt$hashed`." } - { env_var: "SUDO_PASSWORD_HASH", env_value: "", desc: "Optionally set sudo password via hash (takes priority over `SUDO_PASSWORD` var). Format is `$type$salt$hashed`." }
- { env_var: "PROXY_DOMAIN", env_value: "code-server.my.domain", desc: "If this optional variable is set, this domain will be proxied for subdomain proxying. See [Documentation](https://github.com/cdr/code-server/blob/master/docs/FAQ.md#sub-domains)" } - { env_var: "PROXY_DOMAIN", env_value: "code-server.my.domain", desc: "If this optional variable is set, this domain will be proxied for subdomain proxying. See [Documentation](https://github.com/cdr/code-server/blob/master/docs/FAQ.md#sub-domains)" }
- { env_var: "DEFAULT_WORKSPACE", env_value: "/config/workspace", desc: "If this optional variable is set, code-server will open this directory by default" }
optional_block_1: false optional_block_1: false
optional_block_1_items: "" optional_block_1_items: ""
@ -75,7 +77,11 @@ app_setup_block: |
# changelog # changelog
changelogs: changelogs:
- { date: "12.07.21:", desc: "Rebase to focal" } - { date: "20.02.22:", desc: "Install using the official tarballs." }
- { date: "29.12.21:", desc: "Add `install-extension` as a helper for mods to install extensions." }
- { date: "06.12.21:", desc: "Add `DEFAULT_WORKSPACE` env var." }
- { date: "29.11.21:", desc: "Rebase to Ubuntu focal." }
- { date: "16.09.21:", desc: "Fix slow `chown` on large workspace (contents of workspace folder no longer chowned)." }
- { date: "11.07.21:", desc: "Bump node to 14 to fix builds" } - { date: "11.07.21:", desc: "Bump node to 14 to fix builds" }
- { date: "08.05.21:", desc: "Fix doc link" } - { date: "08.05.21:", desc: "Fix doc link" }
- { date: "04.02.20:", desc: "Allow setting gui password via hash using env var `HASHED_PASSWORD`." } - { date: "04.02.20:", desc: "Allow setting gui password via hash using env var `HASHED_PASSWORD`." }

View File

@ -23,5 +23,20 @@ fi
cp /root/.profile /config/.profile cp /root/.profile /config/.profile
# permissions # permissions
chown -R abc:abc \ if [ -f "/usr/bin/find" ] && [ -f "/usr/bin/xargs" ]; then
/config CORES=$(nproc --all)
# Split workload between config and workspace
echo "setting permissions::configuration"
find /config -path /config/workspace -prune -false -o -type d -print0 | \
xargs --null -r --max-args=1 --max-procs=$((CORES*2*8)) \
chown -R abc:abc
echo "setting permissions::workspace"
chown abc:abc /config/workspace
else
# Set permissions on data mount
# do not decend into the workspace
chown -R abc:abc "$(ls /config -I workspace)"
chown abc:abc /config/workspace
fi

View File

@ -15,11 +15,11 @@ fi
exec \ exec \
s6-setuidgid abc \ s6-setuidgid abc \
/usr/local/bin/code-server \ /app/code-server/bin/code-server \
--bind-addr 0.0.0.0:8443 \ --bind-addr 0.0.0.0:8443 \
--user-data-dir /config/data \ --user-data-dir /config/data \
--extensions-dir /config/extensions \ --extensions-dir /config/extensions \
--disable-telemetry \ --disable-telemetry \
--auth "${AUTH}" \ --auth "${AUTH}" \
"${PROXY_DOMAIN_ARG}" \ "${PROXY_DOMAIN_ARG}" \
/config/workspace "${DEFAULT_WORKSPACE:-/config/workspace}"

View File

@ -0,0 +1,10 @@
#!/usr/bin/with-contenv bash
# shellcheck shell=bash
_install=(/app/code-server/bin/code-server "--extensions-dir" "/config/extensions" "--install-extension")
if [ "$(whoami)" == "abc" ]; then
"${_install[@]}" "$@"
else
s6-setuidgid abc "${_install[@]}" "$@"
fi