generated from geniusdynamics/ns8-kickstart-mariadb
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
1551200
commit ab73fb0
Showing
22 changed files
with
202 additions
and
184 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,4 +5,4 @@ | |
# SPDX-License-Identifier: GPL-3.0-or-later | ||
# | ||
|
||
rm -vf kickstart.sql | ||
rm -vf opensign.archive |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,19 @@ | ||
#!/bin/bash | ||
|
||
# | ||
# Copyright (C) 2022 Nethesis S.r.l. | ||
# SPDX-License-Identifier: GPL-3.0-or-later | ||
#!/bin/bash | ||
|
||
# | ||
# Copyright (C) 2022 Nethesis S.r.l. | ||
# SPDX-License-Identifier: GPL-3.0-or-later | ||
# | ||
|
||
set -e | ||
|
||
if ! systemctl --user -q is-active kickstart.service; then | ||
if ! systemctl --user -q is-active opensign.service; then | ||
exit 0 | ||
fi | ||
|
||
podman exec mariadb-app mysqldump \ | ||
--databases kickstart \ | ||
--default-character-set=utf8mb4 \ | ||
--skip-dump-date \ | ||
--ignore-table=mysql.event \ | ||
--single-transaction \ | ||
--quick \ | ||
--add-drop-table > kickstart.sql | ||
podman exec mongo-app mongodump --archive > opensign.archive |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
# | ||
# Copyright (C) 2022 Nethesis S.r.l. | ||
# SPDX-License-Identifier: GPL-3.0-or-later | ||
# | ||
|
||
[Unit] | ||
Description=Podman mongo-app.service | ||
BindsTo=opensign.service | ||
After=opensign.service | ||
|
||
[Service] | ||
Environment=PODMAN_SYSTEMD_UNIT=%n | ||
EnvironmentFile=%S/state/environment | ||
Restart=always | ||
TimeoutStopSec=70 | ||
ExecStartPre=/bin/rm -f %t/mongo-app.pid %t/mongo-app.ctr-id | ||
ExecStart=/usr/bin/podman run --conmon-pidfile %t/mongo-app.pid \ | ||
--cidfile %t/mongo-app.ctr-id --cgroups=no-conmon \ | ||
--pod-id-file %t/opensign.pod-id --replace -d --name mongo-app \ | ||
--volume mongo-app:/data/db:Z \ | ||
--volume mongo-configdb:/data/configdb:Z \ | ||
${MONGO_IMAGE} | ||
ExecStop=/usr/bin/podman stop --ignore --cidfile %t/mongo-app.ctr-id -t 10 | ||
ExecStopPost=/usr/bin/podman rm --ignore -f --cidfile %t/mongo-app.ctr-id | ||
ExecReload=/usr/bin/podman kill -s HUP mongo-app | ||
SyslogIdentifier=%u | ||
PIDFile=%t/mongo-app.pid | ||
Type=forking | ||
|
||
[Install] | ||
WantedBy=default.target |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# | ||
# Copyright (C) 2022 Nethesis S.r.l. | ||
# SPDX-License-Identifier: GPL-3.0-or-later | ||
# | ||
|
||
[Unit] | ||
Description=Podman opensign-client.service | ||
BindsTo=opensign.service | ||
After=opensign.service mongo-app.service opensign-server.service | ||
|
||
[Service] | ||
Environment=PODMAN_SYSTEMD_UNIT=%n | ||
EnvironmentFile=%S/state/environment | ||
EnvironmentFile=-%S/state/smarthost.env | ||
WorkingDirectory=%S/state | ||
Restart=always | ||
TimeoutStopSec=70 | ||
ExecStartPre=/bin/mkdir -p tmp | ||
ExecStartPre=/bin/rm -f %t/opensign-app.pid %t/opensign-app.ctr-id | ||
ExecStartPre=-runagent discover-smarthost | ||
ExecStart=/usr/bin/podman run --conmon-pidfile %t/opensign-app.pid \ | ||
--cidfile %t/opensign-app.ctr-id --cgroups=no-conmon \ | ||
--pod-id-file %t/opensign.pod-id --replace -d --name opensign-app \ | ||
--volume ./apps/OpenSign/:/usr/app \ | ||
--volume /usr/app/node_modules:z \ | ||
--env=OPENSIGN_* \ | ||
${OPENSIGN_IMAGE} npm star | ||
ExecStop=/usr/bin/podman stop --ignore --cidfile %t/opensign-app.ctr-id -t 10 | ||
ExecReload=/usr/bin/podman kill -s HUP opensign-app | ||
SyslogIdentifier=%u | ||
ExecStopPost=/usr/bin/podman rm --ignore -f --cidfile %t/opensign-app.ctr-id | ||
PIDFile=%t/opensign-app.pid | ||
Type=forking | ||
|
||
[Install] | ||
WantedBy=default.target |
Oops, something went wrong.