Skip to content

libexec_startup: Import sbin scripts from projects #296

Merged
merged 3 commits into from
Jan 17, 2023

Conversation

donald
Copy link
Collaborator

@donald donald commented Jan 16, 2023

Import (some) scripts, which live in projects with user access and are
called from mxstartups, into repository and update install.sh.

The scripts are installed into /usr/libexec/startup/ with a name prefixed
with "prj_PROJECT_".

tor lassmichmalbittekurznachdenken - /project/tor/sbin/startup.sh

--> prj_tor_startup.sh

torb lassmichmalbittekurznachdenken - /project/torb/sbin/startup.sh

--> prj_torb_startup.sh

Notes:

This is not complete. The following startup scripts still need to be
done separately:

scinotedocker   ooclhongkong root   /project/scinoteweb/startstop-root.sh
githubnetwork   elwood -       /project/github2/sbin/setup-github-network.sh
gitlabnetwork   jake   -       /project/gitlab/sbin/setup-gitlab-network.sh
overleafnetwork jake   -       /project/overleaf/sbin/setup-overleaf-network.sh
vpn wtf -   /package/vpn/startstop.sh
columbus    chimichangas    -   /project/columbus/sbin/startup.sh
vm2network   chimichangas   -       /project/vm2/sbin/setup-network.sh
aruba-vm chimichangas - /project/aruba-vm/sbin/startstop.sh

Scripts in packages and projects that we regard as secure
(/project/admin , /project/mx , /package/ldap etc.) are not imported.

mxstartups need to be updated to refer to installed scripts instead to
those in the projects. The scripts in the projects should be deleted to
avoid confusion.

Import (some) scripts, which live in projects with user access and are
called from mxstartups, into repository and update install.sh.

The scripts are installed into /usr/libexec/startup/ with a name prefixed
with "prj_PROJECT_".

tor     lassmichmalbittekurznachdenken - /project/tor/sbin/startup.sh

  --> prj_tor_startup.sh

torb    lassmichmalbittekurznachdenken - /project/torb/sbin/startup.sh

  --> prj_torb_startup.sh

Notes:

This is not complete. The following startup scripts still need to be
done separately:

    scinotedocker   ooclhongkong root   /project/scinoteweb/startstop-root.sh
    githubnetwork   elwood -       /project/github2/sbin/setup-github-network.sh
    gitlabnetwork   jake   -       /project/gitlab/sbin/setup-gitlab-network.sh
    overleafnetwork jake   -       /project/overleaf/sbin/setup-overleaf-network.sh
    vpn wtf -   /package/vpn/startstop.sh
    columbus    chimichangas    -   /project/columbus/sbin/startup.sh
    vm2network   chimichangas   -       /project/vm2/sbin/setup-network.sh
    aruba-vm chimichangas - /project/aruba-vm/sbin/startstop.sh

Scripts in packages and projects that we regard as secure
(/project/admin , /project/mx , /package/ldap etc.) are not imported.

mxstartups need to be updated to refer to installed scripts instead to
those in the projects. The scripts in the projects should be deleted to
avoid confusion.
The setting of ulimit in the startup-script is obsolete. The hard limits
are now set via /etc/security/limits.conf. For that to work with
mxstartupctl, `pam_limits.so` has been added to `/etc/pamd.d/su`.

The (unprivileged) startup scripts /project/tor*/bin/startstop.sh` sets
the soft limit for the tor process and fails if unable.

Remove `ulimit` command from script.

Also remove `cd` command from script, which is not needed for startup
and may be surprising if `exec` is used manually.

When `cd` is removed, we also no longer need the brackets for the
subshell, so remove these, too.
@donald donald merged commit 88fed8d into master Jan 17, 2023
Sign in to join this conversation on GitHub.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant