openshift

Populate environment variables from OpenShift secret with Docker build strategy

别说谁变了你拦得住时间么 提交于 2019-12-23 04:29:12
问题 I would like to use on opaque OpenShift secret inside a build pod as environment variable. The secret contains three key-value pairs, so they should become available as three environment variables. (This is for OpenShift 3.9). I have found a documented example for OpenShift's Source build strategy ( sourceStrategy ), but need this in the context of a build configuration with Docker build strategy ( dockerStrategy ). oc explain suggests that extraction of secrets into environment variables

Installing Kohana on OpenShift?

怎甘沉沦 提交于 2019-12-23 03:24:07
问题 How do I install Kohana v3.3.1 on Openshift? Do I create the PHP 5.3 cartridge and put the kohana files inside the php directory? Or do I create a Zend Server 5.6? I would like to use MySQL as well. Kohana v3.3.1 requires PHP 5.3.3 or higher to work. I just created a PHP 5.3 Cartridge and git clone it to my harddrive and here is the file structure: C:\mysite>ls -a . .. .git .openshift README.md deplist.txt libs misc php C:\mysite> Inside the php directory C:\mysite\php>ls -a . .. health_check

Deploying Flask in Openshift

假如想象 提交于 2019-12-23 02:55:16
问题 The following codes are working without any problem in my system's localhost... But ain't doing the job on OpenShift.. There is something wrong with my wsgi.py .. Do I have to pass my username and password using environment variables OR I've need to change the localhost ? The following is the tree of the directory/repository... myflaskaws ├── requirements.txt ├── setup.py ├── static │ ├── assets │ │ ├── style.css │ └── images │ ├── no.png │ └── yes.png ├── templates │ ├── index.html │ ├──

node is not a kubernetes node

烂漫一生 提交于 2019-12-23 02:21:14
问题 I am trying to run simple jenkins pipeline for Maven project. When I try to run it on Jenkins, I am getting below error: ERROR: Node is not a Kubernetes node: I have searched everything related to this error but could not find anything. Can someone tell me where am I doing mistake? Jenkinsfile: pipeline { agent { kubernetes { cloud 'openshift' label 'test' yamlFile 'jenkins/BuildPod.yaml' } } stages { stage('Build stage') { steps { sh 'mvn -B clean verify' } } stage('Test stage') { steps { sh

rhc port forward - open shift issue

陌路散爱 提交于 2019-12-23 01:34:30
问题 I am trying to port forward a particular application that I am developing for. In open shift I have the following applications available; If i choose hotornot then i get the following when running this command in the terminal rhc port-forward -a jbossas if i run the same command but replace hotornot with the other application name (jbossas) - i get the following Does anyone know why i can't port forward the second application but i can the first? Thanks 回答1: turns out i had to first login

Can't get socket.io and nodejs running with OpenShift

て烟熏妆下的殇ゞ 提交于 2019-12-22 12:43:04
问题 I can't get socket.io running on OpenShift. I googled for some hours now but nothing really helped me. Locally it works fine (with different ports and localhost as host of course). This is my server.js file: var port = process.env.OPENSHIFT_NODEJS_PORT || 8080; var ipadr = process.env.OPENSHIFT_NODEJS_IP || "127.0.0.1"; var http = require('http').createServer(function(request, response) { response.writeHead(200, {"Content-Type": "text/plain"}); response.end(); }).listen(port,ipadr); console

Can't get socket.io and nodejs running with OpenShift

为君一笑 提交于 2019-12-22 12:42:19
问题 I can't get socket.io running on OpenShift. I googled for some hours now but nothing really helped me. Locally it works fine (with different ports and localhost as host of course). This is my server.js file: var port = process.env.OPENSHIFT_NODEJS_PORT || 8080; var ipadr = process.env.OPENSHIFT_NODEJS_IP || "127.0.0.1"; var http = require('http').createServer(function(request, response) { response.writeHead(200, {"Content-Type": "text/plain"}); response.end(); }).listen(port,ipadr); console

Can Node.JS on OpenShift be upgraded?

情到浓时终转凉″ 提交于 2019-12-22 12:35:44
问题 On OpenShift, Node.JS is running 0.10.35 which is over a year old. Can this be upgraded to 5.x? cheers S 回答1: There seem to be a way to specify the version of nodejs for your OpenShift cartridge. Here is the official documentation: https://blog.openshift.com/any-version-of-nodejs-you-want-in-the-cloud-openshift-does-it-paas-style/ and also this is a custom Node.js cartridge that takes care of auto-updating the Node.js and NPM versions on each build https://github.com/icflorescu/openshift

ETIMEDOUT connect error using nodemailer in Nodejs Openshift application

瘦欲@ 提交于 2019-12-22 06:45:27
问题 I'm facing some problems using the nodemailer module in my node.js single gear non-scalable application in Openshift. As the documentation suggested, I initialized the transporter object and used the sendMail function. A simplified version of my code is var transporter = nodemailer.createTransport({ service: 'Gmail', auth: { user: 'my.mail@gmail.com', pass: 'mypassword' } }); var mail = { from: 'my.mail@gmail.com', to: 'test@mydomain.com', subject: 'Test mail', html: 'Test mail' };

How to obtain the enable admission controller list in kubernetes?

岁酱吖の 提交于 2019-12-22 05:29:06
问题 AFAIK, the admission controller is the last pass before the submission to the database. However I cannot know which one is enabled, Is there a way to know which one is taking effect? Thanks. 回答1: The kube-apiserver is running in your kube-apiserver-< example.com > container. The application does not have a get method at the moment to obtain the enabled admission plugins, but you can get the startup parameters from its command line. kubectl -n kube-system describe po kube-apiserver-example.com