Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature]: Support customized mirror #89

Open
fangzhengjin opened this issue Mar 8, 2024 · 1 comment
Open

[Feature]: Support customized mirror #89

fangzhengjin opened this issue Mar 8, 2024 · 1 comment
Labels
enhancement New feature or request

Comments

@fangzhengjin
Copy link
Contributor

fangzhengjin commented Mar 8, 2024

1. Your usage scenarios?

Support custom mirror address, such as:
For github, you can use: https://mirror.ghproxy.com
For nodejs, you can use: https://npmmirror.com/mirrors/node/ or internal service of the enterprise

2. What is your expected outcome?

Use environment variables:

3. other questions: How to apply in the inner network CI environment?

Support offline / ci mode! Skip plugin version check.
Provide Docker images, use offline / CI mode, install all plug -in by default, and then use the mirror installation environment set by environment variable settings, such as: VFOX_NODE_DIST_MIRROR.

@fangzhengjin
Copy link
Contributor Author

By the way, environment variables may be set separately for specific projects and saved in the .tool-versions / .vfoxrc file, which takes precedence over system environment variables, so that people do not have to modify environment variables frequently for different environments.

example: .vfoxrc

{
    "env": { // optional, .env priority is higher than system env
        "VFOX_NODE_DIST_MIRROR": "https://npmmirror.com/mirrors/node"
    },
    "profile": { // optional, profile.env priority is higher than .env
        "dev": {
            "env": {
                "VFOX_NODE_DIST_MIRROR": "https://npmmirror.com/mirrors/node"
            }
        },
        "ci": {
            "env": {
                "VFOX_NODE_DIST_MIRROR": "http://192.168.1.100:8000/repository/mirrors/node"
            }
        }
    },
    "tools": {
        "nodejs": "v18.19.0",
        "java": "21"
    }
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant