我想要做的是啓用從GitLab到Google Cloude上的計算引擎的連續交付。我在那裏運行Ubuntu 16.04 TSL。我確實安裝了運行我的項目所需的所有組件,如:Swift,Steam,nginx。 我已經設法安裝Gitlab runner,並創建了一個跑步者,可以從我的gitlab repo訪問。每次我推動掌握跑步者觸發器。發生什麼事是失敗的原因是:Gitlab - Google compute engine持續交付
could not create leading directories of '/home/gitlab-runner/builds/2bbbbbd/0/Server/Packages/vapor.git': Permission denied
如果我的權限更改爲chmod -R 777
這將焊割上running
爲build
舞臺上gitlab管道可見。
我不喜歡的東西: sudo chown -R gitlab-runner:gitlab-runner /home/gitlab-runner/builds
sudo chown -R gitlab-runner:gitlab-runner /home/gitlab-runner/cache
但是這並沒有幫助,錯誤的是同一Permission denied
下面你有我.gitlab-ci.yml
before_script:
- swift --version
stages:
- build
- deploy
job_build:
stage: build
before_script:
- vapor clean
script:
- vapor build --release
only:
- master
job_run_app:
stage: deploy
script:
- echo "Deploy a API"
- vapor run --name=App --env=production
environment:
name: production
job_run_frontend:
stage: deploy
script:
- echo "Deploy a Frontend"
- vapor run --name=Frontend --env=production
environment:
name: production
但還沒有傳遞到一個階段例如。部署。我已經等了14小時,但沒有結果。 而且......我有幾個問題:
- Gitlab亞軍創建構建下的位置
/home/gitlab-runner/builds/
在此位置每個新任務都有自己的文件夾。例如。/home/gitlab-runner/builds/2bbbbbd/
其中是我的項目和命令執行。那麼當第一個正在運行並且我部署新版本時會發生什麼?端口被第一個實例阻止了,如此等等? - 如果我想啓用
supervisor
當我每次部署文件夾的時候,我該如何做到這一點? - 任何人都可以解釋或顯示我或指向我的教程如何與外部碼頭持續部署?
您是如何解決您的權限問題的?自己面對同樣的問題。 –
我確實使用了適用於我的'chmod -R 777'。我知道這不是完美的解決方案,但爲了測試目的,這很好。不過,由於這個過程還沒有完成,所以它掛在'build'上。對於CD我現在瞄準dpl – Shial
經過一些工作,我得到了'build'來處理gce。也正在尋找dpl現在的CD –