Skip to content

Commit

Permalink
Merge pull request #8 from OSC/generator
Browse files Browse the repository at this point in the history
Run update_ood_portal before running service
  • Loading branch information
treydock authored Aug 4, 2020
2 parents 893f8ba + da3634b commit 269298b
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions packaging/ondemand-dex.spec
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ Source0: https://github.com/dexidp/dex/archive/v%{version}.tar.gz
Source1: https://dl.google.com/go/go%{go_version}.linux-amd64.tar.gz
Source2: web.tar.gz
# Adds session support
# Original commit: https://github.com/juliantaylor/dex/commit/b3fc3e6c2295c0af166803bdde0977ed170d1d40
Source5: https://github.com/OSC/dex/commit/b3fc3e6c2295c0af166803bdde0977ed170d1d40.patch

BuildRequires: ondemand-scldevel
Expand Down Expand Up @@ -68,6 +69,10 @@ touch %{buildroot}%{confdir}/dex.db
ExecStart=
ExecStart=%{_sbindir}/%{name}-session serve %{confdir}/config.yaml
EOF
%__cat >> %{buildroot}%{_sysconfdir}/systemd/system/%{name}.service.d/update_ood_portal.conf << EOF
[Service]
ExecStartPre=-/opt/ood/ood-portal-generator/sbin/update_ood_portal --rpm
EOF
%__mkdir_p %{buildroot}%{_unitdir}
%__cat >> %{buildroot}%{_unitdir}/%{name}.service << EOF
[Unit]
Expand Down Expand Up @@ -113,4 +118,5 @@ getent passwd %{name} > /dev/null || useradd -r -d /var/lib/%{name} -g %{name} -
%dir %{_sysconfdir}/systemd/system/%{name}.service.d
%ghost %{_sysconfdir}/systemd/system/%{name}.service.d/session.conf
%{_sysconfdir}/systemd/system/%{name}.service.d/session.conf.example
%{_sysconfdir}/systemd/system/%{name}.service.d/update_ood_portal.conf
%{_unitdir}/%{name}.service

0 comments on commit 269298b

Please sign in to comment.