mirror of
https://github.com/community-scripts/ProxmoxVE.git
synced 2025-11-04 18:32:51 +00:00
Compare commits
47 Commits
2025-02-27
...
2025-03-03
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
712ff6f5cc | ||
|
|
f80bc3c09a | ||
|
|
7c5efad1ca | ||
|
|
d0edd224ca | ||
|
|
6c5ef63375 | ||
|
|
402420e159 | ||
|
|
af302d62f3 | ||
|
|
bedb908682 | ||
|
|
9bf30de4cb | ||
|
|
9302e2e27d | ||
|
|
6ab8815b3b | ||
|
|
4baae014ab | ||
|
|
d000c35ff5 | ||
|
|
9570c9199a | ||
|
|
705ad208d7 | ||
|
|
6e3367c4e7 | ||
|
|
71d8da316a | ||
|
|
ba990514c4 | ||
|
|
0ae7f3b445 | ||
|
|
307b49fee6 | ||
|
|
6a940716f0 | ||
|
|
53b30e5f15 | ||
|
|
134741f681 | ||
|
|
9ef77cfd3f | ||
|
|
01e8f413ea | ||
|
|
6aa2057202 | ||
|
|
4583158cf5 | ||
|
|
48b14f7347 | ||
|
|
623e1896aa | ||
|
|
e29652c8dd | ||
|
|
6d0fe3e2ee | ||
|
|
f25f13e789 | ||
|
|
4101618556 | ||
|
|
5f30084c6f | ||
|
|
4c266aeb42 | ||
|
|
00794c41e6 | ||
|
|
f1cdfecaaf | ||
|
|
c738615bf2 | ||
|
|
8af885a0f3 | ||
|
|
62cdb5c0c2 | ||
|
|
843c4f8c1e | ||
|
|
d82c9a24a7 | ||
|
|
b24860c97b | ||
|
|
e8e298581c | ||
|
|
05769fdff1 | ||
|
|
5c5c628954 | ||
|
|
10f4172349 |
68
.github/runner/docker/gh-runner-self.dockerfile
vendored
Normal file
68
.github/runner/docker/gh-runner-self.dockerfile
vendored
Normal file
@@ -0,0 +1,68 @@
|
|||||||
|
FROM mcr.microsoft.com/dotnet/runtime-deps:8.0-jammy as build
|
||||||
|
|
||||||
|
ARG TARGETOS
|
||||||
|
ARG TARGETARCH
|
||||||
|
ARG DOCKER_VERSION=27.5.1
|
||||||
|
ARG BUILDX_VERSION=0.20.1
|
||||||
|
ARG RUNNER_ARCH="x64"
|
||||||
|
|
||||||
|
RUN apt update -y && apt install sudo curl unzip -y
|
||||||
|
|
||||||
|
WORKDIR /actions-runner
|
||||||
|
|
||||||
|
RUN RUNNER_VERSION=$(curl -s https://api.github.com/repos/actions/runner/releases/latest | grep "tag_name" | head -n 1 | awk '{print substr($2, 3, length($2)-4)}') \
|
||||||
|
&& curl -f -L -o runner.tar.gz https://github.com/actions/runner/releases/download/v${RUNNER_VERSION}/actions-runner-linux-${RUNNER_ARCH}-${RUNNER_VERSION}.tar.gz \
|
||||||
|
&& tar xzf ./runner.tar.gz \
|
||||||
|
&& rm runner.tar.gz
|
||||||
|
|
||||||
|
RUN RUNNER_CONTAINER_HOOKS_VERSION=$(curl -s https://api.github.com/repos/actions/runner-container-hooks/releases/latest | grep "tag_name" | head -n 1 | awk '{print substr($2, 3, length($2)-4)}') \
|
||||||
|
&& curl -f -L -o runner-container-hooks.zip https://github.com/actions/runner-container-hooks/releases/download/v${RUNNER_CONTAINER_HOOKS_VERSION}/actions-runner-hooks-k8s-${RUNNER_CONTAINER_HOOKS_VERSION}.zip \
|
||||||
|
&& unzip ./runner-container-hooks.zip -d ./k8s \
|
||||||
|
&& rm runner-container-hooks.zip
|
||||||
|
|
||||||
|
RUN export RUNNER_ARCH=${TARGETARCH} \
|
||||||
|
&& if [ "$RUNNER_ARCH" = "amd64" ]; then export DOCKER_ARCH=x86_64 ; fi \
|
||||||
|
&& if [ "$RUNNER_ARCH" = "arm64" ]; then export DOCKER_ARCH=aarch64 ; fi \
|
||||||
|
&& curl -fLo docker.tgz https://download.docker.com/${TARGETOS}/static/stable/${DOCKER_ARCH}/docker-${DOCKER_VERSION}.tgz \
|
||||||
|
&& tar zxvf docker.tgz \
|
||||||
|
&& rm -rf docker.tgz \
|
||||||
|
&& mkdir -p /usr/local/lib/docker/cli-plugins \
|
||||||
|
&& curl -fLo /usr/local/lib/docker/cli-plugins/docker-buildx \
|
||||||
|
"https://github.com/docker/buildx/releases/download/v${BUILDX_VERSION}/buildx-v${BUILDX_VERSION}.linux-${TARGETARCH}" \
|
||||||
|
&& chmod +x /usr/local/lib/docker/cli-plugins/docker-buildx
|
||||||
|
|
||||||
|
FROM mcr.microsoft.com/dotnet/runtime-deps:8.0-jammy
|
||||||
|
|
||||||
|
ENV DEBIAN_FRONTEND=noninteractive
|
||||||
|
ENV RUNNER_MANUALLY_TRAP_SIG=1
|
||||||
|
ENV ACTIONS_RUNNER_PRINT_LOG_TO_STDOUT=1
|
||||||
|
ENV ImageOS=ubuntu22
|
||||||
|
|
||||||
|
RUN apt update -y \
|
||||||
|
&& apt install -y --no-install-recommends sudo lsb-release gpg-agent software-properties-common curl jq unzip \
|
||||||
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
|
RUN add-apt-repository ppa:git-core/ppa \
|
||||||
|
&& apt update -y \
|
||||||
|
&& apt install -y git \
|
||||||
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
|
RUN adduser --disabled-password --gecos "" --uid 1001 runner \
|
||||||
|
&& groupadd docker --gid 123 \
|
||||||
|
&& usermod -aG sudo runner \
|
||||||
|
&& usermod -aG docker runner \
|
||||||
|
&& echo "%sudo ALL=(ALL:ALL) NOPASSWD:ALL" > /etc/sudoers \
|
||||||
|
&& echo "Defaults env_keep += \"DEBIAN_FRONTEND\"" >> /etc/sudoers
|
||||||
|
|
||||||
|
# Install own dependencies in final image
|
||||||
|
RUN curl -fsSL https://deb.nodesource.com/setup_22.x | bash - \
|
||||||
|
&& apt-get install -y nodejs \
|
||||||
|
&& apt-get install -y gh jq git
|
||||||
|
|
||||||
|
WORKDIR /home/runner
|
||||||
|
|
||||||
|
COPY --chown=runner:docker --from=build /actions-runner .
|
||||||
|
COPY --from=build /usr/local/lib/docker/cli-plugins/docker-buildx /usr/local/lib/docker/cli-plugins/docker-buildx
|
||||||
|
RUN install -o root -g root -m 755 docker/* /usr/bin/ && rm -rf docker
|
||||||
|
|
||||||
|
USER runner
|
||||||
@@ -10,7 +10,7 @@ on:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
update-app-files:
|
update-app-files:
|
||||||
runs-on: ubuntu-latest
|
runs-on: runner-cluster-htl-set
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
contents: write
|
contents: write
|
||||||
|
|||||||
2
.github/workflows/autolabeler.yml
vendored
2
.github/workflows/autolabeler.yml
vendored
@@ -7,7 +7,7 @@ on:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
autolabeler:
|
autolabeler:
|
||||||
runs-on: ubuntu-latest
|
runs-on: runner-cluster-htl-set
|
||||||
permissions:
|
permissions:
|
||||||
pull-requests: write
|
pull-requests: write
|
||||||
env:
|
env:
|
||||||
|
|||||||
2
.github/workflows/changelog-pr.yml
vendored
2
.github/workflows/changelog-pr.yml
vendored
@@ -7,7 +7,7 @@ on:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
update-changelog-pull-request:
|
update-changelog-pull-request:
|
||||||
runs-on: ubuntu-latest
|
runs-on: runner-cluster-htl-set
|
||||||
env:
|
env:
|
||||||
CONFIG_PATH: .github/changelog-pr-config.json
|
CONFIG_PATH: .github/changelog-pr-config.json
|
||||||
BRANCH_NAME: github-action-update-changelog
|
BRANCH_NAME: github-action-update-changelog
|
||||||
|
|||||||
2
.github/workflows/close-discussion.yml
vendored
2
.github/workflows/close-discussion.yml
vendored
@@ -6,7 +6,7 @@ on:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
close-discussion:
|
close-discussion:
|
||||||
runs-on: ubuntu-latest
|
runs-on: runner-cluster-htl-set
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout Repository
|
- name: Checkout Repository
|
||||||
|
|||||||
37
.github/workflows/create-docker-for-runner.yml
vendored
Normal file
37
.github/workflows/create-docker-for-runner.yml
vendored
Normal file
@@ -0,0 +1,37 @@
|
|||||||
|
name: Build and Publish Docker Image
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
|
paths:
|
||||||
|
- '.github/runner/docker/**'
|
||||||
|
schedule:
|
||||||
|
- cron: '0 0 * * *'
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
runs-on: ubuntu-latest #To ensure it always builds we use the github runner with all the right tooling
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Checkout code
|
||||||
|
uses: actions/checkout@v3
|
||||||
|
|
||||||
|
- name: Log in to GHCR
|
||||||
|
uses: docker/login-action@v2
|
||||||
|
with:
|
||||||
|
registry: ghcr.io
|
||||||
|
username: ${{ github.actor }}
|
||||||
|
password: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
|
- name: Build Docker image
|
||||||
|
run: |
|
||||||
|
repo_name=${{ github.repository }} # Get repository name
|
||||||
|
repo_name_lower=$(echo $repo_name | tr '[:upper:]' '[:lower:]') # Convert to lowercase
|
||||||
|
docker build -t ghcr.io/$repo_name_lower/gh-runner-self:latest -f .github/runner/docker/gh-runner-self.dockerfile .
|
||||||
|
|
||||||
|
- name: Push Docker image to GHCR
|
||||||
|
run: |
|
||||||
|
repo_name=${{ github.repository }} # Get repository name
|
||||||
|
repo_name_lower=$(echo $repo_name | tr '[:upper:]' '[:lower:]') # Convert to lowercase
|
||||||
|
docker push ghcr.io/$repo_name_lower/gh-runner-self:latest
|
||||||
2
.github/workflows/delete-json-branch.yml
vendored
2
.github/workflows/delete-json-branch.yml
vendored
@@ -9,7 +9,7 @@ on:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
delete_branch:
|
delete_branch:
|
||||||
runs-on: ubuntu-latest
|
runs-on: runner-cluster-htl-set
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout the code
|
- name: Checkout the code
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
|
|||||||
2
.github/workflows/frontend-cicd.yml
vendored
2
.github/workflows/frontend-cicd.yml
vendored
@@ -27,7 +27,7 @@ concurrency:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
runs-on: ubuntu-latest
|
runs-on: runner-cluster-htl-set
|
||||||
defaults:
|
defaults:
|
||||||
run:
|
run:
|
||||||
working-directory: frontend # Set default working directory for all run steps
|
working-directory: frontend # Set default working directory for all run steps
|
||||||
|
|||||||
54
.github/workflows/github-release.yml
vendored
54
.github/workflows/github-release.yml
vendored
@@ -1,25 +1,57 @@
|
|||||||
name: Create new release
|
name: Create Daily Release
|
||||||
|
|
||||||
on:
|
on:
|
||||||
schedule:
|
schedule:
|
||||||
# Runs "At 00:01 every night" (UTC)
|
- cron: '1 0 * * *' # Runs daily at 00:01 UTC
|
||||||
- cron: '1 0 * * *'
|
workflow_dispatch:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
create-new-release:
|
create-daily-release:
|
||||||
runs-on: ubuntu-latest
|
runs-on: runner-cluster-htl-set
|
||||||
permissions:
|
permissions:
|
||||||
contents: write
|
contents: write
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout code
|
- name: Checkout repository
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
- name: Parse CHANGELOG.md for yesterday's entries and create a new release
|
|
||||||
|
- name: Extract first 5000 characters from CHANGELOG.md
|
||||||
|
run: head -c 5000 CHANGELOG.md > changelog_cropped.md
|
||||||
|
|
||||||
|
- name: Debugging - Show extracted changelog
|
||||||
|
run: |
|
||||||
|
echo "=== CHANGELOG EXCERPT ==="
|
||||||
|
cat changelog_cropped.md
|
||||||
|
echo "========================="
|
||||||
|
|
||||||
|
- name: Parse CHANGELOG.md and create release
|
||||||
env:
|
env:
|
||||||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
run: |
|
run: |
|
||||||
YESTERDAY=$(date -u --date="yesterday" +%Y-%m-%d)
|
YESTERDAY=$(date -u --date="yesterday" +%Y-%m-%d)
|
||||||
YESTERDAY_CHANGELOG_NOTES=$(awk '/^## '"$YESTERDAY"'/ {f=1; next} f && /^## [0-9]{4}-[0-9]{2}-[0-9]{2}/ {f=0} f && !/^## / {print}' CHANGELOG.md)
|
echo "Checking for changes on: $YESTERDAY"
|
||||||
|
|
||||||
if [ -n "$YESTERDAY_CHANGELOG_NOTES" ]; then
|
# Ensure yesterday's date exists in the changelog
|
||||||
gh release create "$YESTERDAY" -t "$YESTERDAY" -n "$YESTERDAY_CHANGELOG_NOTES" --latest
|
if ! grep -q "## $YESTERDAY" changelog_cropped.md; then
|
||||||
|
echo "No entry found for $YESTERDAY, skipping release."
|
||||||
|
exit 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Extract section for yesterday's date
|
||||||
|
awk -v date="## $YESTERDAY" '
|
||||||
|
$0 ~ date {found=1; next}
|
||||||
|
found && /^## [0-9]{4}-[0-9]{2}-[0-9]{2}/ {exit}
|
||||||
|
found
|
||||||
|
' changelog_cropped.md > changelog_tmp.md
|
||||||
|
|
||||||
|
echo "=== Extracted Changelog ==="
|
||||||
|
cat changelog_tmp.md
|
||||||
|
echo "==========================="
|
||||||
|
|
||||||
|
# Skip if no content was found
|
||||||
|
if [ ! -s changelog_tmp.md ]; then
|
||||||
|
echo "No changes found for $YESTERDAY, skipping release."
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Create GitHub release
|
||||||
|
gh release create "$YESTERDAY" -t "$YESTERDAY" -F changelog_tmp.md
|
||||||
|
|||||||
34
.github/workflows/script-test.yml
vendored
34
.github/workflows/script-test.yml
vendored
@@ -140,34 +140,38 @@ jobs:
|
|||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
|
|
||||||
- name: Post error comments
|
- name: Post error comments
|
||||||
run: |
|
run: |
|
||||||
ERROR="false"
|
ERROR="false"
|
||||||
SEARCH_LINE=".github/workflows/scripts/app-test/pr-build.func: line 255"
|
SEARCH_LINE=".github/workflows/scripts/app-test/pr-build.func: line 255:"
|
||||||
|
|
||||||
|
# Get all existing comments on the PR
|
||||||
|
EXISTING_COMMENTS=$(gh pr view ${{ github.event.pull_request.number }} --repo ${{ github.repository }} --json comments --jq '.comments[].body')
|
||||||
|
|
||||||
for FILE in ${{ env.ALL_FILES }}; do
|
for FILE in ${{ env.ALL_FILES }}; do
|
||||||
STRIPPED_NAME=$(basename "$FILE" | sed 's/-install//' | sed 's/\.sh$//')
|
STRIPPED_NAME=$(basename "$FILE" | sed 's/-install//' | sed 's/\.sh$//')
|
||||||
if [[ ! -f result_$STRIPPED_NAME.log ]]; then
|
if [[ ! -f result_$STRIPPED_NAME.log ]]; then
|
||||||
continue
|
continue
|
||||||
fi
|
fi
|
||||||
ERROR_MSG=$(cat result_$STRIPPED_NAME.log)
|
ERROR_MSG=$(cat result_$STRIPPED_NAME.log)
|
||||||
|
|
||||||
if [ -n "$ERROR_MSG" ]; then
|
if [ -n "$ERROR_MSG" ]; then
|
||||||
CLEANED_ERROR_MSG=$(echo "$ERROR_MSG" | sed "s|$SEARCH_LINE.*||")
|
CLEANED_ERROR_MSG=$(echo "$ERROR_MSG" | sed "s|$SEARCH_LINE.*||")
|
||||||
echo "Posting error message for $FILE"
|
COMMENT_BODY=":warning: The script _**$FILE**_ failed with the following message: <br> <div><strong>${CLEANED_ERROR_MSG}</strong></div>"
|
||||||
echo ${CLEANED_ERROR_MSG}
|
|
||||||
gh pr comment ${{ github.event.pull_request.number }} \
|
# Check if the comment already exists
|
||||||
--repo ${{ github.repository }} \
|
if echo "$EXISTING_COMMENTS" | grep -qF "$COMMENT_BODY"; then
|
||||||
--body ":warning: The script _**$FILE**_ failed with the following message: <br> <div><strong>${CLEANED_ERROR_MSG}</strong></div>"
|
echo "Skipping duplicate comment for $FILE"
|
||||||
ERROR="true"
|
else
|
||||||
|
echo "Posting error message for $FILE"
|
||||||
|
gh pr comment ${{ github.event.pull_request.number }} \
|
||||||
|
--repo ${{ github.repository }} \
|
||||||
|
--body "$COMMENT_BODY"
|
||||||
|
ERROR="true"
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
echo "ERROR=$ERROR" >> $GITHUB_ENV
|
echo "ERROR=$ERROR" >> $GITHUB_ENV
|
||||||
env:
|
|
||||||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
|
|
||||||
- name: Fail if error
|
|
||||||
if: ${{ env.ERROR == 'true' }}
|
|
||||||
run: exit 1
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
243
.github/workflows/script_format.yml
vendored
Normal file
243
.github/workflows/script_format.yml
vendored
Normal file
@@ -0,0 +1,243 @@
|
|||||||
|
name: Script Format Check
|
||||||
|
permissions:
|
||||||
|
pull-requests: write
|
||||||
|
on:
|
||||||
|
pull_request_target:
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
|
paths:
|
||||||
|
- 'install/*.sh'
|
||||||
|
- 'ct/*.sh'
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
run-install-script:
|
||||||
|
runs-on: pvenode
|
||||||
|
steps:
|
||||||
|
- name: Checkout PR branch (supports forks)
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
ref: ${{ github.event.pull_request.head.ref }}
|
||||||
|
repository: ${{ github.event.pull_request.head.repo.full_name }}
|
||||||
|
fetch-depth: 0
|
||||||
|
|
||||||
|
- name: Add Git safe directory
|
||||||
|
run: |
|
||||||
|
git config --global --add safe.directory /__w/ProxmoxVE/ProxmoxVE
|
||||||
|
|
||||||
|
- name: Set up GH_TOKEN
|
||||||
|
env:
|
||||||
|
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
run: |
|
||||||
|
echo "GH_TOKEN=${GH_TOKEN}" >> $GITHUB_ENV
|
||||||
|
|
||||||
|
- name: Get Changed Files
|
||||||
|
run: |
|
||||||
|
CHANGED_FILES=$(gh pr diff ${{ github.event.pull_request.number }} --repo ${{ github.repository }} --name-only)
|
||||||
|
CHANGED_FILES=$(echo "$CHANGED_FILES" | tr '\n' ' ')
|
||||||
|
echo "Changed files: $CHANGED_FILES"
|
||||||
|
echo "SCRIPT=$CHANGED_FILES" >> $GITHUB_ENV
|
||||||
|
env:
|
||||||
|
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
|
- name: Check scripts
|
||||||
|
id: run-install
|
||||||
|
continue-on-error: true
|
||||||
|
run: |
|
||||||
|
for FILE in ${{ env.SCRIPT }}; do
|
||||||
|
STRIPPED_NAME=$(basename "$FILE" | sed 's/-install//' | sed 's/\.sh$//')
|
||||||
|
echo "Running Test for: $STRIPPED_NAME"
|
||||||
|
FILE_STRIPPED="${FILE##*/}"
|
||||||
|
LOG_FILE="result_$FILE_STRIPPED.log"
|
||||||
|
|
||||||
|
if [[ $FILE =~ ^ct/.*\.sh$ ]]; then
|
||||||
|
|
||||||
|
FIRST_LINE=$(sed -n '1p' "$FILE")
|
||||||
|
[[ "$FIRST_LINE" != "#!/usr/bin/env bash" ]] && echo "Line 1 was $FIRST_LINE | Should be: #!/usr/bin/env bash" >> "$LOG_FILE"
|
||||||
|
SECOND_LINE=$(sed -n '2p' "$FILE")
|
||||||
|
[[ "$SECOND_LINE" != "source <(curl -s https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/build.func)" ]] &&
|
||||||
|
echo "Line 2 was $SECOND_LINE | Should be: source <(curl -s https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/build.func)" >> "$LOG_FILE"
|
||||||
|
THIRD_LINE=$(sed -n '3p' "$FILE")
|
||||||
|
if ! [[ "$THIRD_LINE" =~ ^#\ Copyright\ \(c\)\ [0-9]{4}-[0-9]{4}\ community-scripts\ ORG$ || "$THIRD_LINE" =~ ^Copyright\ \(c\)\ [0-9]{4}-[0-9]{4}\ tteck$ ]]; then
|
||||||
|
echo "Line 3 was $THIRD_LINE | Should be: # Copyright (c) 2021-2025 community-scripts ORG" >> "$LOG_FILE"
|
||||||
|
fi
|
||||||
|
|
||||||
|
EXPECTED_AUTHOR="# Author:"
|
||||||
|
EXPECTED_LICENSE="# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE"
|
||||||
|
EXPECTED_SOURCE="# Source:"
|
||||||
|
EXPECTED_EMPTY=""
|
||||||
|
|
||||||
|
for i in {4..7}; do
|
||||||
|
LINE=$(sed -n "${i}p" "$FILE")
|
||||||
|
|
||||||
|
case $i in
|
||||||
|
4)
|
||||||
|
[[ $LINE == $EXPECTED_AUTHOR* ]] || printf "Line %d was: '%s' | Should start with: '%s'\n" "$i" "$LINE" "$EXPECTED_AUTHOR" >> $LOG_FILE
|
||||||
|
;;
|
||||||
|
5)
|
||||||
|
[[ "$LINE" == "$EXPECTED_LICENSE" ]] || printf "Line %d was: '%s' | Should be: '%s'\n" "$i" "$LINE" "$EXPECTED_LICENSE" >> $LOG_FILE
|
||||||
|
;;
|
||||||
|
6)
|
||||||
|
[[ $LINE == $EXPECTED_SOURCE* ]] || printf "Line %d was: '%s' | Should start with: '%s'\n" "$i" "$LINE" "$EXPECTED_SOURCE" >> $LOG_FILE
|
||||||
|
;;
|
||||||
|
7)
|
||||||
|
[[ -z $LINE ]] || printf "Line %d was: '%s' | Should be empty\n" "$i" "$LINE" >> $LOG_FILE
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
|
||||||
|
|
||||||
|
EXPECTED_PREFIXES=(
|
||||||
|
"APP="
|
||||||
|
"var_tags="
|
||||||
|
"var_cpu=" # Must be a number
|
||||||
|
"var_ram=" # Must be a number
|
||||||
|
"var_disk=" # Must be a number
|
||||||
|
"var_os=" # Must be debian, alpine, or ubuntu
|
||||||
|
"var_version="
|
||||||
|
"var_unprivileged=" # Must be 0 or 1
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
|
for i in {8..15}; do
|
||||||
|
LINE=$(sed -n "${i}p" "$FILE")
|
||||||
|
INDEX=$((i - 8))
|
||||||
|
|
||||||
|
case $INDEX in
|
||||||
|
2|3|4) # var_cpu, var_ram, var_disk (must be numbers)
|
||||||
|
if [[ "$LINE" =~ ^${EXPECTED_PREFIXES[$INDEX]}([0-9]+)$ ]]; then
|
||||||
|
continue # Valid
|
||||||
|
else
|
||||||
|
echo "Line $i was '$LINE' | Should be: '${EXPECTED_PREFIXES[$INDEX]}<NUMBER>'" >> "$LOG_FILE"
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
5) # var_os (must be debian, alpine, or ubuntu)
|
||||||
|
if [[ "$LINE" =~ ^var_os=(debian|alpine|ubuntu)$ ]]; then
|
||||||
|
continue # Valid
|
||||||
|
else
|
||||||
|
echo "Line $i was '$LINE' | Should be: 'var_os=[debian|alpine|ubuntu]'" >> "$LOG_FILE"
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
7) # var_unprivileged (must be 0 or 1)
|
||||||
|
if [[ "$LINE" =~ ^var_unprivileged=[01]$ ]]; then
|
||||||
|
continue # Valid
|
||||||
|
else
|
||||||
|
echo "Line $i was '$LINE' | Should be: 'var_unprivileged=[0|1]'" >> "$LOG_FILE"
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
*) # Other lines (must start with expected prefix)
|
||||||
|
if [[ "$LINE" == ${EXPECTED_PREFIXES[$INDEX]}* ]]; then
|
||||||
|
continue # Valid
|
||||||
|
else
|
||||||
|
echo "Line $i was '$LINE' | Should start with '${EXPECTED_PREFIXES[$INDEX]}'" >> "$LOG_FILE"
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
|
||||||
|
for i in {16..20}; do
|
||||||
|
LINE=$(sed -n "${i}p" "$FILE")
|
||||||
|
EXPECTED=(
|
||||||
|
"header_info \"$APP\""
|
||||||
|
"variables"
|
||||||
|
"color"
|
||||||
|
"catch_errors"
|
||||||
|
"function update_script() {"
|
||||||
|
)
|
||||||
|
[[ "$LINE" != "${EXPECTED[$((i-16))]}" ]] && echo "Line $i was $LINE | Should be: ${EXPECTED[$((i-16))]}" >> "$LOG_FILE"
|
||||||
|
done
|
||||||
|
cat "$LOG_FILE"
|
||||||
|
elif [[ $FILE =~ ^install/.*-install\.sh$ ]]; then
|
||||||
|
|
||||||
|
FIRST_LINE=$(sed -n '1p' "$FILE")
|
||||||
|
[[ "$FIRST_LINE" != "#!/usr/bin/env bash" ]] && echo "Line 1 was $FIRST_LINE | Should be: #!/usr/bin/env bash" >> "$LOG_FILE"
|
||||||
|
|
||||||
|
SECOND_LINE=$(sed -n '2p' "$FILE")
|
||||||
|
[[ -n "$SECOND_LINE" ]] && echo "Line 2 should be empty" >> "$LOG_FILE"
|
||||||
|
|
||||||
|
THIRD_LINE=$(sed -n '3p' "$FILE")
|
||||||
|
if ! [[ "$THIRD_LINE" =~ ^#\ Copyright\ \(c\)\ [0-9]{4}-[0-9]{4}\ community-scripts\ ORG$ || "$THIRD_LINE" =~ ^Copyright\ \(c\)\ [0-9]{4}-[0-9]{4}\ tteck$ ]]; then
|
||||||
|
echo "Line 3 was $THIRD_LINE | Should be: # Copyright (c) 2021-2025 community-scripts ORG" >> "$LOG_FILE"
|
||||||
|
fi
|
||||||
|
|
||||||
|
EXPECTED_AUTHOR="# Author:"
|
||||||
|
EXPECTED_LICENSE="# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE"
|
||||||
|
EXPECTED_SOURCE="# Source:"
|
||||||
|
EXPECTED_EMPTY=""
|
||||||
|
|
||||||
|
for i in {4..7}; do
|
||||||
|
LINE=$(sed -n "${i}p" "$FILE")
|
||||||
|
|
||||||
|
case $i in
|
||||||
|
4)
|
||||||
|
[[ $LINE == $EXPECTED_AUTHOR* ]] || printf "Line %d was: '%s' | Should start with: '%s'\n" "$i" "$LINE" "$EXPECTED_AUTHOR" >> $LOG_FILE
|
||||||
|
;;
|
||||||
|
5)
|
||||||
|
[[ "$LINE" == "$EXPECTED_LICENSE" ]] || printf "Line %d was: '%s' | Should be: '%s'\n" "$i" "$LINE" "$EXPECTED_LICENSE" >> $LOG_FILE
|
||||||
|
;;
|
||||||
|
6)
|
||||||
|
[[ $LINE == $EXPECTED_SOURCE* ]] || printf "Line %d was: '%s' | Should start with: '%s'\n" "$i" "$LINE" "$EXPECTED_SOURCE" >> $LOG_FILE
|
||||||
|
;;
|
||||||
|
7)
|
||||||
|
[[ -z $LINE ]] || printf "Line %d was: '%s' | Should be empty\n" "$i" "$LINE" >> $LOG_FILE
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
|
||||||
|
[[ "$(sed -n '8p' "$FILE")" != 'source /dev/stdin <<< "$FUNCTIONS_FILE_PATH"' ]] && echo 'Line 8 should be: source /dev/stdin <<< "$FUNCTIONS_FILE_PATH"' >> "$LOG_FILE"
|
||||||
|
|
||||||
|
for i in {9..14}; do
|
||||||
|
LINE=$(sed -n "${i}p" "$FILE")
|
||||||
|
EXPECTED=(
|
||||||
|
"color"
|
||||||
|
"verb_ip6"
|
||||||
|
"catch_errors"
|
||||||
|
"setting_up_container"
|
||||||
|
"network_check"
|
||||||
|
"update_os"
|
||||||
|
)
|
||||||
|
[[ "$LINE" != "${EXPECTED[$((i-9))]}" ]] && echo "Line $i was $LINE | Should be: ${EXPECTED[$((i-9))]}" >> "$LOG_FILE"
|
||||||
|
done
|
||||||
|
|
||||||
|
[[ -n "$(sed -n '15p' "$FILE")" ]] && echo "Line 15 should be empty" >> "$LOG_FILE"
|
||||||
|
[[ "$(sed -n '16p' "$FILE")" != 'msg_info "Installing Dependencies"' ]] && echo 'Line 16 should be: msg_info "Installing Dependencies"' >> "$LOG_FILE"
|
||||||
|
|
||||||
|
LAST_3_LINES=$(tail -n 3 "$FILE")
|
||||||
|
[[ "$LAST_3_LINES" != *"$STD apt-get -y autoremove"* ]] && echo 'Third to last line should be: $STD apt-get -y autoremove' >> "$LOG_FILE"
|
||||||
|
[[ "$LAST_3_LINES" != *"$STD apt-get -y autoclean"* ]] && echo 'Second to last line should be: $STD apt-get -y clean' >> "$LOG_FILE"
|
||||||
|
[[ "$LAST_3_LINES" != *'msg_ok "Cleaned"'* ]] && echo 'Last line should be: msg_ok "Cleaned"' >> "$LOG_FILE"
|
||||||
|
cat "$LOG_FILE"
|
||||||
|
fi
|
||||||
|
|
||||||
|
done
|
||||||
|
|
||||||
|
|
||||||
|
- name: Post error comments
|
||||||
|
run: |
|
||||||
|
ERROR="false"
|
||||||
|
for FILE in ${{ env.SCRIPT }}; do
|
||||||
|
FILE_STRIPPED="${FILE##*/}"
|
||||||
|
LOG_FILE="result_$FILE_STRIPPED.log"
|
||||||
|
echo $LOG_FILE
|
||||||
|
if [[ ! -f $LOG_FILE ]]; then
|
||||||
|
continue
|
||||||
|
fi
|
||||||
|
ERROR_MSG=$(cat $LOG_FILE)
|
||||||
|
|
||||||
|
if [ -n "$ERROR_MSG" ]; then
|
||||||
|
echo "Posting error message for $FILE"
|
||||||
|
echo ${ERROR_MSG}
|
||||||
|
gh pr comment ${{ github.event.pull_request.number }} \
|
||||||
|
--repo ${{ github.repository }} \
|
||||||
|
--body ":warning: The script _**$FILE**_ has the following formatting errors: <br> <div><strong>${ERROR_MSG}</strong></div>"
|
||||||
|
|
||||||
|
|
||||||
|
ERROR="true"
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
echo "ERROR=$ERROR" >> $GITHUB_ENV
|
||||||
|
env:
|
||||||
|
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
|
- name: Fail if error
|
||||||
|
if: ${{ env.ERROR == 'true' }}
|
||||||
|
run: exit 1
|
||||||
2
.github/workflows/update-json-date.yml
vendored
2
.github/workflows/update-json-date.yml
vendored
@@ -10,7 +10,7 @@ on:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
update-app-files:
|
update-app-files:
|
||||||
runs-on: ubuntu-latest
|
runs-on: runner-cluster-htl-set
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
contents: write
|
contents: write
|
||||||
|
|||||||
2
.github/workflows/validate-filenames.yml
vendored
2
.github/workflows/validate-filenames.yml
vendored
@@ -10,7 +10,7 @@ on:
|
|||||||
jobs:
|
jobs:
|
||||||
check-files:
|
check-files:
|
||||||
name: Check changed files
|
name: Check changed files
|
||||||
runs-on: ubuntu-latest
|
runs-on: runner-cluster-htl-set
|
||||||
permissions:
|
permissions:
|
||||||
pull-requests: write
|
pull-requests: write
|
||||||
|
|
||||||
|
|||||||
74
CHANGELOG.md
74
CHANGELOG.md
@@ -13,9 +13,79 @@ Exercise vigilance regarding copycat or coat-tailing sites that seek to exploit
|
|||||||
> [!NOTE]
|
> [!NOTE]
|
||||||
All LXC instances created using this repository come pre-installed with Midnight Commander, which is a command-line tool (`mc`) that offers a user-friendly file and directory management interface for the terminal environment.
|
All LXC instances created using this repository come pre-installed with Midnight Commander, which is a command-line tool (`mc`) that offers a user-friendly file and directory management interface for the terminal environment.
|
||||||
|
|
||||||
> [!IMPORTANT]
|
|
||||||
Do not break established syntax in this file, as it is automatically updated by a Github Workflow
|
|
||||||
|
|
||||||
|
## 2025-03-03
|
||||||
|
|
||||||
|
### 🆕 New Scripts
|
||||||
|
|
||||||
|
- Habitica [@tremor021](https://github.com/tremor021) ([#2779](https://github.com/community-scripts/ProxmoxVE/pull/2779))
|
||||||
|
|
||||||
|
### 🚀 Updated Scripts
|
||||||
|
|
||||||
|
- #### 🐞 Bug Fixes
|
||||||
|
|
||||||
|
- Zigbee2Mqtt Use fixed pnpm Version 10.4.1 [@MickLesk](https://github.com/MickLesk) ([#2805](https://github.com/community-scripts/ProxmoxVE/pull/2805))
|
||||||
|
- Linkwarden: Fix & Update Monolith-Installation [@MickLesk](https://github.com/MickLesk) ([#2787](https://github.com/community-scripts/ProxmoxVE/pull/2787))
|
||||||
|
|
||||||
|
- #### ✨ New Features
|
||||||
|
|
||||||
|
- Feature: MinIO use now static port 9001 [@MickLesk](https://github.com/MickLesk) ([#2786](https://github.com/community-scripts/ProxmoxVE/pull/2786))
|
||||||
|
- Feature Template Path for Mountings [@MickLesk](https://github.com/MickLesk) ([#2785](https://github.com/community-scripts/ProxmoxVE/pull/2785))
|
||||||
|
|
||||||
|
### 🌐 Website
|
||||||
|
|
||||||
|
- #### ✨ New Features
|
||||||
|
|
||||||
|
- Feature: Website - show default OS [@MickLesk](https://github.com/MickLesk) ([#2790](https://github.com/community-scripts/ProxmoxVE/pull/2790))
|
||||||
|
|
||||||
|
- #### 📝 Script Information
|
||||||
|
|
||||||
|
- Update zigbee2mqtt.json - make sure link is clickable [@gurtjun](https://github.com/gurtjun) ([#2802](https://github.com/community-scripts/ProxmoxVE/pull/2802))
|
||||||
|
|
||||||
|
## 2025-03-02
|
||||||
|
|
||||||
|
### 🚀 Updated Scripts
|
||||||
|
|
||||||
|
- #### 🐞 Bug Fixes
|
||||||
|
|
||||||
|
- Fix gpg Repo for nzbget [@flatlinebb](https://github.com/flatlinebb) ([#2774](https://github.com/community-scripts/ProxmoxVE/pull/2774))
|
||||||
|
|
||||||
|
## 2025-03-01
|
||||||
|
|
||||||
|
### 🚀 Updated Scripts
|
||||||
|
|
||||||
|
- #### 🐞 Bug Fixes
|
||||||
|
|
||||||
|
- Firefly III: FIx Ownership for OAuth Key [@michelroegl-brunner](https://github.com/michelroegl-brunner) ([#2759](https://github.com/community-scripts/ProxmoxVE/pull/2759))
|
||||||
|
- homarr: double restart to fix homarr migration [@CrazyWolf13](https://github.com/CrazyWolf13) ([#2757](https://github.com/community-scripts/ProxmoxVE/pull/2757))
|
||||||
|
|
||||||
|
- #### ✨ New Features
|
||||||
|
|
||||||
|
- ActualBudget: New Installation Script with new Repo [@MickLesk](https://github.com/MickLesk) ([#2770](https://github.com/community-scripts/ProxmoxVE/pull/2770))
|
||||||
|
|
||||||
|
- #### 💥 Breaking Changes
|
||||||
|
|
||||||
|
- Breaking: Remove Update Function for Actual Budget until it fixed [@MickLesk](https://github.com/MickLesk) ([#2768](https://github.com/community-scripts/ProxmoxVE/pull/2768))
|
||||||
|
|
||||||
|
### 🧰 Maintenance
|
||||||
|
|
||||||
|
- #### 🐞 Bug Fixes
|
||||||
|
|
||||||
|
- Remove Note on Changelog [@MickLesk](https://github.com/MickLesk) ([#2758](https://github.com/community-scripts/ProxmoxVE/pull/2758))
|
||||||
|
- Fix Release Creation if Changelog.md to long [@MickLesk](https://github.com/MickLesk) ([#2752](https://github.com/community-scripts/ProxmoxVE/pull/2752))
|
||||||
|
|
||||||
|
## 2025-02-28
|
||||||
|
|
||||||
|
### 🧰 Maintenance
|
||||||
|
|
||||||
|
- #### ✨ New Features
|
||||||
|
|
||||||
|
- Shell Format Workflow [@michelroegl-brunner](https://github.com/michelroegl-brunner) ([#2400](https://github.com/community-scripts/ProxmoxVE/pull/2400))
|
||||||
|
|
||||||
|
- #### 📂 Github
|
||||||
|
|
||||||
|
- Update all Action to new selfhosted Runner Cluster [@michelroegl-brunner](https://github.com/michelroegl-brunner) ([#2739](https://github.com/community-scripts/ProxmoxVE/pull/2739))
|
||||||
|
- Update Script Test Workflow [@michelroegl-brunner](https://github.com/michelroegl-brunner) ([#2741](https://github.com/community-scripts/ProxmoxVE/pull/2741))
|
||||||
|
|
||||||
## 2025-02-27
|
## 2025-02-27
|
||||||
|
|
||||||
|
|||||||
@@ -28,89 +28,8 @@ function update_script() {
|
|||||||
msg_error "No ${APP} Installation Found!"
|
msg_error "No ${APP} Installation Found!"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
msg_error "Due to major changes in the Actual Budget repository, we are currently unable to provide updates. Please check back later."
|
||||||
RELEASE=$(curl -s https://api.github.com/repos/actualbudget/actual/releases/latest | \
|
exit
|
||||||
grep "tag_name" | awk -F '"' '{print substr($4, 2)}')
|
|
||||||
|
|
||||||
if [[ ! -f /opt/actualbudget_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/actualbudget_version.txt)" ]]; then
|
|
||||||
msg_info "Stopping ${APP}"
|
|
||||||
systemctl stop actualbudget
|
|
||||||
msg_ok "${APP} Stopped"
|
|
||||||
|
|
||||||
msg_info "Updating ${APP} to ${RELEASE}"
|
|
||||||
cd /tmp
|
|
||||||
wget -q "https://github.com/actualbudget/actual-server/archive/refs/tags/v${RELEASE}.tar.gz"
|
|
||||||
|
|
||||||
mv /opt/actualbudget /opt/actualbudget_bak
|
|
||||||
$STD tar -xzf "v${RELEASE}.tar.gz"
|
|
||||||
mv *ctual-server-* /opt/actualbudget
|
|
||||||
|
|
||||||
mkdir -p /opt/actualbudget-data/{server-files,upload,migrate,user-files,migrations,config}
|
|
||||||
for dir in server-files .migrate user-files migrations; do
|
|
||||||
if [[ -d /opt/actualbudget_bak/$dir ]]; then
|
|
||||||
mv /opt/actualbudget_bak/$dir/* /opt/actualbudget-data/$dir/ || true
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
if [[ -f /opt/actualbudget-data/migrate/.migrations ]]; then
|
|
||||||
sed -i 's/null/1732656575219/g' /opt/actualbudget-data/migrate/.migrations
|
|
||||||
sed -i 's/null/1732656575220/g' /opt/actualbudget-data/migrate/.migrations
|
|
||||||
fi
|
|
||||||
if [[ -f /opt/actualbudget/server-files/account.sqlite ]] && [[ ! -f /opt/actualbudget-data/server-files/account.sqlite ]]; then
|
|
||||||
mv /opt/actualbudget/server-files/account.sqlite /opt/actualbudget-data/server-files/account.sqlite
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [[ -f /opt/actualbudget_bak/.env ]]; then
|
|
||||||
mv /opt/actualbudget_bak/.env /opt/actualbudget-data/.env
|
|
||||||
else
|
|
||||||
cat <<EOF > /opt/actualbudget-data/.env
|
|
||||||
ACTUAL_UPLOAD_DIR=/opt/actualbudget-data/upload
|
|
||||||
ACTUAL_DATA_DIR=/opt/actualbudget-data
|
|
||||||
ACTUAL_SERVER_FILES_DIR=/opt/actualbudget-data/server-files
|
|
||||||
ACTUAL_USER_FILES=/opt/actualbudget-data/user-files
|
|
||||||
PORT=5006
|
|
||||||
ACTUAL_TRUSTED_PROXIES="10.0.0.0/8,172.16.0.0/12,192.168.0.0/16,127.0.0.1/32,::1/128,fc00::/7"
|
|
||||||
ACTUAL_HTTPS_KEY=/opt/actualbudget/selfhost.key
|
|
||||||
ACTUAL_HTTPS_CERT=/opt/actualbudget/selfhost.crt
|
|
||||||
EOF
|
|
||||||
fi
|
|
||||||
cd /opt/actualbudget
|
|
||||||
$STD yarn install
|
|
||||||
echo "${RELEASE}" > /opt/actualbudget_version.txt
|
|
||||||
msg_ok "Updated ${APP}"
|
|
||||||
|
|
||||||
msg_info "Starting ${APP}"
|
|
||||||
cat <<EOF > /etc/systemd/system/actualbudget.service
|
|
||||||
[Unit]
|
|
||||||
Description=Actual Budget Service
|
|
||||||
After=network.target
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
Type=simple
|
|
||||||
User=root
|
|
||||||
Group=root
|
|
||||||
WorkingDirectory=/opt/actualbudget
|
|
||||||
EnvironmentFile=/opt/actualbudget-data/.env
|
|
||||||
ExecStart=/usr/bin/yarn start
|
|
||||||
Restart=always
|
|
||||||
RestartSec=10
|
|
||||||
|
|
||||||
[Install]
|
|
||||||
WantedBy=multi-user.target
|
|
||||||
EOF
|
|
||||||
|
|
||||||
systemctl daemon-reload
|
|
||||||
systemctl start actualbudget
|
|
||||||
msg_ok "Started ${APP}"
|
|
||||||
|
|
||||||
msg_info "Cleaning Up"
|
|
||||||
rm -rf /opt/actualbudget_bak
|
|
||||||
rm -rf "/tmp/v${RELEASE}.tar.gz"
|
|
||||||
msg_ok "Cleaned"
|
|
||||||
msg_ok "Updated Successfully"
|
|
||||||
else
|
|
||||||
msg_ok "No update required. ${APP} is already at ${RELEASE}"
|
|
||||||
fi
|
|
||||||
exit 0
|
|
||||||
}
|
}
|
||||||
|
|
||||||
start
|
start
|
||||||
|
|||||||
@@ -221,7 +221,8 @@ mapfile -t TEMPLATES < <(pveam available -section system | sed -n "s/.*\($TEMPLA
|
|||||||
exit 207
|
exit 207
|
||||||
}
|
}
|
||||||
TEMPLATE="${TEMPLATES[-1]}"
|
TEMPLATE="${TEMPLATES[-1]}"
|
||||||
TEMPLATE_PATH="/var/lib/vz/template/cache/$TEMPLATE"
|
TEMPLATE_PATH="$(pvesm path $TEMPLATE_STORAGE:vztmpl/$TEMPLATE)"
|
||||||
|
# Without NAS/Mount: TEMPLATE_PATH="/var/lib/vz/template/cache/$TEMPLATE"
|
||||||
# Check if template exists, if corrupt remove and redownload
|
# Check if template exists, if corrupt remove and redownload
|
||||||
if ! pveam list "$TEMPLATE_STORAGE" | grep -q "$TEMPLATE" || ! zstdcat "$TEMPLATE_PATH" | tar -tf - >/dev/null 2>&1; then
|
if ! pveam list "$TEMPLATE_STORAGE" | grep -q "$TEMPLATE" || ! zstdcat "$TEMPLATE_PATH" | tar -tf - >/dev/null 2>&1; then
|
||||||
msg_warn "Template $TEMPLATE not found in storage or seems to be corrupted. Redownloading."
|
msg_warn "Template $TEMPLATE not found in storage or seems to be corrupted. Redownloading."
|
||||||
|
|||||||
74
ct/habitica.sh
Normal file
74
ct/habitica.sh
Normal file
@@ -0,0 +1,74 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
source <(curl -s https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/build.func)
|
||||||
|
# Copyright (c) 2021-2025 community-scripts ORG
|
||||||
|
# Author: Slaviša Arežina (tremor021)
|
||||||
|
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||||
|
# Source: https://github.com/HabitRPG/habitica
|
||||||
|
|
||||||
|
APP="Habitica"
|
||||||
|
var_tags="gaming"
|
||||||
|
var_cpu="2"
|
||||||
|
var_ram="4096"
|
||||||
|
var_disk="8"
|
||||||
|
var_os="debian"
|
||||||
|
var_version="12"
|
||||||
|
var_unprivileged="1"
|
||||||
|
|
||||||
|
header_info "$APP"
|
||||||
|
variables
|
||||||
|
color
|
||||||
|
catch_errors
|
||||||
|
|
||||||
|
function update_script() {
|
||||||
|
header_info
|
||||||
|
check_container_storage
|
||||||
|
check_container_resources
|
||||||
|
|
||||||
|
if [[ ! -d "/opt/habitica" ]]; then
|
||||||
|
msg_error "No ${APP} Installation Found!"
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
RELEASE=$(curl -s https://api.github.com/repos/HabitRPG/habitica/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }')
|
||||||
|
if [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]] || [[ ! -f /opt/${APP}_version.txt ]]; then
|
||||||
|
msg_info "Stopping $APP"
|
||||||
|
systemctl stop habitica-mongodb
|
||||||
|
systemctl stop habitica
|
||||||
|
systemctl stop habitica-client
|
||||||
|
msg_ok "Stopped $APP"
|
||||||
|
|
||||||
|
msg_info "Updating $APP to ${RELEASE}"
|
||||||
|
temp_file=$(mktemp)
|
||||||
|
wget -q "https://github.com/HabitRPG/habitica/archive/refs/tags/v${RELEASE}.tar.gz" -O $temp_file
|
||||||
|
tar zxf $temp_file
|
||||||
|
cp -rf habitica-${RELEASE}/* /opt/habitica
|
||||||
|
cd /opt/habitica
|
||||||
|
$STD npm i
|
||||||
|
echo "${RELEASE}" >/opt/${APP}_version.txt
|
||||||
|
msg_ok "Updated $APP to ${RELEASE}"
|
||||||
|
|
||||||
|
msg_info "Starting $APP"
|
||||||
|
systemctl start habitica-mongodb
|
||||||
|
systemctl start habitica
|
||||||
|
systemctl start habitica-client
|
||||||
|
msg_ok "Started $APP"
|
||||||
|
|
||||||
|
msg_info "Cleaning Up"
|
||||||
|
rm -f $temp_file
|
||||||
|
rm -rf ~/habitica-${RELEASE}
|
||||||
|
msg_ok "Cleanup Completed"
|
||||||
|
|
||||||
|
msg_ok "Update Successful"
|
||||||
|
else
|
||||||
|
msg_ok "No update required. ${APP} is already at ${RELEASE}"
|
||||||
|
fi
|
||||||
|
exit
|
||||||
|
}
|
||||||
|
|
||||||
|
start
|
||||||
|
build_container
|
||||||
|
description
|
||||||
|
|
||||||
|
msg_ok "Completed Successfully!\n"
|
||||||
|
echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}"
|
||||||
|
echo -e "${INFO}${YW} Access it using the following URL:${CL}"
|
||||||
|
echo -e "${TAB}${GATEWAY}${BGN}http://${IP}:8080${CL}"
|
||||||
6
ct/headers/habitica
Normal file
6
ct/headers/habitica
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
__ __ __ _ __ _
|
||||||
|
/ / / /___ _/ /_ (_) /_(_)________ _
|
||||||
|
/ /_/ / __ `/ __ \/ / __/ / ___/ __ `/
|
||||||
|
/ __ / /_/ / /_/ / / /_/ / /__/ /_/ /
|
||||||
|
/_/ /_/\__,_/_.___/_/\__/_/\___/\__,_/
|
||||||
|
|
||||||
@@ -148,6 +148,7 @@ EOF
|
|||||||
|
|
||||||
msg_info "Starting Services"
|
msg_info "Starting Services"
|
||||||
systemctl start homarr
|
systemctl start homarr
|
||||||
|
systemctl restart homarr
|
||||||
msg_ok "Started Services"
|
msg_ok "Started Services"
|
||||||
msg_ok "Updated Successfully"
|
msg_ok "Updated Successfully"
|
||||||
else
|
else
|
||||||
|
|||||||
@@ -32,6 +32,15 @@ function update_script() {
|
|||||||
systemctl stop linkwarden
|
systemctl stop linkwarden
|
||||||
msg_ok "Stopped ${APP}"
|
msg_ok "Stopped ${APP}"
|
||||||
|
|
||||||
|
msg_info "Updating Rust"
|
||||||
|
$STD apt-get install -y build-essential
|
||||||
|
$STD curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
|
||||||
|
source $HOME/.cargo/env
|
||||||
|
echo 'export PATH=/usr/local/cargo/bin:$PATH' >> /etc/profile
|
||||||
|
source /etc/profile
|
||||||
|
$STD cargo install monolith
|
||||||
|
msg_ok "Updated Rust"
|
||||||
|
|
||||||
msg_info "Updating ${APP} to ${RELEASE}"
|
msg_info "Updating ${APP} to ${RELEASE}"
|
||||||
cd /opt
|
cd /opt
|
||||||
mv /opt/linkwarden/.env /opt/.env
|
mv /opt/linkwarden/.env /opt/.env
|
||||||
|
|||||||
@@ -37,7 +37,8 @@ function update_script() {
|
|||||||
cd /opt
|
cd /opt
|
||||||
rm -rf /opt/vikunja/vikunja
|
rm -rf /opt/vikunja/vikunja
|
||||||
wget -q "https://dl.vikunja.io/vikunja/$RELEASE/vikunja-$RELEASE-amd64.deb"
|
wget -q "https://dl.vikunja.io/vikunja/$RELEASE/vikunja-$RELEASE-amd64.deb"
|
||||||
$STD DEBIAN_FRONTEND=noninteractive dpkg -i vikunja-$RELEASE-amd64.deb
|
export DEBIAN_FRONTEND=noninteractive
|
||||||
|
$STD dpkg -i vikunja-$RELEASE-amd64.deb
|
||||||
echo "${RELEASE}" >/opt/${APP}_version.txt
|
echo "${RELEASE}" >/opt/${APP}_version.txt
|
||||||
msg_ok "Updated ${APP}"
|
msg_ok "Updated ${APP}"
|
||||||
|
|
||||||
|
|||||||
@@ -33,6 +33,10 @@ function update_script() {
|
|||||||
systemctl stop zigbee2mqtt
|
systemctl stop zigbee2mqtt
|
||||||
msg_ok "Stopped Service"
|
msg_ok "Stopped Service"
|
||||||
|
|
||||||
|
msg_info "Updating pnpm"
|
||||||
|
$STD npm install -g pnpm@10.4.1
|
||||||
|
msg_ok "Updated pnpm"
|
||||||
|
|
||||||
msg_info "Creating Backup"
|
msg_info "Creating Backup"
|
||||||
rm -rf /opt/${APP}_backup*.tar.gz
|
rm -rf /opt/${APP}_backup*.tar.gz
|
||||||
mkdir -p /opt/z2m_backup
|
mkdir -p /opt/z2m_backup
|
||||||
|
|||||||
@@ -28,6 +28,10 @@ function ScriptItem({
|
|||||||
setSelectedScript(null);
|
setSelectedScript(null);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
const defaultInstallMethod = item.install_methods?.[0];
|
||||||
|
const os = defaultInstallMethod?.resources?.os || "Proxmox Node";
|
||||||
|
const version = defaultInstallMethod?.resources?.version || "";
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="mr-7 mt-0 flex w-full min-w-fit">
|
<div className="mr-7 mt-0 flex w-full min-w-fit">
|
||||||
<div className="flex w-full min-w-fit">
|
<div className="flex w-full min-w-fit">
|
||||||
@@ -60,6 +64,9 @@ function ScriptItem({
|
|||||||
<p className="w-full text-sm text-muted-foreground">
|
<p className="w-full text-sm text-muted-foreground">
|
||||||
Date added: {extractDate(item.date_created)}
|
Date added: {extractDate(item.date_created)}
|
||||||
</p>
|
</p>
|
||||||
|
<p className="text-sm text-muted-foreground">
|
||||||
|
Default OS: {os} {version}
|
||||||
|
</p>
|
||||||
</div>
|
</div>
|
||||||
<div className="flex gap-5">
|
<div className="flex gap-5">
|
||||||
<DefaultSettings item={item} />
|
<DefaultSettings item={item} />
|
||||||
|
|||||||
@@ -1,14 +1,23 @@
|
|||||||
import { Button } from "@/components/ui/button";
|
import { Button } from "@/components/ui/button";
|
||||||
import { basePath } from "@/config/siteConfig";
|
import { basePath } from "@/config/siteConfig";
|
||||||
import { Script } from "@/lib/types";
|
import { Script } from "@/lib/types";
|
||||||
import { BookOpenText, Code, Globe } from "lucide-react";
|
import { BookOpenText, Code, Globe, RefreshCcw } from "lucide-react";
|
||||||
import Link from "next/link";
|
import Link from "next/link";
|
||||||
|
|
||||||
|
const generateInstallSourceUrl = (slug: string) => {
|
||||||
|
const baseUrl = `https://raw.githubusercontent.com/community-scripts/${basePath}/main`;
|
||||||
|
return `${baseUrl}/install/${slug}-install.sh`;
|
||||||
|
};
|
||||||
|
|
||||||
const generateSourceUrl = (slug: string, type: string) => {
|
const generateSourceUrl = (slug: string, type: string) => {
|
||||||
const baseUrl = `https://raw.githubusercontent.com/community-scripts/${basePath}/main`;
|
const baseUrl = `https://raw.githubusercontent.com/community-scripts/${basePath}/main`;
|
||||||
return type === "ct"
|
return type === "vm" ? `${baseUrl}/vm/${slug}.sh` : `${baseUrl}/misc/${slug}.sh`;
|
||||||
? `${baseUrl}/install/${slug}-install.sh`
|
return `${baseUrl}/misc/${slug}.sh`;
|
||||||
: `${baseUrl}/${type}/${slug}.sh`;
|
};
|
||||||
|
|
||||||
|
const generateUpdateUrl = (slug: string) => {
|
||||||
|
const baseUrl = `https://raw.githubusercontent.com/community-scripts/${basePath}/main`;
|
||||||
|
return `${baseUrl}/ct/${slug}.sh`;
|
||||||
};
|
};
|
||||||
|
|
||||||
interface ButtonLinkProps {
|
interface ButtonLinkProps {
|
||||||
@@ -29,20 +38,35 @@ const ButtonLink = ({ href, icon, text }: ButtonLinkProps) => (
|
|||||||
);
|
);
|
||||||
|
|
||||||
export default function Buttons({ item }: { item: Script }) {
|
export default function Buttons({ item }: { item: Script }) {
|
||||||
|
const isCtOrDefault = ["ct"].includes(item.type);
|
||||||
|
const installSourceUrl = isCtOrDefault ? generateInstallSourceUrl(item.slug) : null;
|
||||||
|
const updateSourceUrl = isCtOrDefault ? generateUpdateUrl(item.slug) : null;
|
||||||
|
const sourceUrl = !isCtOrDefault ? generateSourceUrl(item.slug, item.type) : null;
|
||||||
|
|
||||||
const buttons = [
|
const buttons = [
|
||||||
item.website && {
|
item.website && {
|
||||||
href: item.website,
|
href: item.website,
|
||||||
icon: <Globe className="h-4 w-4" />,
|
icon: <Globe className="h-4 w-4" />,
|
||||||
text: "Website",
|
text: "Website",
|
||||||
},
|
},
|
||||||
item.documentation && {
|
item.documentation && {
|
||||||
href: item.documentation,
|
href: item.documentation,
|
||||||
icon: <BookOpenText className="h-4 w-4" />,
|
icon: <BookOpenText className="h-4 w-4" />,
|
||||||
text: "Documentation",
|
text: "Documentation",
|
||||||
},
|
},
|
||||||
{
|
installSourceUrl && {
|
||||||
href: generateSourceUrl(item.slug, item.type),
|
href: installSourceUrl,
|
||||||
icon: <Code className="h-4 w-4" />,
|
icon: <Code className="h-4 w-4" />,
|
||||||
|
text: "Install-Source",
|
||||||
|
},
|
||||||
|
updateSourceUrl && {
|
||||||
|
href: updateSourceUrl,
|
||||||
|
icon: <RefreshCcw className="h-4 w-4" />,
|
||||||
|
text: "Update-Source",
|
||||||
|
},
|
||||||
|
sourceUrl && {
|
||||||
|
href: sourceUrl,
|
||||||
|
icon: <Code className="h-4 w-4" />,
|
||||||
text: "Source Code",
|
text: "Source Code",
|
||||||
},
|
},
|
||||||
].filter(Boolean) as ButtonLinkProps[];
|
].filter(Boolean) as ButtonLinkProps[];
|
||||||
|
|||||||
@@ -38,9 +38,9 @@ msg_ok "Installed Node.js"
|
|||||||
msg_info "Installing Actual Budget"
|
msg_info "Installing Actual Budget"
|
||||||
cd /opt
|
cd /opt
|
||||||
RELEASE=$(curl -s https://api.github.com/repos/actualbudget/actual/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }')
|
RELEASE=$(curl -s https://api.github.com/repos/actualbudget/actual/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }')
|
||||||
wget -q https://github.com/actualbudget/actual-server/archive/refs/tags/v${RELEASE}.tar.gz
|
wget -q https://github.com/actualbudget/actual/archive/refs/tags/v${RELEASE}.tar.gz
|
||||||
tar -xzf v${RELEASE}.tar.gz
|
tar -xzf v${RELEASE}.tar.gz
|
||||||
mv *ctual-server-* /opt/actualbudget
|
mv actual-${RELEASE} /opt/actualbudget
|
||||||
|
|
||||||
mkdir -p /opt/actualbudget-data/{server-files,upload,migrate,user-files,migrations,config}
|
mkdir -p /opt/actualbudget-data/{server-files,upload,migrate,user-files,migrations,config}
|
||||||
chown -R root:root /opt/actualbudget-data
|
chown -R root:root /opt/actualbudget-data
|
||||||
@@ -57,7 +57,7 @@ ACTUAL_HTTPS_KEY=/opt/actualbudget/selfhost.key
|
|||||||
ACTUAL_HTTPS_CERT=/opt/actualbudget/selfhost.crt
|
ACTUAL_HTTPS_CERT=/opt/actualbudget/selfhost.crt
|
||||||
EOF
|
EOF
|
||||||
cd /opt/actualbudget
|
cd /opt/actualbudget
|
||||||
$STD yarn install
|
$STD yarn workspaces focus @actual-app/sync-server --production
|
||||||
$STD openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout selfhost.key -out selfhost.crt <<EOF
|
$STD openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout selfhost.key -out selfhost.crt <<EOF
|
||||||
US
|
US
|
||||||
California
|
California
|
||||||
@@ -82,14 +82,14 @@ User=root
|
|||||||
Group=root
|
Group=root
|
||||||
WorkingDirectory=/opt/actualbudget
|
WorkingDirectory=/opt/actualbudget
|
||||||
EnvironmentFile=/opt/actualbudget-data/.env
|
EnvironmentFile=/opt/actualbudget-data/.env
|
||||||
ExecStart=/usr/bin/yarn start
|
ExecStart=/usr/bin/yarn start:server
|
||||||
Restart=always
|
Restart=always
|
||||||
RestartSec=10
|
RestartSec=10
|
||||||
|
|
||||||
[Install]
|
[Install]
|
||||||
WantedBy=multi-user.target
|
WantedBy=multi-user.target
|
||||||
EOF
|
EOF
|
||||||
systemctl enable -q --now actualbudget.service
|
systemctl enable -q --now actualbudget
|
||||||
msg_ok "Created Service"
|
msg_ok "Created Service"
|
||||||
|
|
||||||
motd_ssh
|
motd_ssh
|
||||||
|
|||||||
@@ -84,6 +84,7 @@ cat <<EOF >/etc/apache2/sites-available/firefly.conf
|
|||||||
|
|
||||||
</VirtualHost>
|
</VirtualHost>
|
||||||
EOF
|
EOF
|
||||||
|
chown www-data:www-data /opt/firefly/storage/oauth-*.key
|
||||||
$STD a2enmod php8.4
|
$STD a2enmod php8.4
|
||||||
$STD a2enmod rewrite
|
$STD a2enmod rewrite
|
||||||
$STD a2ensite firefly.conf
|
$STD a2ensite firefly.conf
|
||||||
|
|||||||
110
install/habitica-install.sh
Normal file
110
install/habitica-install.sh
Normal file
@@ -0,0 +1,110 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# Copyright (c) 2021-2025 community-scripts ORG
|
||||||
|
# Author: Slaviša Arežina (tremor021)
|
||||||
|
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||||
|
# Source: https://github.com/HabitRPG/habitica
|
||||||
|
|
||||||
|
source /dev/stdin <<<"$FUNCTIONS_FILE_PATH"
|
||||||
|
color
|
||||||
|
verb_ip6
|
||||||
|
catch_errors
|
||||||
|
setting_up_container
|
||||||
|
network_check
|
||||||
|
update_os
|
||||||
|
|
||||||
|
msg_info "Installing Dependencies"
|
||||||
|
$STD apt-get install -y \
|
||||||
|
curl \
|
||||||
|
sudo \
|
||||||
|
mc \
|
||||||
|
libkrb5-dev \
|
||||||
|
gnupg \
|
||||||
|
build-essential \
|
||||||
|
git
|
||||||
|
wget -q http://archive.ubuntu.com/ubuntu/pool/main/o/openssl/libssl1.1_1.1.1f-1ubuntu2_amd64.deb
|
||||||
|
$STD dpkg -i libssl1.1_1.1.1f-1ubuntu2_amd64.deb
|
||||||
|
msg_ok "Installed Dependencies"
|
||||||
|
|
||||||
|
msg_info "Setting up Node.js Repository"
|
||||||
|
mkdir -p /etc/apt/keyrings
|
||||||
|
curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg
|
||||||
|
echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_20.x nodistro main" >/etc/apt/sources.list.d/nodesource.list
|
||||||
|
msg_ok "Set up Node.js Repository"
|
||||||
|
|
||||||
|
msg_info "Setup Node.js"
|
||||||
|
$STD apt-get update
|
||||||
|
$STD apt-get install -y nodejs
|
||||||
|
msg_ok "Setup Node.js"
|
||||||
|
|
||||||
|
msg_info "Setup ${APPLICATION}"
|
||||||
|
temp_file=$(mktemp)
|
||||||
|
RELEASE=$(curl -s https://api.github.com/repos/HabitRPG/habitica/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }')
|
||||||
|
wget -q "https://github.com/HabitRPG/habitica/archive/refs/tags/v${RELEASE}.tar.gz" -O $temp_file
|
||||||
|
tar zxf $temp_file
|
||||||
|
mv habitica-${RELEASE}/ /opt/habitica
|
||||||
|
cd /opt/habitica
|
||||||
|
$STD npm i
|
||||||
|
cp config.json.example config.json
|
||||||
|
echo "${RELEASE}" >/opt/${APPLICATION}_version.txt
|
||||||
|
msg_ok "Setup ${APPLICATION}"
|
||||||
|
|
||||||
|
msg_info "Creating Service"
|
||||||
|
cat <<EOF >/etc/systemd/system/habitica-mongodb.service
|
||||||
|
[Unit]
|
||||||
|
Description=Habitica MongoDB Service
|
||||||
|
After=network.target
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
Type=simple
|
||||||
|
User=root
|
||||||
|
WorkingDirectory=/opt/habitica
|
||||||
|
ExecStart=/usr/bin/npm run mongo:dev
|
||||||
|
Restart=always
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
||||||
|
EOF
|
||||||
|
cat <<EOF >/etc/systemd/system/habitica.service
|
||||||
|
[Unit]
|
||||||
|
Description=Habitica Service
|
||||||
|
After=habitica-mongodb.service
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
Type=simple
|
||||||
|
User=root
|
||||||
|
WorkingDirectory=/opt/habitica
|
||||||
|
ExecStart=/usr/bin/npm start
|
||||||
|
Restart=always
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
||||||
|
EOF
|
||||||
|
cat <<EOF >/etc/systemd/system/habitica-client.service
|
||||||
|
[Unit]
|
||||||
|
Description=Habitica Client Service
|
||||||
|
After=habitica.service
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
Type=simple
|
||||||
|
User=root
|
||||||
|
WorkingDirectory=/opt/habitica
|
||||||
|
ExecStart=/usr/bin/npm run client:dev
|
||||||
|
Restart=always
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
||||||
|
EOF
|
||||||
|
systemctl enable -q --now habitica-mongodb
|
||||||
|
systemctl enable -q --now habitica
|
||||||
|
systemctl enable -q --now habitica-client
|
||||||
|
msg_ok "Created Service"
|
||||||
|
|
||||||
|
motd_ssh
|
||||||
|
customize
|
||||||
|
|
||||||
|
msg_info "Cleaning up"
|
||||||
|
rm -f $temp_file
|
||||||
|
$STD apt-get -y autoremove
|
||||||
|
$STD apt-get -y autoclean
|
||||||
|
msg_ok "Cleaned"
|
||||||
@@ -20,7 +20,9 @@ $STD apt-get install -y \
|
|||||||
sudo \
|
sudo \
|
||||||
mc \
|
mc \
|
||||||
make \
|
make \
|
||||||
|
git \
|
||||||
postgresql \
|
postgresql \
|
||||||
|
build-essential \
|
||||||
cargo \
|
cargo \
|
||||||
gnupg
|
gnupg
|
||||||
msg_ok "Installed Dependencies"
|
msg_ok "Installed Dependencies"
|
||||||
@@ -37,10 +39,13 @@ $STD apt-get install -y nodejs
|
|||||||
$STD npm install -g yarn
|
$STD npm install -g yarn
|
||||||
msg_ok "Installed Node.js/Yarn"
|
msg_ok "Installed Node.js/Yarn"
|
||||||
|
|
||||||
msg_info "Installing Monolith"
|
msg_info "Installing Rust"
|
||||||
|
$STD curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
|
||||||
|
source $HOME/.cargo/env
|
||||||
|
echo 'export PATH=/usr/local/cargo/bin:$PATH' >> /etc/profile
|
||||||
|
source /etc/profile
|
||||||
$STD cargo install monolith
|
$STD cargo install monolith
|
||||||
export PATH=~/.cargo/bin:$PATH
|
msg_ok "Installed Rust"
|
||||||
msg_ok "Installed Monolith"
|
|
||||||
|
|
||||||
msg_info "Setting up PostgreSQL DB"
|
msg_info "Setting up PostgreSQL DB"
|
||||||
DB_NAME=linkwardendb
|
DB_NAME=linkwardendb
|
||||||
|
|||||||
@@ -57,7 +57,7 @@ After=network-online.target
|
|||||||
User=minio-user
|
User=minio-user
|
||||||
Group=minio-user
|
Group=minio-user
|
||||||
EnvironmentFile=-/etc/default/minio
|
EnvironmentFile=-/etc/default/minio
|
||||||
ExecStart=/usr/local/bin/minio server /data
|
ExecStart=/usr/local/bin/minio server --console-address ":9001" /data
|
||||||
Restart=always
|
Restart=always
|
||||||
RestartSec=5
|
RestartSec=5
|
||||||
LimitNOFILE=65536
|
LimitNOFILE=65536
|
||||||
@@ -74,4 +74,4 @@ customize
|
|||||||
msg_info "Cleaning up"
|
msg_info "Cleaning up"
|
||||||
$STD apt-get -y autoremove
|
$STD apt-get -y autoremove
|
||||||
$STD apt-get -y autoclean
|
$STD apt-get -y autoclean
|
||||||
msg_ok "Cleaned"
|
msg_ok "Cleaned"
|
||||||
|
|||||||
@@ -31,7 +31,7 @@ msg_ok "Installed Dependencies"
|
|||||||
msg_info "Installing NZBGet"
|
msg_info "Installing NZBGet"
|
||||||
mkdir -p /etc/apt/keyrings
|
mkdir -p /etc/apt/keyrings
|
||||||
curl -fsSL https://nzbgetcom.github.io/nzbgetcom.asc | gpg --dearmor -o /etc/apt/keyrings/nzbgetcom.gpg
|
curl -fsSL https://nzbgetcom.github.io/nzbgetcom.asc | gpg --dearmor -o /etc/apt/keyrings/nzbgetcom.gpg
|
||||||
echo "deb [signed-by=/etc/apt/keyrings/nzbgetcom.gpg] https://nzbgetcom.github.io/deb stable main" >/etc/apt/sources.list.d/nzbgetcom.list
|
echo "deb [arch=all signed-by=/etc/apt/keyrings/nzbgetcom.gpg] https://nzbgetcom.github.io/deb stable main" >/etc/apt/sources.list.d/nzbgetcom.list
|
||||||
$STD apt-get update
|
$STD apt-get update
|
||||||
$STD apt-get install -y nzbget
|
$STD apt-get install -y nzbget
|
||||||
msg_ok "Installed NZBGet"
|
msg_ok "Installed NZBGet"
|
||||||
|
|||||||
43
json/habitica.json
Normal file
43
json/habitica.json
Normal file
@@ -0,0 +1,43 @@
|
|||||||
|
{
|
||||||
|
"name": "Habitica",
|
||||||
|
"slug": "habitica",
|
||||||
|
"categories": [
|
||||||
|
24
|
||||||
|
],
|
||||||
|
"date_created": "2025-03-03",
|
||||||
|
"type": "ct",
|
||||||
|
"updateable": true,
|
||||||
|
"privileged": false,
|
||||||
|
"interface_port": 8080,
|
||||||
|
"documentation": "https://github.com/HabitRPG/habitica/wiki",
|
||||||
|
"website": "https://habitica.com/",
|
||||||
|
"logo": "https://github.com/HabitRPG/habitica/raw/refs/heads/develop/website/client/src/assets/svg/logo.svg",
|
||||||
|
"description": "Habitica is an open-source habit-building program that treats your life like a role-playing game. Level up as you succeed, lose HP as you fail, and earn Gold to buy weapons and armor!",
|
||||||
|
"install_methods": [
|
||||||
|
{
|
||||||
|
"type": "default",
|
||||||
|
"script": "ct/habitica.sh",
|
||||||
|
"resources": {
|
||||||
|
"cpu": 2,
|
||||||
|
"ram": 4096,
|
||||||
|
"hdd": 8,
|
||||||
|
"os": "debian",
|
||||||
|
"version": "12"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"default_credentials": {
|
||||||
|
"username": null,
|
||||||
|
"password": null
|
||||||
|
},
|
||||||
|
"notes": [
|
||||||
|
{
|
||||||
|
"text": "It takes a minute or two after installation for web UI to start, please be patient.",
|
||||||
|
"type": "info"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"text": "Config file is at `/opt/habitica/config.json`",
|
||||||
|
"type": "info"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
@@ -30,10 +30,5 @@
|
|||||||
"username": null,
|
"username": null,
|
||||||
"password": null
|
"password": null
|
||||||
},
|
},
|
||||||
"notes": [
|
"notes": []
|
||||||
{
|
}
|
||||||
"text": "Linkwarden > 2.8.2 needs Monolith, More info: `https://github.com/community-scripts/ProxmoxVE/discussions/305`",
|
|
||||||
"type": "info"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
|
|||||||
@@ -8,7 +8,7 @@
|
|||||||
"type": "ct",
|
"type": "ct",
|
||||||
"updateable": true,
|
"updateable": true,
|
||||||
"privileged": false,
|
"privileged": false,
|
||||||
"interface_port": 9000,
|
"interface_port": 9001,
|
||||||
"documentation": "https://min.io/docs/minio/linux/index.html",
|
"documentation": "https://min.io/docs/minio/linux/index.html",
|
||||||
"website": "https://min.io/",
|
"website": "https://min.io/",
|
||||||
"logo": "https://raw.githubusercontent.com/minio/minio/refs/heads/master/.github/logo.svg",
|
"logo": "https://raw.githubusercontent.com/minio/minio/refs/heads/master/.github/logo.svg",
|
||||||
|
|||||||
@@ -43,7 +43,7 @@
|
|||||||
},
|
},
|
||||||
"notes": [
|
"notes": [
|
||||||
{
|
{
|
||||||
"text": "You can find the post-install guide here: https://github.com/community-scripts/ProxmoxVE/discussions/410",
|
"text": "You can find the post-install guide here: `https://github.com/community-scripts/ProxmoxVE/discussions/410`",
|
||||||
"type": "info"
|
"type": "info"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
Reference in New Issue
Block a user