Changes to Workfows
Some checks failed
Auto Update .app-files / update-app-files (push) Has been cancelled
Shellcheck / Shellcheck (push) Has been cancelled
Create Changelog Pull Request / update-changelog-pull-request (push) Has been cancelled
Close Discussion on PR Merge / close-discussion (push) Has been cancelled
Sync to Gitea / sync (push) Has been cancelled
Some checks failed
Auto Update .app-files / update-app-files (push) Has been cancelled
Shellcheck / Shellcheck (push) Has been cancelled
Create Changelog Pull Request / update-changelog-pull-request (push) Has been cancelled
Close Discussion on PR Merge / close-discussion (push) Has been cancelled
Sync to Gitea / sync (push) Has been cancelled
This commit is contained in:
parent
98daf9bc56
commit
c3f73291a3
@ -5,11 +5,12 @@ on:
|
|||||||
branches:
|
branches:
|
||||||
- main
|
- main
|
||||||
paths:
|
paths:
|
||||||
- 'ct/**.sh'
|
- "ct/**.sh"
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
update-app-files:
|
update-app-files:
|
||||||
|
if: github.repository == 'community-scripts/ProxmoxVED'
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
@ -79,7 +80,7 @@ jobs:
|
|||||||
--label "automated pr"
|
--label "automated pr"
|
||||||
env:
|
env:
|
||||||
GH_TOKEN: ${{ steps.generate-token.outputs.token }}
|
GH_TOKEN: ${{ steps.generate-token.outputs.token }}
|
||||||
|
|
||||||
- name: Approve pull request
|
- name: Approve pull request
|
||||||
if: env.changed == 'true'
|
if: env.changed == 'true'
|
||||||
env:
|
env:
|
||||||
@ -89,7 +90,7 @@ jobs:
|
|||||||
if [ -n "$PR_NUMBER" ]; then
|
if [ -n "$PR_NUMBER" ]; then
|
||||||
gh pr review $PR_NUMBER --approve
|
gh pr review $PR_NUMBER --approve
|
||||||
fi
|
fi
|
||||||
|
|
||||||
- name: Re-approve pull request after update
|
- name: Re-approve pull request after update
|
||||||
if: env.changed == 'true'
|
if: env.changed == 'true'
|
||||||
env:
|
env:
|
||||||
|
11
.github/workflows/autolabeler.yml
vendored
11
.github/workflows/autolabeler.yml
vendored
@ -7,6 +7,7 @@ on:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
autolabeler:
|
autolabeler:
|
||||||
|
if: github.repository == 'community-scripts/ProxmoxVED'
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
permissions:
|
permissions:
|
||||||
pull-requests: write
|
pull-requests: write
|
||||||
@ -42,9 +43,9 @@ jobs:
|
|||||||
pull_number: prNumber,
|
pull_number: prNumber,
|
||||||
});
|
});
|
||||||
const prFiles = prListFilesResponse.data;
|
const prFiles = prListFilesResponse.data;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// Apply labels based on file changes
|
// Apply labels based on file changes
|
||||||
for (const [label, rules] of Object.entries(autolabelerConfig)) {
|
for (const [label, rules] of Object.entries(autolabelerConfig)) {
|
||||||
const shouldAddLabel = prFiles.some((prFile) => {
|
const shouldAddLabel = prFiles.some((prFile) => {
|
||||||
@ -66,17 +67,17 @@ jobs:
|
|||||||
"✨ **New feature**": "feature",
|
"✨ **New feature**": "feature",
|
||||||
"💥 **Breaking change**": "breaking change",
|
"💥 **Breaking change**": "breaking change",
|
||||||
};
|
};
|
||||||
|
|
||||||
for (const [checkbox, label] of Object.entries(templateLabelMappings)) {
|
for (const [checkbox, label] of Object.entries(templateLabelMappings)) {
|
||||||
const escapedCheckbox = checkbox.replace(/([.*+?^=!:${}()|\[\]\/\\])/g, "\\$1");
|
const escapedCheckbox = checkbox.replace(/([.*+?^=!:${}()|\[\]\/\\])/g, "\\$1");
|
||||||
const regex = new RegExp(`- \\[(x|X)\\]\\s*.*${escapedCheckbox}`, "i");
|
const regex = new RegExp(`- \\[(x|X)\\]\\s*.*${escapedCheckbox}`, "i");
|
||||||
const match = prBody.match(regex);
|
const match = prBody.match(regex);
|
||||||
if (match) {
|
if (match) {
|
||||||
console.log(`Match: ${match}`);
|
console.log(`Match: ${match}`);
|
||||||
labelsToAdd.add(label);
|
labelsToAdd.add(label);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
console.log(`Labels to add: ${Array.from(labelsToAdd).join(", ")}`);
|
console.log(`Labels to add: ${Array.from(labelsToAdd).join(", ")}`);
|
||||||
|
|
||||||
if (labelsToAdd.size > 0) {
|
if (labelsToAdd.size > 0) {
|
||||||
|
2
.github/workflows/changelog-pr.yaml
vendored
2
.github/workflows/changelog-pr.yaml
vendored
@ -7,7 +7,7 @@ on:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
update-changelog-pull-request:
|
update-changelog-pull-request:
|
||||||
if: github.repository == 'community-scripts/ProxmoxVE'
|
if: github.repository == 'community-scripts/ProxmoxVED'
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
env:
|
env:
|
||||||
CONFIG_PATH: .github/changelog-pr-config.json
|
CONFIG_PATH: .github/changelog-pr-config.json
|
||||||
|
1
.github/workflows/close-discussion.yaml
vendored
1
.github/workflows/close-discussion.yaml
vendored
@ -11,6 +11,7 @@ permissions:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
close-discussion:
|
close-discussion:
|
||||||
|
if: github.repository == 'community-scripts/ProxmoxVED'
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
|
5
.github/workflows/close-ttek-issue.yaml
vendored
5
.github/workflows/close-ttek-issue.yaml
vendored
@ -6,6 +6,7 @@ on:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
close_tteck_issues:
|
close_tteck_issues:
|
||||||
|
if: github.repository == 'community-scripts/ProxmoxVED'
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Auto-close if tteck script detected
|
- name: Auto-close if tteck script detected
|
||||||
@ -22,12 +23,12 @@ jobs:
|
|||||||
|
|
||||||
This repository is no longer used for active scripts.
|
This repository is no longer used for active scripts.
|
||||||
**Please update your bookmarks** and use: [https://helper-scripts.com](https://helper-scripts.com)
|
**Please update your bookmarks** and use: [https://helper-scripts.com](https://helper-scripts.com)
|
||||||
|
|
||||||
Also make sure your Bash command starts with:
|
Also make sure your Bash command starts with:
|
||||||
\`\`\`bash
|
\`\`\`bash
|
||||||
bash <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/ct/...)
|
bash <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/ct/...)
|
||||||
\`\`\`
|
\`\`\`
|
||||||
|
|
||||||
This issue is being closed automatically.`;
|
This issue is being closed automatically.`;
|
||||||
|
|
||||||
await github.rest.issues.createComment({
|
await github.rest.issues.createComment({
|
||||||
|
@ -11,7 +11,7 @@ permissions:
|
|||||||
jobs:
|
jobs:
|
||||||
post_to_discord:
|
post_to_discord:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
if: contains(github.event.issue.labels.*.name, 'Ready For Testing')
|
if: contains(github.event.issue.labels.*.name, 'Ready For Testing') && github.repository == 'community-scripts/ProxmoxVED'
|
||||||
steps:
|
steps:
|
||||||
- name: Extract Issue Title (Lowercase & Underscores)
|
- name: Extract Issue Title (Lowercase & Underscores)
|
||||||
id: extract_title
|
id: extract_title
|
||||||
|
3
.github/workflows/delete-discord-thread.yml
vendored
3
.github/workflows/delete-discord-thread.yml
vendored
@ -7,13 +7,14 @@ on:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
close_discord_thread:
|
close_discord_thread:
|
||||||
|
if: github.repository == 'community-scripts/ProxmoxVED'
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Get thread-ID op and close thread
|
- name: Get thread-ID op and close thread
|
||||||
run: |
|
run: |
|
||||||
ISSUE_TITLE="${{ github.event.issue.title }}"
|
ISSUE_TITLE="${{ github.event.issue.title }}"
|
||||||
|
|
||||||
THREAD_ID=$(curl -s -X GET "https://discord.com/api/v10/guilds/${{ secrets.DISCORD_GUILD_ID }}/threads/active" \
|
THREAD_ID=$(curl -s -X GET "https://discord.com/api/v10/guilds/${{ secrets.DISCORD_GUILD_ID }}/threads/active" \
|
||||||
-H "Authorization: Bot ${{ secrets.DISCORD_BOT_TOKEN }}" \
|
-H "Authorization: Bot ${{ secrets.DISCORD_BOT_TOKEN }}" \
|
||||||
-H "Content-Type: application/json" | \
|
-H "Content-Type: application/json" | \
|
||||||
|
2
.github/workflows/delete_new_script.yaml
vendored
2
.github/workflows/delete_new_script.yaml
vendored
@ -7,7 +7,7 @@ on:
|
|||||||
jobs:
|
jobs:
|
||||||
delete-files:
|
delete-files:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
if: contains(github.event.issue.labels.*.name, 'Started Migration To ProxmoxVE')
|
if: contains(github.event.issue.labels.*.name, 'Started Migration To ProxmoxVE') && github.repository == 'community-scripts/ProxmoxVED'
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
|
5
.github/workflows/frontend-cicd.yml
vendored
5
.github/workflows/frontend-cicd.yml
vendored
@ -25,10 +25,11 @@ concurrency:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
|
if: github.repository == 'community-scripts/ProxmoxVED'
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
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
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
@ -63,7 +64,7 @@ jobs:
|
|||||||
deploy:
|
deploy:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: build
|
needs: build
|
||||||
if: github.ref == 'refs/heads/main'
|
if: github.ref == 'refs/heads/main' && github.repository == 'community-scripts/ProxmoxVED'
|
||||||
permissions:
|
permissions:
|
||||||
pages: write
|
pages: write
|
||||||
id-token: write
|
id-token: write
|
||||||
|
7
.github/workflows/get-versions-from-gh.yaml
vendored
7
.github/workflows/get-versions-from-gh.yaml
vendored
@ -12,6 +12,7 @@ permissions:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
crawl-versions:
|
crawl-versions:
|
||||||
|
if: github.repository == 'community-scripts/ProxmoxVED'
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
@ -32,10 +33,10 @@ jobs:
|
|||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
run: |
|
run: |
|
||||||
ls
|
ls
|
||||||
|
|
||||||
chmod +x .github/workflows/scripts/get-gh-release.sh
|
chmod +x .github/workflows/scripts/get-gh-release.sh
|
||||||
.github/workflows/scripts/get-gh-release.sh
|
.github/workflows/scripts/get-gh-release.sh
|
||||||
|
|
||||||
- name: Commit JSON
|
- name: Commit JSON
|
||||||
env:
|
env:
|
||||||
|
@ -12,6 +12,7 @@ permissions:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
crawl-versions:
|
crawl-versions:
|
||||||
|
if: github.repository == 'community-scripts/ProxmoxVED'
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
|
2
.github/workflows/move-to-main-repo.yaml
vendored
2
.github/workflows/move-to-main-repo.yaml
vendored
@ -14,7 +14,7 @@ permissions:
|
|||||||
jobs:
|
jobs:
|
||||||
move-to-main-repo:
|
move-to-main-repo:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
if: github.event.label.name == 'Migration To ProxmoxVE'
|
if: github.event.label.name == 'Migration To ProxmoxVE' && github.repository == 'community-scripts/ProxmoxVED'
|
||||||
steps:
|
steps:
|
||||||
- name: Generate a token
|
- name: Generate a token
|
||||||
id: app-token
|
id: app-token
|
||||||
|
3
.github/workflows/push-to-gitea.yml
vendored
3
.github/workflows/push-to-gitea.yml
vendored
@ -7,6 +7,7 @@ on:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
sync:
|
sync:
|
||||||
|
if: github.repository == 'community-scripts/ProxmoxVED'
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
@ -19,7 +20,7 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
git config --global user.name "Push From Github"
|
git config --global user.name "Push From Github"
|
||||||
git config --global user.email "actions@github.com"
|
git config --global user.email "actions@github.com"
|
||||||
git remote add gitea http://$GITEA_USER:$GITEA_TOKEN@git.community-scripts.org/community-scripts/ProxmoxVED.git
|
git remote add gitea https://$GITEA_USER:$GITEA_TOKEN@git.community-scripts.org/community-scripts/ProxmoxVED.git
|
||||||
git push gitea --mirror
|
git push gitea --mirror
|
||||||
env:
|
env:
|
||||||
GITEA_USER: ${{ secrets.GITEA_USERNAME }}
|
GITEA_USER: ${{ secrets.GITEA_USERNAME }}
|
||||||
|
132
.github/workflows/script-test.yaml
vendored
132
.github/workflows/script-test.yaml
vendored
@ -1,16 +1,17 @@
|
|||||||
name: Run Scripts on PVE Node for testing
|
name: Run Scripts on PVE Node for testing
|
||||||
permissions:
|
permissions:
|
||||||
pull-requests: write
|
pull-requests: write
|
||||||
on:
|
on:
|
||||||
pull_request_target:
|
pull_request_target:
|
||||||
branches:
|
branches:
|
||||||
- main
|
- main
|
||||||
paths:
|
paths:
|
||||||
- 'install/**.sh'
|
- "install/**.sh"
|
||||||
- 'ct/**.sh'
|
- "ct/**.sh"
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
run-install-script:
|
run-install-script:
|
||||||
|
if: github.repository == 'community-scripts/ProxmoxVED'
|
||||||
runs-on: pvenode
|
runs-on: pvenode
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout PR branch
|
- name: Checkout PR branch
|
||||||
@ -39,7 +40,6 @@ jobs:
|
|||||||
env:
|
env:
|
||||||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
|
|
||||||
- name: Get scripts
|
- name: Get scripts
|
||||||
id: check-install-script
|
id: check-install-script
|
||||||
run: |
|
run: |
|
||||||
@ -62,73 +62,73 @@ jobs:
|
|||||||
id: run-install
|
id: run-install
|
||||||
continue-on-error: true
|
continue-on-error: true
|
||||||
run: |
|
run: |
|
||||||
set +e
|
set +e
|
||||||
#run for each files in /ct
|
#run for each files in /ct
|
||||||
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$//')
|
||||||
echo "Running Test for: $STRIPPED_NAME"
|
echo "Running Test for: $STRIPPED_NAME"
|
||||||
if grep -E -q 'read\s+-r\s+-p\s+".*"\s+\w+' "$FILE"; then
|
if grep -E -q 'read\s+-r\s+-p\s+".*"\s+\w+' "$FILE"; then
|
||||||
echo "The script contains an interactive prompt. Skipping execution."
|
echo "The script contains an interactive prompt. Skipping execution."
|
||||||
|
continue
|
||||||
|
fi
|
||||||
|
if [[ $FILE =~ ^install/.*-install\.sh$ ]]; then
|
||||||
|
CT_SCRIPT="ct/$STRIPPED_NAME.sh"
|
||||||
|
if [[ ! -f $CT_SCRIPT ]]; then
|
||||||
|
echo "No CT script found for $STRIPPED_NAME"
|
||||||
|
ERROR_MSG="No CT script found for $FILE"
|
||||||
|
echo "$ERROR_MSG" > result_$STRIPPED_NAME.log
|
||||||
continue
|
continue
|
||||||
fi
|
fi
|
||||||
if [[ $FILE =~ ^install/.*-install\.sh$ ]]; then
|
if grep -E -q 'read\s+-r\s+-p\s+".*"\s+\w+' "install/$STRIPPED_NAME-install.sh"; then
|
||||||
CT_SCRIPT="ct/$STRIPPED_NAME.sh"
|
echo "The script contains an interactive prompt. Skipping execution."
|
||||||
if [[ ! -f $CT_SCRIPT ]]; then
|
|
||||||
echo "No CT script found for $STRIPPED_NAME"
|
|
||||||
ERROR_MSG="No CT script found for $FILE"
|
|
||||||
echo "$ERROR_MSG" > result_$STRIPPED_NAME.log
|
|
||||||
continue
|
continue
|
||||||
fi
|
fi
|
||||||
if grep -E -q 'read\s+-r\s+-p\s+".*"\s+\w+' "install/$STRIPPED_NAME-install.sh"; then
|
echo "Found CT script for $STRIPPED_NAME"
|
||||||
echo "The script contains an interactive prompt. Skipping execution."
|
chmod +x "$CT_SCRIPT"
|
||||||
continue
|
RUNNING_FILE=$CT_SCRIPT
|
||||||
fi
|
elif [[ $FILE =~ ^ct/.*\.sh$ ]]; then
|
||||||
echo "Found CT script for $STRIPPED_NAME"
|
INSTALL_SCRIPT="install/$STRIPPED_NAME-install.sh"
|
||||||
chmod +x "$CT_SCRIPT"
|
if [[ ! -f $INSTALL_SCRIPT ]]; then
|
||||||
RUNNING_FILE=$CT_SCRIPT
|
echo "No install script found for $STRIPPED_NAME"
|
||||||
elif [[ $FILE =~ ^ct/.*\.sh$ ]]; then
|
ERROR_MSG="No install script found for $FILE"
|
||||||
INSTALL_SCRIPT="install/$STRIPPED_NAME-install.sh"
|
|
||||||
if [[ ! -f $INSTALL_SCRIPT ]]; then
|
|
||||||
echo "No install script found for $STRIPPED_NAME"
|
|
||||||
ERROR_MSG="No install script found for $FILE"
|
|
||||||
echo "$ERROR_MSG" > result_$STRIPPED_NAME.log
|
|
||||||
continue
|
|
||||||
fi
|
|
||||||
echo "Found install script for $STRIPPED_NAME"
|
|
||||||
chmod +x "$INSTALL_SCRIPT"
|
|
||||||
RUNNING_FILE=$FILE
|
|
||||||
if grep -E -q 'read\s+-r\s+-p\s+".*"\s+\w+' "ct/$STRIPPED_NAME.sh"; then
|
|
||||||
echo "The script contains an interactive prompt. Skipping execution."
|
|
||||||
continue
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
git remote add community-scripts https://github.com/community-scripts/ProxmoxVE.git
|
|
||||||
git fetch community-scripts
|
|
||||||
rm -f .github/workflows/scripts/app-test/pr-build.func || true
|
|
||||||
rm -f .github/workflows/scripts/app-test/pr-install.func || true
|
|
||||||
rm -f .github/workflows/scripts/app-test/pr-alpine-install.func || true
|
|
||||||
rm -f .github/workflows/scripts/app-test/pr-create-lxc.sh || true
|
|
||||||
git checkout community-scripts/main -- .github/workflows/scripts/app-test/pr-build.func
|
|
||||||
git checkout community-scripts/main -- .github/workflows/scripts/app-test/pr-install.func
|
|
||||||
git checkout community-scripts/main -- .github/workflows/scripts/app-test/pr-alpine-install.func
|
|
||||||
git checkout community-scripts/main -- .github/workflows/scripts/app-test/pr-create-lxc.sh
|
|
||||||
chmod +x $RUNNING_FILE
|
|
||||||
chmod +x .github/workflows/scripts/app-test/pr-create-lxc.sh
|
|
||||||
chmod +x .github/workflows/scripts/app-test/pr-install.func
|
|
||||||
chmod +x .github/workflows/scripts/app-test/pr-alpine-install.func
|
|
||||||
chmod +x .github/workflows/scripts/app-test/pr-build.func
|
|
||||||
sed -i 's|source <(curl -s https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/build.func)|source .github/workflows/scripts/app-test/pr-build.func|g' "$RUNNING_FILE"
|
|
||||||
echo "Executing $RUNNING_FILE"
|
|
||||||
export TERM=xterm-256color
|
|
||||||
./$RUNNING_FILE
|
|
||||||
ERROR_MSG=$(./$RUNNING_FILE 2>&1 > /dev/null)
|
|
||||||
echo "Finished running $FILE"
|
|
||||||
if [ -n "$ERROR_MSG" ]; then
|
|
||||||
echo "ERROR in $STRIPPED_NAME: $ERROR_MSG"
|
|
||||||
echo "$ERROR_MSG" > result_$STRIPPED_NAME.log
|
echo "$ERROR_MSG" > result_$STRIPPED_NAME.log
|
||||||
|
continue
|
||||||
fi
|
fi
|
||||||
done
|
echo "Found install script for $STRIPPED_NAME"
|
||||||
set -e # Restore exit-on-error
|
chmod +x "$INSTALL_SCRIPT"
|
||||||
|
RUNNING_FILE=$FILE
|
||||||
|
if grep -E -q 'read\s+-r\s+-p\s+".*"\s+\w+' "ct/$STRIPPED_NAME.sh"; then
|
||||||
|
echo "The script contains an interactive prompt. Skipping execution."
|
||||||
|
continue
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
git remote add community-scripts https://github.com/community-scripts/ProxmoxVE.git
|
||||||
|
git fetch community-scripts
|
||||||
|
rm -f .github/workflows/scripts/app-test/pr-build.func || true
|
||||||
|
rm -f .github/workflows/scripts/app-test/pr-install.func || true
|
||||||
|
rm -f .github/workflows/scripts/app-test/pr-alpine-install.func || true
|
||||||
|
rm -f .github/workflows/scripts/app-test/pr-create-lxc.sh || true
|
||||||
|
git checkout community-scripts/main -- .github/workflows/scripts/app-test/pr-build.func
|
||||||
|
git checkout community-scripts/main -- .github/workflows/scripts/app-test/pr-install.func
|
||||||
|
git checkout community-scripts/main -- .github/workflows/scripts/app-test/pr-alpine-install.func
|
||||||
|
git checkout community-scripts/main -- .github/workflows/scripts/app-test/pr-create-lxc.sh
|
||||||
|
chmod +x $RUNNING_FILE
|
||||||
|
chmod +x .github/workflows/scripts/app-test/pr-create-lxc.sh
|
||||||
|
chmod +x .github/workflows/scripts/app-test/pr-install.func
|
||||||
|
chmod +x .github/workflows/scripts/app-test/pr-alpine-install.func
|
||||||
|
chmod +x .github/workflows/scripts/app-test/pr-build.func
|
||||||
|
sed -i 's|source <(curl -s https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/build.func)|source .github/workflows/scripts/app-test/pr-build.func|g' "$RUNNING_FILE"
|
||||||
|
echo "Executing $RUNNING_FILE"
|
||||||
|
export TERM=xterm-256color
|
||||||
|
./$RUNNING_FILE
|
||||||
|
ERROR_MSG=$(./$RUNNING_FILE 2>&1 > /dev/null)
|
||||||
|
echo "Finished running $FILE"
|
||||||
|
if [ -n "$ERROR_MSG" ]; then
|
||||||
|
echo "ERROR in $STRIPPED_NAME: $ERROR_MSG"
|
||||||
|
echo "$ERROR_MSG" > result_$STRIPPED_NAME.log
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
set -e # Restore exit-on-error
|
||||||
|
|
||||||
- name: Cleanup PVE Node
|
- name: Cleanup PVE Node
|
||||||
run: |
|
run: |
|
||||||
@ -175,5 +175,3 @@ jobs:
|
|||||||
done
|
done
|
||||||
|
|
||||||
echo "ERROR=$ERROR" >> $GITHUB_ENV
|
echo "ERROR=$ERROR" >> $GITHUB_ENV
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user