forked from p68pgqsh7/simulation_temp
Compare commits
No commits in common. 'develop' and 'main' have entirely different histories.
@ -1,33 +0,0 @@
|
||||
kind: pipeline
|
||||
type: docker
|
||||
name: deploy
|
||||
platform:
|
||||
os: linux
|
||||
arch: amd64
|
||||
volumes:
|
||||
- name: cache
|
||||
host:
|
||||
path: /var/lib/cache
|
||||
steps:
|
||||
# host、username、password可在参数管理中配置
|
||||
- name: 远程主机部署
|
||||
image: appleboy/drone-ssh
|
||||
pull: if-not-exists # 添加此行,只在本地没有镜像时才拉取
|
||||
settings:
|
||||
host:
|
||||
from_secret: deploy_ip
|
||||
username:
|
||||
from_secret: deploy_name
|
||||
password:
|
||||
from_secret: deploy_pwd
|
||||
port: 22
|
||||
script:
|
||||
- echo ====暂停容器开始11=======
|
||||
- rm -fr /opt/test
|
||||
- git clone https://bdgit.educoder.net/jasder/simulation_temp.git /opt/test
|
||||
- chmod 777 /opt/test
|
||||
- docker rm -f nginx
|
||||
- echo ====开始部署=======
|
||||
- docker run -d -p 58080:80 -v /opt/test:/usr/share/nginx/html:ro --name nginx nginx:1.24.0
|
||||
- echo ====部署成功======
|
||||
|
Loading…
Reference in new issue