Skip to content

Commit

Permalink
Update nodejs repo to use nodistro and new GPG key
Browse files Browse the repository at this point in the history
Fixes #261
  • Loading branch information
treydock committed Nov 1, 2023
1 parent 43b39cf commit c85d477
Show file tree
Hide file tree
Showing 7 changed files with 14 additions and 14 deletions.
2 changes: 1 addition & 1 deletion Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
PATH
remote: .
specs:
ood_packaging (0.13.4)
ood_packaging (0.13.5)
rake (~> 13.0.1)

GEM
Expand Down
4 changes: 2 additions & 2 deletions lib/ood_packaging/build_box/docker-image/Dockerfile.erb
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ RUN apt update -y && apt install -y apt-transport-https ca-certificates \
sudo rake wget curl ruby bundler && \
apt clean all -y
<% if ! ['bookworm'].include?(codename) && arch != 'ppc64le' %>
RUN echo "deb https://deb.nodesource.com/node_<%= nodejs_version %>.x <%= codename %> main" > /etc/apt/sources.list.d/nodesource.list
RUN curl -s https://deb.nodesource.com/gpgkey/nodesource.gpg.key | gpg --dearmor > /etc/apt/trusted.gpg.d/nodesource.gpg
RUN echo "deb https://deb.nodesource.com/node_<%= nodejs_version %>.x nodistro main" > /etc/apt/sources.list.d/nodesource.list
RUN curl -s https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor > /etc/apt/trusted.gpg.d/nodesource.gpg
<% end %>
<% end -%>
RUN ln -s /dev/null /etc/systemd/system/proc-sys-fs-binfmt_misc.automount
Expand Down
6 changes: 3 additions & 3 deletions lib/ood_packaging/version.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@

# Version code for OodPackaging
module OodPackaging
VERSION = '0.13.4'
VERSION = '0.13.5'
PACKAGE_VERSION = {
'ondemand-release' => {
'(ubuntu|debian)' => '3.1.0',
'(ubuntu|debian)' => '3.1.1',
'default' => '3.1'
},
'ondemand-release-latest' => {
'(ubuntu|debian)' => '2',
'(ubuntu|debian)' => '3',
'default' => '1-8'
},
'ondemand-runtime' => '3.1.3',
Expand Down
4 changes: 2 additions & 2 deletions packages/ondemand-release-latest/deb/debian/rules
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ override_dh_auto_install:
# Debian 12 (bookworm) has NodeJS 18 in OS repos
ifeq ($(CODENAME),bookworm)
else
echo "deb https://deb.nodesource.com/$(NODEREPO) $(CODENAME) main" > $(WEB_DESTDIR)/etc/apt/sources.list.d/nodesource.list
curl -s https://deb.nodesource.com/gpgkey/nodesource.gpg.key | gpg --dearmor > $(WEB_DESTDIR)/etc/apt/trusted.gpg.d/nodesource.gpg
echo "deb https://deb.nodesource.com/$(NODEREPO) nodistro main" > $(WEB_DESTDIR)/etc/apt/sources.list.d/nodesource.list
curl -s https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor > $(WEB_DESTDIR)/etc/apt/trusted.gpg.d/nodesource.gpg
endif

override_dh_builddeb:
Expand Down
4 changes: 2 additions & 2 deletions packages/ondemand-release/deb/debian/rules
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ override_dh_auto_install:
# Debian 12 (bookworm) has NodeJS 18 in OS repos
ifeq ($(CODENAME),bookworm)
else
echo "deb https://deb.nodesource.com/$(NODEREPO) $(CODENAME) main" > $(WEB_DESTDIR)/etc/apt/sources.list.d/nodesource.list
curl -s https://deb.nodesource.com/gpgkey/nodesource.gpg.key | gpg --dearmor > $(WEB_DESTDIR)/etc/apt/trusted.gpg.d/nodesource.gpg
echo "deb https://deb.nodesource.com/$(NODEREPO) nodistro main" > $(WEB_DESTDIR)/etc/apt/sources.list.d/nodesource.list
curl -s https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor > $(WEB_DESTDIR)/etc/apt/trusted.gpg.d/nodesource.gpg
endif

override_dh_builddeb:
Expand Down
6 changes: 3 additions & 3 deletions release-manifest.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ ondemand-release:
versions:
- '{major}-1'
# deb package
- '{major}.0-focal'
- '{major}.0-jammy'
- '{major}.0-bookworm'
- '{major}.1-focal'
- '{major}.1-jammy'
- '{major}.1-bookworm'

# web
cjose:
Expand Down
2 changes: 1 addition & 1 deletion spec/ood_packaging/ood_packaging_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@
end

it 'gets package version for dist ubuntu-20.04' do
expect(described_class.package_version('ondemand-release-latest', 'ubuntu-20.04')).to eq('2')
expect(described_class.package_version('ondemand-release-latest', 'ubuntu-20.04')).to eq('3')
end
end

0 comments on commit c85d477

Please sign in to comment.