Travis + Openshift未部署到openshift [英] Travis + Openshift Not deploying to openshift

查看:158
本文介绍了Travis + Openshift未部署到openshift的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们遇到了能够部署到openshift的问题。

We are having issues with being able to deploy to openshift. The deployment process runs but then doesn't actually deploy any new code to our gears.

这是我的travis文件:

language: node_js

node_js:
  - '0.10'

before_script:
  - npm install -g bower grunt-cli
  - gem install sass
  - bower install

services: mongodb

before_deploy:
  - rm -rf .sass-cache .tmp client e2e node_modules server styleguide *.*
  - mv dist/* ./
  - rm -rf dist
  - ls

notifications:
  slack: REMOVED

deploy:
  - provider: heroku
    api_key: REMOVED
    skip_cleanup: true
    buildpack: https://github.com/ddollar/heroku-buildpack-multi.git
    app:
      qa: snd-onair-webclient-qa
      production: snd-onair-webclient-production
  - provider: openshift
    user: rbrookfield@352inc.com
    password:
      secure: REMOVED
    skip_cleanup: true
    clean_up: false
    domain: onairtest
    app:
      staging: snd

branches:
  only:
    - dev
    - staging
    - qa
    - production

这里是我travis部署的尾部:

authenticated as rbrookfield@352inc.com
found app snd
Generating public/private rsa key pair.
Your identification has been saved in .dpl/id_rsa.
Your public key has been saved in .dpl/id_rsa.pub.
The key fingerprint is:
1d:0f:07:49:08:90:f3:1a:2f:b7:c3:9a:c4:19:bd:c7 testing-worker-linux-4554f670-1-8413-linux-2-14078509
The key's randomart image is:
+--[ RSA 2048]----+
|    .o.. oo.     |
|    o   . ..     |
|     o    o .    |
|    ...  . =     |
|    .+. S . .    |
|   .oooo         |
|    ++..E        |
|   . .+.         |
|    o. .         |
+-----------------+
dpl.3
Deploying application
warning: push.default is unset; its implicit value is changing in
Git 2.0 from 'matching' to 'simple'. To squelch this message
and maintain the current behavior after the default changes, use:
  git config --global push.default matching
To squelch this message and adopt the new behavior now, use:
  git config --global push.default simple
See 'git help config' and search for 'push.default' for further information.
(the 'simple' mode was introduced in Git 1.7.11. Use the similar mode
'current' instead of 'simple' if you sometimes use older versions of Git)
Warning: Permanently added 'snd-onairtest.rhcloud.com' (RSA) to the list of known hosts.
Everything up-to-date
Done. Your build exited with 0.

我也在我的开路齿轮上设置了ssh键,存储库,我可以从实例访问它。我不知道这是怎么回事。

I have also setup a ssh key on my openshift gears since this a private repository and I am able to access it from the instances. Im not sure what is going on here.

推荐答案

似乎是一个常见的问题。您需要在travis.yml文件中执行提交,以反映更新。这是我的代码中,我在我的测试后提交的部分:

Seems like a common-ish issue. You need to do a commit in the travis.yml file so that the updates are reflected. Here is the part in my code where I make the commit after my tests:


after_success:

- git config --global user.emailtravis@localhost.localdomain

- git config --global user.nameTravis CI

- git add --all

- git commit -amTravis change

after_success:
- git config --global user.email "travis@localhost.localdomain"
- git config --global user.name "Travis CI"
- git add --all
- git commit -am "Travis change"

还要注意的是,用户可以执行构建操作并通过执行以下操作部署工件:

Also be nice to note that a user could perform a build operation and deploy just the artifacts by doing something like the following:


after_success:

- grunt build

- cd dist

- git init

- git config --global user.emailtravis@localhost.localdomain

- git config --global user.nameTravis CI

- git add --all

- git commit -amTravis change

after_success:
- grunt build
- cd dist
- git init
- git config --global user.email "travis@localhost.localdomain"
- git config --global user.name "Travis CI"
- git add --all
- git commit -am "Travis change"

这篇关于Travis + Openshift未部署到openshift的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆