Execution of scripts started on development machine #1815

Closed
opened 2026-02-05 02:20:23 +03:00 by OVERLORD · 3 comments
Owner

Originally created by @volkmarnissen on GitHub (Oct 17, 2025).

🌟 Briefly describe the feature

Enable scripts to run with standalone sources (backward compatible)

📝 Detailed description

Currently the scripts are called like this:

bash -c "$(wget -qLO - https://github.com/community-scripts/ProxmoxVE/raw/main/ct/mariadb.sh)"

This could be enhanced by the following command line options:
--script-dir

local directory for the scripts is empty:
download from ProxmoxVE
--pve-host
Host name of of the proxmox node (default is localhost)
--github-repository my repository
Name of a repository forked from in default is community-scripts.
--branch
Name of a branch in ProxmoxVE default is main.

Example of usage:

  1. Same as today see above
  2. Execute script "on" a development machine with local scripts in ~/ProxmoxVE
~/ProxmoxVE/vc/myApp.sh --script-dir ~/ProxmoxVE --pve-host myProxmoxNode

3.Execute script from a forked repository

bash -c "$(wget -qLO - https://github.com/<my repository>/ProxmoxVE/raw/<mybranch>/ct/<myApp>.sh)" -- --github-repository **my repository** --branch **mybranch**

Implementation and Testing

  • The feature should be implemented using a minimalistic approach.
  • In the original code, only the source ... lines should be changed
  • No changes in ct/* files
  • The new feature should be tested using unit tests to make sure, all use cases are working properly.
  • Before pulling to main:
    -- The feature must be tested on the forked repository with some standard script like ct/mariadb.sh.
    -- Test update command in lxc container.
    -- May be the pull request workflow doesn't handle the changed files.
    However after the changes, the workflow can be simplified by using the command line options
  • Once the feature is in main branch the same tests must be executed from community-scripts repository
  • If the last step fails, a rollback in main branch must be executed.

I can implement it and create a pull request.

💡 Why is this useful?

When developing new lxc container types, it is difficult to test this with local files.
This is much easier if the feature is implemented.

Originally created by @volkmarnissen on GitHub (Oct 17, 2025). ### 🌟 Briefly describe the feature Enable scripts to run with standalone sources (backward compatible) ### 📝 Detailed description Currently the scripts are called like this: ``` bash -c "$(wget -qLO - https://github.com/community-scripts/ProxmoxVE/raw/main/ct/mariadb.sh)" ``` This could be enhanced by the following command line options: **--script-dir <dir>** local directory for the scripts is empty: download from [ProxmoxVE](https://github.com/community-scripts/ProxmoxVE) **--pve-host <dir>** Host name of of the proxmox node (default is localhost) **--github-repository my repository** Name of a repository forked from in default is **community-scripts**. **--branch <branch name>** Name of a branch in [ProxmoxVE](https://github.com/community-scripts/ProxmoxVE) default is main. Example of usage: 1. Same as today see above 2. Execute script "on" a development machine with local scripts in ```~/ProxmoxVE``` ``` ~/ProxmoxVE/vc/myApp.sh --script-dir ~/ProxmoxVE --pve-host myProxmoxNode ``` 3.Execute script from a forked repository ``` bash -c "$(wget -qLO - https://github.com/<my repository>/ProxmoxVE/raw/<mybranch>/ct/<myApp>.sh)" -- --github-repository **my repository** --branch **mybranch** ``` ## Implementation and Testing - The feature should be implemented using a minimalistic approach. - In the original code, only ```the source ...``` lines should be changed - No changes in ```ct/*``` files - The new feature should be tested using unit tests to make sure, all use cases are working properly. - Before pulling to main: -- The feature must be tested on the forked repository with some standard script like ct/mariadb.sh. -- Test update command in lxc container. -- May be the pull request workflow doesn't handle the changed files. However after the changes, the workflow can be simplified by using the command line options - Once the feature is in main branch the same tests must be executed from **community-scripts** repository - If the last step fails, a rollback in main branch must be executed. I can implement it and create a pull request. ### 💡 Why is this useful? When developing new lxc container types, it is difficult to test this with local files. This is much easier if the feature is implemented.
OVERLORD added the enhancement label 2026-02-05 02:20:23 +03:00
Author
Owner

@michelroegl-brunner commented on GitHub (Oct 17, 2025):

You may want to look at the ProxmoxVE-Loacl repo, this is more or less what you want. ther you can add the scripts you want to test locally.

@michelroegl-brunner commented on GitHub (Oct 17, 2025): You may want to look at the [ProxmoxVE-Loacl](https://github.com/[community-scripts/ProxmoxVE-Local](https://github.com/community-scripts/ProxmoxVE-Local)) repo, this is more or less what you want. ther you can add the scripts you want to test locally.
Author
Owner

@MickLesk commented on GitHub (Oct 17, 2025):

This is not so easy to do with subshells. At the latest during installation (within the LXC), it loses the connection. It is not difficult to fork ProxmoxVED, replace the few places there using Search&Replace, and then just push the PR with the 2-3 files. New scripts only work against ProxmoxVED anyway, which is a very small repo.

@MickLesk commented on GitHub (Oct 17, 2025): This is not so easy to do with subshells. At the latest during installation (within the LXC), it loses the connection. It is not difficult to fork ProxmoxVED, replace the few places there using Search&Replace, and then just push the PR with the 2-3 files. New scripts only work against ProxmoxVED anyway, which is a very small repo.
Author
Owner

@CrazyWolf13 commented on GitHub (Oct 18, 2025):

Small side note, we don't use wget anymore, we got bashed on reddit and therefore switched everything to curl for security:

bash -c "$(wget -qLO - https://github.com/community-scripts/ProxmoxVE/raw/main/ct/mariadb.sh)"

-->

bash -c "$(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/ct/mariadb.sh)"
@CrazyWolf13 commented on GitHub (Oct 18, 2025): Small side note, we don't use wget anymore, we got bashed on reddit and therefore switched everything to curl for security: ```bash bash -c "$(wget -qLO - https://github.com/community-scripts/ProxmoxVE/raw/main/ct/mariadb.sh)" ``` --> ```bash bash -c "$(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/ct/mariadb.sh)" ```
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/ProxmoxVE#1815