Compare commits
10
Commits
cf60dbcfb8
...
main
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
684f6b1a54 | ||
|
|
b3ec5886e3 | ||
|
|
2dd66df5c4 | ||
|
|
f70ba8ae25 | ||
|
|
5477f97f5d | ||
|
|
fa5b134600 | ||
|
|
20a7f030ef | ||
|
|
70551d1e75 | ||
|
|
d0f9117515 | ||
|
|
b8fb20b4e4 |
No files matched your search
@@ -2,6 +2,8 @@
|
|||||||
|
|
||||||
Part of the Science in the City Festival - Single-participant learning environments for hands-on Co-op Cloud deployment practice.
|
Part of the Science in the City Festival - Single-participant learning environments for hands-on Co-op Cloud deployment practice.
|
||||||
|
|
||||||
|
See the [workshop slides](https://git.dailysh.it/nextlevelshit/malta-slides) for detailed presentation and materials.
|
||||||
|
|
||||||
## 🚀 Quick Start
|
## 🚀 Quick Start
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
@@ -44,7 +46,7 @@ browser wordpress # Open directly in Firefox
|
|||||||
## 💾 USB Environment
|
## 💾 USB Environment
|
||||||
|
|
||||||
Pre-configured with:
|
Pre-configured with:
|
||||||
- **Automatic WiFi connection** to workshop network
|
- **Automatic WiFi connection** to workshop network (CODE_CRISPIES) or public cafe WiFi (APSFreeWiFi)
|
||||||
- Docker Swarm + abra installation
|
- Docker Swarm + abra installation
|
||||||
- SSH client for cloud access
|
- SSH client for cloud access
|
||||||
- Wildcard DNS resolution (dnsmasq)
|
- Wildcard DNS resolution (dnsmasq)
|
||||||
|
|||||||
+38
-45
@@ -267,6 +267,26 @@ isoConfig
|
|||||||
method = "auto";
|
method = "auto";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
"APSFreeWiFi" = {
|
||||||
|
connection = {
|
||||||
|
id = "APSFreeWiFi";
|
||||||
|
type = "wifi";
|
||||||
|
autoconnect = true;
|
||||||
|
};
|
||||||
|
wifi = {
|
||||||
|
mode = "infrastructure";
|
||||||
|
ssid = "APSFreeWiFi";
|
||||||
|
};
|
||||||
|
wifi-security = {
|
||||||
|
key-mgmt = "none";
|
||||||
|
};
|
||||||
|
ipv4 = {
|
||||||
|
method = "auto";
|
||||||
|
};
|
||||||
|
ipv6 = {
|
||||||
|
method = "auto";
|
||||||
|
};
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
@@ -493,8 +513,7 @@ isoConfig
|
|||||||
systemd.services.workshop-abra-install = {
|
systemd.services.workshop-abra-install = {
|
||||||
description = "Install abra CLI system-wide with retry logic and proper verification";
|
description = "Install abra CLI system-wide with retry logic and proper verification";
|
||||||
wantedBy = [ "multi-user.target" ];
|
wantedBy = [ "multi-user.target" ];
|
||||||
after = [ "network-online.target" ];
|
after = [ "workshop-system-setup.service" ];
|
||||||
wants = [ "network-online.target" ];
|
|
||||||
path = with pkgs; [
|
path = with pkgs; [
|
||||||
bash
|
bash
|
||||||
wget
|
wget
|
||||||
@@ -509,36 +528,22 @@ isoConfig
|
|||||||
];
|
];
|
||||||
|
|
||||||
script = ''
|
script = ''
|
||||||
# Enhanced installation with proper verification
|
# Plain abra installation
|
||||||
export TERM=xterm-256color
|
export TERM=xterm-256color
|
||||||
export HOME=/root
|
export HOME=/root
|
||||||
|
|
||||||
# Check if abra is already properly installed (CORRECTED VERIFICATION)
|
# Check if abra is already properly installed
|
||||||
if sudo abra --version >/dev/null 2>&1; then
|
if sudo abra --version >/dev/null 2>&1; then
|
||||||
echo "✅ abra already installed and functional"
|
echo "✅ abra already installed and functional"
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Wait for actual internet connectivity
|
echo "🚀 Installing abra system-wide..."
|
||||||
echo "🌐 Waiting for internet connectivity..."
|
|
||||||
for i in {1..30}; do
|
|
||||||
if curl -s --max-time 5 https://abra.coopcloud.tech >/dev/null 2>&1; then
|
|
||||||
echo "✅ Internet connectivity confirmed"
|
|
||||||
break
|
|
||||||
fi
|
|
||||||
if [ $i -eq 30 ]; then
|
|
||||||
echo "❌ No internet connectivity after 60 seconds"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
sleep 2
|
|
||||||
done
|
|
||||||
|
|
||||||
# Attempt installation with retry logic
|
# Plain installation
|
||||||
for attempt in {1..3}; do
|
curl -fsSL https://install.abra.coopcloud.tech | bash
|
||||||
echo "🚀 Installing abra (attempt $attempt/3)..."
|
|
||||||
|
|
||||||
if curl -fsSL https://install.abra.coopcloud.tech | bash; then
|
# Verify installation
|
||||||
# Verify installation success using CORRECT check method
|
|
||||||
if sudo abra --version >/dev/null 2>&1; then
|
if sudo abra --version >/dev/null 2>&1; then
|
||||||
echo "✅ abra installed successfully"
|
echo "✅ abra installed successfully"
|
||||||
|
|
||||||
@@ -550,28 +555,17 @@ isoConfig
|
|||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
else
|
else
|
||||||
echo "⚠️ Installation script completed but abra not functional"
|
echo "❌ abra installation failed"
|
||||||
fi
|
|
||||||
else
|
|
||||||
echo "❌ Installation attempt $attempt failed"
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ $attempt -lt 3 ]; then
|
|
||||||
echo "⏳ Retrying in 10 seconds..."
|
|
||||||
sleep 10
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
|
|
||||||
echo "❌ abra installation failed after 3 attempts"
|
|
||||||
exit 1
|
exit 1
|
||||||
|
fi
|
||||||
'';
|
'';
|
||||||
|
|
||||||
serviceConfig = {
|
serviceConfig = {
|
||||||
Type = "oneshot";
|
Type = "oneshot";
|
||||||
RemainAfterExit = true;
|
RemainAfterExit = true;
|
||||||
User = "root";
|
|
||||||
Restart = "on-failure";
|
Restart = "on-failure";
|
||||||
RestartSec = "30s";
|
RestartSec = "30s";
|
||||||
|
User = "root";
|
||||||
Environment = [
|
Environment = [
|
||||||
"TERM=xterm-256color"
|
"TERM=xterm-256color"
|
||||||
"HOME=/root"
|
"HOME=/root"
|
||||||
@@ -1208,7 +1202,7 @@ isoConfig
|
|||||||
install() {
|
install() {
|
||||||
echo "🔄 Checking and repairing abra installation..."
|
echo "🔄 Checking and repairing abra installation..."
|
||||||
|
|
||||||
# Use the CORRECT check method (matches service verification)
|
# Check if abra is already installed
|
||||||
if sudo abra --version >/dev/null 2>&1; then
|
if sudo abra --version >/dev/null 2>&1; then
|
||||||
echo "✅ abra is already installed and functional"
|
echo "✅ abra is already installed and functional"
|
||||||
return 0
|
return 0
|
||||||
@@ -1217,18 +1211,17 @@ isoConfig
|
|||||||
echo "🔄 Restarting abra installation service..."
|
echo "🔄 Restarting abra installation service..."
|
||||||
sudo systemctl restart workshop-abra-install
|
sudo systemctl restart workshop-abra-install
|
||||||
|
|
||||||
# Monitor installation progress
|
# Wait for service to complete
|
||||||
echo "📊 Monitoring installation..."
|
sleep 5
|
||||||
for i in {1..30}; do
|
|
||||||
|
# Check if installation succeeded
|
||||||
if sudo abra --version >/dev/null 2>&1; then
|
if sudo abra --version >/dev/null 2>&1; then
|
||||||
echo "✅ abra installation completed successfully!"
|
echo "✅ abra installation completed successfully!"
|
||||||
return 0
|
return 0
|
||||||
fi
|
else
|
||||||
sleep 2
|
echo "❌ Installation failed. Try running 'install' again or check status:"
|
||||||
done
|
|
||||||
|
|
||||||
echo "❌ Installation still not complete. Check status:"
|
|
||||||
echo " sudo systemctl status workshop-abra-install"
|
echo " sudo systemctl status workshop-abra-install"
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
recipes() {
|
recipes() {
|
||||||
|
|||||||
@@ -71,7 +71,7 @@
|
|||||||
## Getting Started Commands
|
## Getting Started Commands
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
# WiFi connects automatically - no manual setup needed!
|
# WiFi connects automatically to CODE_CRISPIES or APSFreeWiFi - no manual setup needed!
|
||||||
# Set up your local environment
|
# Set up your local environment
|
||||||
setup
|
setup
|
||||||
|
|
||||||
@@ -120,7 +120,8 @@ Name: Android, Password: (ask facilitator)
|
|||||||
→ Note: Terminal no longer auto-starts to prevent boot hangs
|
→ Note: Terminal no longer auto-starts to prevent boot hangs
|
||||||
|
|
||||||
**Can't connect to internet**
|
**Can't connect to internet**
|
||||||
→ WiFi should connect automatically to "CODE_CRISPIES"
|
→ WiFi should connect automatically to "CODE_CRISPIES" or "APSFreeWiFi"
|
||||||
|
→ If connecting to APSFreeWiFi, complete browser login when prompted
|
||||||
→ If not, use mobile hotspot as backup
|
→ If not, use mobile hotspot as backup
|
||||||
→ Check: nmcli connection show --active
|
→ Check: nmcli connection show --active
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user