Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/libresign/admin_group_manager
Nextcloud admin group manager
https://github.com/libresign/admin_group_manager
hacktoberfest nextcloud nextcloud-app nextcloud-apps
Last synced: 7 days ago
JSON representation
Nextcloud admin group manager
- Host: GitHub
- URL: https://github.com/libresign/admin_group_manager
- Owner: LibreSign
- License: agpl-3.0
- Created: 2024-10-07T15:53:08.000Z (3 months ago)
- Default Branch: main
- Last Pushed: 2024-12-06T19:55:06.000Z (17 days ago)
- Last Synced: 2024-12-13T17:57:23.462Z (10 days ago)
- Topics: hacktoberfest, nextcloud, nextcloud-app, nextcloud-apps
- Language: PHP
- Homepage:
- Size: 117 KB
- Stars: 0
- Watchers: 4
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Funding: .github/FUNDING.yml
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
- Codeowners: .github/CODEOWNERS
Awesome Lists containing this project
README
# Admin group manager
Manage routines associates to admin groups
Available features:
- Create admin group setting the default group quota and enabled apps## Setup
- Clone this repo at your app folder
- Run the follow commands:
```bash
composer install --no-dev
npm ci
npm run build
occ app:enable admin_group_manager
occ app:enable groupquota
```
- Allowed IPBy security, this API only receive requests from a specific IP.
- Run a tail with grep to watch by the word "Unauthorized access".
```bash
tail -f data/nextcloud.log|grep "Unauthorized access"
```
- Do a request to API endpoint and go back to terminal to check the logs and get the IP.
- With the IP, run the follow command:
```bash
occ config:system:set admin_group_manager_allowed_ip --value
```## Performance improving
Systemd service- Create a systemd service file in /etc/systemd/system/admin-group-manager.service with the following content:
```ini
[Unit]
Description=Admin Group Manager worker
After=network.target[Service]
ExecStart=/opt/admin-group-manager/taskprocessing.sh
Restart=always[Install]
WantedBy=multi-user.target
```- Create a shell script in /opt/admin-group-manager/taskprocessing.sh with the following content and make sure to make it executable:
```bash
#!/bin/sh
echo "Starting Admin Group Manager worker $1"
cd /path/to/nextcloud
sudo -u www-data php occ background-job:worker 'OCA\AdminGroupManager\BackgroundJob\EnableAppsForGroup'
```- Enable and start the service:
```bash
systemctl enable --now admin-group-manager.service
```
- Check if is working fine:
```bash
systemctl list-units --type=service | grep admin-group-manager
```
- Check execution log:
```bash
journalctl -xeu nextcloud-ai-worker.service -f
```## How to use
Check the available endpoints installing the app `ocs_api_viewer` and going to Nextcloud web interface at ocs_api_viewer app to verify the endpoints of this app.