mirror of https://github.com/kubernetes/kops.git
				
				
				
			
		
			
				
	
	
	
		
			1.3 KiB
		
	
	
	
	
	
			
		
		
	
	
			1.3 KiB
		
	
	
	
	
	
Vendoring Go dependencies
kOps uses go mod to manage vendored dependencies.
Prerequisites
The following software must be installed prior to running the update commands:
Adding a dependency to the vendor directory
Go modules will manage required dependencies based on the imports found in the source code. Follow these steps to run the update process:
- Add the desired import to a .gofile.
- Run make gomodto start the update process. If this step is successful, the imported dependency will be added to thevendorsubdirectory.
- Commit any changes, including changes to the vendordirectory,go.mod, andgo.sum.
- Open a pull request with these changes separately from other work so that it is easier to review.
Updating a dependency in the vendor directory (e.g. aws-sdk-go)
- Update the locked version as specified in go.mod
- Run make gomod.
- Review the changes to ensure that they are as intended / trustworthy.
- Commit any changes, including changes to the vendordirectory,go.modandgo.sum.
- Open a pull request with these changes separately from other work so that it is easier to review. Please include any significant changes you observed.