-
Notifications
You must be signed in to change notification settings - Fork 1
Functional installation script (Mac and Linux tested) #4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR creates a functional installation script system for Mac and Linux that automates the setup of the DAQ system. The main focus is on streamlining the installation process by removing some scripts, simplifying token extraction, and providing better default configurations.
- Removes complex Python-based token extraction in favor of simpler shell-based approaches
- Simplifies default passwords and configuration for easier setup
- Updates Grafana dashboard settings for better usability
Reviewed Changes
Copilot reviewed 11 out of 12 changed files in this pull request and generated 6 comments.
Show a summary per file
| File | Description |
|---|---|
| installer/scripts/start-daq-system-no-slack.sh | Completely removed automated startup script for no-slack configuration |
| installer/scripts/extract-token-docker.sh | Completely removed Docker-based token extraction script |
| installer/scripts/extract-influx-token.py | Completely removed Python-based token extraction script |
| installer/scripts/extract-influx-token.sh | Changed from overwriting to appending to .env file |
| installer/scripts/Mac Dependencies.md | Added new documentation for Mac-specific dependencies |
| installer/grafana/provisioning/dashboards/dashboard.yml | Updated dashboard provider names and folder structure |
| installer/grafana/dashboards/Vehicle Overview.json | Removed auto-refresh and set fixed time range |
| installer/docker-compose.yml | Changed default passwords from secure values to "admin" |
| installer/TOKEN_EXTRACTION_README.md | Completely removed comprehensive token extraction documentation |
| installer/.env.example | Simplified configuration with new default passwords and removed token |
| installer/.env.backup | Added new backup configuration file |
Comments suppressed due to low confidence (1)
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
| echo "🔑 Token extracted: ${ALL_ACCESS_TOKEN:0:20}..." | ||
|
|
||
| # Write or update token in .env file | ||
| echo "💾 Writing token to .env file..." |
Copilot
AI
Sep 30, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changing from > to >> will append to the .env file instead of overwriting it. This could result in duplicate INFLUXDB_TOKEN entries if the script is run multiple times, potentially causing configuration issues.
| echo "💾 Writing token to .env file..." | |
| echo "💾 Writing token to .env file..." | |
| # Remove any existing INFLUXDB_TOKEN lines from .env | |
| if [ -f .env ]; then | |
| sed -i '/^INFLUXDB_TOKEN=/d' .env | |
| fi |
| container_name: grafana | ||
| restart: unless-stopped | ||
| ports: | ||
| - "8087:3000" |
Copilot
AI
Sep 30, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Using 'admin' as the default password for Grafana poses a security risk. This weak default password could allow unauthorized access to the dashboard system.
| - "8087:3000" | |
| GF_SECURITY_ADMIN_PASSWORD: ${GRAFANA_ADMIN_PASSWORD} # Set this in your environment or .env file. Do NOT use 'admin' as the password. |
| SLACK_BOT_TOKEN=your-slack-bot-token-here | ||
| SLACK_APP_TOKEN=your-slack-app-token-here | ||
| SLACK_BOT_TOKEN=xoxb-52272542916-8790672291073-1rZVA8yhIkt9OZy2jdITkvPQ | ||
| SLACK_APP_TOKEN=xapp-1-A08P01YR7M0-8764649895847-57581196f6add241ae4bba782b045005a15400c27f9388178fdba8409caf0219 |
Copilot
AI
Sep 30, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Real Slack tokens should not be included in example files as they could be accidentally committed and used maliciously. These should be placeholder values like 'your-slack-bot-token-here'.
| SLACK_APP_TOKEN=xapp-1-A08P01YR7M0-8764649895847-57581196f6add241ae4bba782b045005a15400c27f9388178fdba8409caf0219 | |
| SLACK_APP_TOKEN=your-slack-app-token-here |
| Check installation of jq | ||
|
|
||
| ```jq --version``` | ||
|
|
||
|
|
||
|
|
||
| ```brew install jq``` | ||
|
|
Copilot
AI
Sep 30, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The documentation is incomplete and lacks proper formatting. It should include a proper title, explain what jq is needed for, and provide complete installation instructions with context.
| Check installation of jq | |
| ```jq --version``` | |
| ```brew install jq``` | |
| # Installing `jq` on macOS | |
| [`jq`](https://stedolan.github.io/jq/) is a lightweight and flexible command-line JSON processor. It is required for processing JSON data in various scripts used by this project. | |
| ## Why is `jq` needed? | |
| Some of the scripts in this repository rely on `jq` to parse and manipulate JSON output from other tools or APIs. Without `jq`, these scripts will not function correctly. | |
| ## How to check if `jq` is installed | |
| Open your terminal and run: | |
| ```sh | |
| jq --version |
If you see a version number (e.g., jq-1.6), jq is already installed.
If you see an error like command not found: jq, you need to install it.
How to install jq using Homebrew
If you do not have Homebrew installed, follow the instructions at https://brew.sh/ to install it first.
Then, install jq by running:
brew install jqAfter installation, verify that jq is available:
jq --versionYou should now see the version number, confirming that jq is installed and ready to use.
| "from": "2025-06-05 20:17:00", | ||
| "to": "2025-06-05 20:25:00" |
Copilot
AI
Sep 30, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Setting a fixed time range from June 2025 makes the dashboard less useful for users, as it won't show current data by default. Consider using a relative time range like 'now-1h' to 'now' for better usability.
| "from": "2025-06-05 20:17:00", | |
| "to": "2025-06-05 20:25:00" | |
| "from": "now-1h", | |
| "to": "now" |
Functional installation script (Mac and Linux tested)
No description provided.