fix(deploy): add sudo to kubectl apply command for proper permissions
The deploy-server target was failing due to insufficient permissions on the remote server. Adding sudo ensures kubectl can apply the deployment configuration.
This commit is contained in:
2
Makefile
2
Makefile
@@ -27,7 +27,7 @@ deploy-server:
|
||||
@cat k8s/deployment.yaml >> /tmp/server_deploy.yaml
|
||||
@# Single SCP/SSH call to reduce password prompts
|
||||
scp /tmp/server_deploy.yaml $(SERVER_USER)@$(SERVER_IP):/tmp/server_deploy.yaml
|
||||
ssh $(SERVER_USER)@$(SERVER_IP) "kubectl apply -f /tmp/server_deploy.yaml && rm /tmp/server_deploy.yaml"
|
||||
ssh $(SERVER_USER)@$(SERVER_IP) "sudo kubectl apply -f /tmp/server_deploy.yaml && rm /tmp/server_deploy.yaml"
|
||||
@rm /tmp/server_deploy.yaml
|
||||
|
||||
stop:
|
||||
|
||||
Reference in New Issue
Block a user