#codefresh - March 2019

Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
@dustinvb is there are way to update shared configurations using cli?
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
thx!!
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
feels very much like kubectl
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
too bad it doesn't support -f - for stdin
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago

Error: Failed to read file; caused by Error: File extension is not recognized

Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
@dustinvb got what I wanted to implement (assume roles) for codefresh
Mark Grube
Mark Grubeover 7 years ago
has anyone ever set up deploy conditionals to only deploy when a branch is tagged?
dustinvb
dustinvbover 7 years ago
rss
rssover 7 years ago
GitHub Incident - Degraded performance across Web, Pages and Notifications
Mar 12, 15:18 UTC
Investigating - GitHub has reported an incident related to degraded performance across Web, Pages and Notifications.
More information here: https://www.githubstatus.com/
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
The Codefresh status page includes statuses of everything they depend on
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
Yea it’s worked wonderfully! We have a channel at CloudPosse with feeds for all the status pages (including AWS) that we depend on
rss
rssover 7 years ago
GitHub Incident - Degraded performance across Web, Pages and Notifications
Mar 13, 08:51 UTC
Resolved - This incident has been resolved.
Mar 12, 15:18 UTC
Investigating - GitHub has reported an incident related to degraded performance across Web, Pages and Notifications.
More information here: https://www.githubstatus.com/
dustinvb
dustinvbover 7 years ago
Sorry been traveling see you're already here @oscarsullivan_old
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
Just incase anyone is planning on rolling out Codefresh Enterprise (on prem), in AWS, here’s our terraform module for it: https://github.com/cloudposse/terraform-aws-codefresh-backing-services
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
this is to leverage as many fully-managed AWS services as possible that are required to run Codefresh
dustinvb
dustinvbover 7 years ago
Simple Step for Aqua scanning in a Codefresh pipeline. https://github.com/codefresh-contrib/cfstep-aqua
dustinvb
dustinvbover 7 years ago
This is the results passed back to Codefresh registry and there is a link to the detailed report in Aqua
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
@dustinvb did something change in the last 2-3 weeks in codefresh that would lead to this to start failing?

chsh -s /bin/sh nobody
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
got it
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
something in alpine:3.7 has changed
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
so that it prompts for a password
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
but doesn't happen in 3.8
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago(edited)
i'll figure this out.
dustinvb
dustinvbover 7 years ago
I normally see this error related to npm install using global flag. Not sure why it's going to fail here. I have to add the unsafe arg to npmconfig to get around it.
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
this worked for me
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago(edited)
echo "auth sufficient pam_shells.so" > /etc/pam.d/chsh in my alpine container
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago(edited)
@dustinvb can i unexport an env? (E.g. cf_unexport) 😃
dustinvb
dustinvbover 7 years ago
Sorry no, not a feature at this time.
rss
rssover 7 years ago
Codefresh Incident
Mar 19, 15:53 UTC
Investigating - We are investigating an issue on our platform that is affecting build functionality.
We will go to provide more information here as investigation progresses.
rss
rssover 7 years ago
Codefresh Incident
Mar 19, 16:15 UTC
Monitoring - There was an issue during a DB upgrade process.
The issue was quickly identified and now is resolved.
But we'll keep monitoring the platform to ensure it is working as expected
Mar 19, 15:53 UTC
Investigating - We are investigating an issue on our platform that is affecting build functionality.
We will go to provide more information here as investigation progresses.
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
dustinvb
dustinvbover 7 years ago
This should give you a semi reasonable estimate based on commits to your org repos and the total across all of them.
dustinvb
dustinvbover 7 years ago
Yes, our SaaS model gets you out of maintenance and gives you a team of support engineers on our side to assist you if you do run into anything.
dustinvb
dustinvbover 7 years ago
I encourage you to reach out to michael.schaaf@codefresh.io to ask any questions about pricing.
dustinvb
dustinvbover 7 years ago
dustinvb
dustinvbover 7 years ago
I haven't had much success with it.
dustinvb
dustinvbover 7 years ago
OH well... If you can manually count then probably wouldn't even be a metric to concern yourself with. Instead look at concurrency and the runtime sizes memory/compute for each pipeline.
dustinvb
dustinvbover 7 years ago
Jenkins is a bit brittle.
dustinvb
dustinvbover 7 years ago
I've done it. Terraform + Chef and then ran all the builds from Docker. It was better but I still had to deal with things like the Maven plugin...
dustinvb
dustinvbover 7 years ago
Not true
dustinvb
dustinvbover 7 years ago
Easy to roll in anything you're doing on the Linux Slave with Jenkins over to an Ubuntu or CentOS Docker image and incorporate that same scripting and push binaries. That's supported.
dustinvb
dustinvbover 7 years ago
Depends, we have customers that push jars for example that are used by their customers that are not focused on the Docker artifact. I think it depends on what your plan is for the artifact. If it makes sense to run in a container and it is possible that's an optin.
dustinvb
dustinvbover 7 years ago
Yup, and if you're like me you already have the scripting in version control in something like a make file.
dustinvb
dustinvbover 7 years ago
Just leaving the item of building the slave Docker image by running apt-get and other package solutions to prepare the image for the build. Then you can use that in a multistage later on.
dustinvb
dustinvbover 7 years ago
Yes we have several
dustinvb
dustinvbover 7 years ago
dustinvb
dustinvbover 7 years ago
Check the blog here.
dustinvb
dustinvbover 7 years ago
@Kostis (Codefresh) Is our technical writer and does the comparisons posted on the blog if you have any questions.
dustinvb
dustinvbover 7 years ago
2 builds, but could restrict this to not create on specific events.
dustinvb
dustinvbover 7 years ago
Say if you have filter on commit and PR open, the commit would have already built unless you wanted to do more in regards to a commit pipeline vs. pr pipeline. Then you'd add pull request synchronized event to build on your commits to existing PR.
dustinvb
dustinvbover 7 years ago
Oscar, I'd suggest emailing Michael about the pricing. He can work with you in regards to concerns around these soft build limits in our plans and find you a plan that fits your budget.
giphy
giphyover 7 years ago
giphy
giphyover 7 years ago
dustinvb
dustinvbover 7 years ago
Not you ☝️ ?
dustinvb
dustinvbover 7 years ago
Oscar, Michael has confirmed there is alternative plans he can discuss with you. Just FYI.
rss
rssover 7 years ago
Codefresh Incident
Mar 19, 19:11 UTC
Update - We're still working on resolving some performance issues.
We're constantly monitoring the system.
Once all minor issues are fully resolved, this incident will be closed
Mar 19, 16:15 UTC
Monitoring - There was an issue during a DB upgrade process.
The issue was quickly identified and now is resolved.
But we'll keep monitoring the platform to ensure it is working as expected
Mar 19, 15:53 UTC
Investigating - We are investigating an issue on our platform that is...
rss
rssover 7 years ago
Codefresh Incident
Mar 19, 19:46 UTC
Resolved - The issue is now resolved.
Performance is now at expected levels across all the platform.
We're going to keep monitoring the system to ensure a consistent behavior in terms of performance
Mar 19, 19:37 UTC
Update - UPDATE: we're currently performing a DB-upgrade operation as part of the actions to resolve the current performance issues
Mar 19, 19:11 UTC
Update - We're still working on resolving some performance issues.
We're constantly monitoring the system.
Once...
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
you can definitely have it source controlled
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago(edited)
3 ways to define it:
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
- 1) inline using UI (great for debugging, but not as a workflow)
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
- 2) from a remote URL
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
- 3) from source control (how we typically do it)
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
you can also even define your pipeline creation process as code as we do here:
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
erik
erikover 7 years ago
dustinvb
dustinvbover 7 years ago
I already booked the time to attend! This is a do not miss in my book.
Avineshwar Pratap Singh
Avineshwar Pratap Singhover 7 years ago(edited)
Noob question: Hoping to understand (read if there is a resource already) the motivation behind creating codefresh. Just to be clear, this is not an ask what is codefresh but more around the lines of what kind of issues it tackles better.

@Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
@Avineshwar Pratap Singh can you ping me on Monday? I am AFK.
Avineshwar Pratap Singh
Avineshwar Pratap Singhover 7 years ago
@Erik Osterman (Cloud Posse) looking forward! 👍️
dustinvb
dustinvbover 7 years ago(edited)
Codefresh tackles the move from VMs to micro-services supporting build, test, delivery and deployment of micro-services using micro-service based pipelines built upon a scalable platform meant to scale as micro-services emerge which require 10x-1000x the amount of builds in a CI/CD platform as your typical Legacy build VM based applications. Each micro-service can bring in it's own version of a programming language (best for the job) leaving it up to a VM to build and test offers little flexibility to remain as agile as today's containers allow. Using a pipeline built out of micro-services gives your CI/CD the same flexibility as the applications you're building. Around all of this Codefresh has build a UI that integrates with your Version Control System and Kubernetes. Giving you a soup to nuts view of your CI/CD around containers and Kubernetes. We also provide private Docker registry to aid in your archive/deployment of Docker containers. Please see https://steps.codefresh.io/ for a listing of some of the provides micro-services you can include as steps in your pipeline and of course to this document about Codefresh pipelines: https://codefresh.io/docs/docs/configure-ci-cd-pipeline/introduction-to-codefresh-pipelines/
casey
caseyover 7 years ago
has anyone used chamber in a codefresh pipeline to inject secrets into helm chart? Wondering whats that best approach for this?
casey
caseyover 7 years ago
never mind found a link in the docs, here is reference for anyone who cares
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
if you run kubectl get pods --all-namespaces, what do you see?
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
@Andriy Knysh (Cloud Posse) others have had trouble with getting nodes registered
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
What does get nodes show?
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
kubectl get nodes
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
(On phone)
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
for worker nodes to join the cluster, you need to apply that config map
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
either using the example code, or manually
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
let me know if that still is not working
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
it was tested about 2 months ago, was ok
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
but recently a few people reported issues with workers joining the cluster
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
so if you have the same issue, I’ll have to look into that
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
@Andriy Knysh (Cloud Posse) ☝️
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
i saw that
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
as i mentioned, we did not see issues like that before
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
@oscarsullivan_old try the example and let us know
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
i think geodesic has an ENV var for that, @Erik Osterman (Cloud Posse) do you remember which one?
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
(or maybe it’s just for kops)
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
It’s a kubectl env
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
Yes
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
That one
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
@Andriy Knysh (Cloud Posse) what’s the path setting g for the module
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
That is what should change to dev shm
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago(edited)
with var.apply_config_map_aws_auth` set to “true”
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
@Andriy Knysh (Cloud Posse) Where does the module write the config?
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
you specify the path
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
Can we specify then dev shm?
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
kubeconfig_filename = "${path.module}/kubeconfig${var.delimiter}${module.eks_cluster.eks_cluster_id}.yaml"
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
need to change that to a var
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
do you see the workers?
Erik Osterman (Cloud Posse)
Erik Osterman (Cloud Posse)over 7 years ago
@Andriy Knysh (Cloud Posse) can you update the issue with this new information ?
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
i can update the issue, yes
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
but i pointed out a few times there to do what @oscarsullivan_old just did 🙂
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
so either that did not work for them, or something else was wrong
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
as i remember there were some thoughts around that, but don’t remember exactly the details 🙂
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
is it your image?
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
i think you need to deploy Docker pull secrets to k8s https://github.com/cloudposse/charts/tree/master/incubator/dockercfg
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
1 sec
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
yes
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
when we deploy an app to the cluster, we usually create a helmfile in the same repo
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
we call it Helm Cartridge
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
the helmfile deploys the pull-secret chart and then the app chart
Mark Grube
Mark Grubeover 7 years ago
I went through this a little while ago, I created a secret in the namespace I was deploying to
kubectl create secret docker-registry ${name_of_secret} --docker-server=<http://r.cfcr.io|r.cfcr.io> --docker-username=${codefresh_username} --docker-password=${codefresh_cr_generated_password} -n ${namespace}


Then when you deploy you have to set the imagePullSecret in the Deployment spec
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
k8s itself needs permissions to pull images
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
(that’s for @oscarsullivan_old ^)
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
when pulling the image during deployment
Mark Grube
Mark Grubeover 7 years ago
yeah thats the pull secret that you upload as a secret to kubernetes
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
it has nothing to do with Codefresh, which just sends k8s resource definitions to the cluster, the cluster itself pulls the images
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
yes, it does the same as the chart
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
(too many moving parts 🙂 )
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
For a quick test, do what Mark showed
Andriy Knysh (Cloud Posse)
Andriy Knysh (Cloud Posse)over 7 years ago
We use the chart and the helmfile to automate all of that
Mark Grube
Mark Grubeover 7 years ago
thats the token
Mark Grube
Mark Grubeover 7 years ago
its whatever you set here
Mark Grube
Mark Grubeover 7 years ago
right now it would be your username, unless you have a service account
Mark Grube
Mark Grubeover 7 years ago
in the future I think they are going to allow you to generate users for CFCR that are not tied to an individual user
Mark Grube
Mark Grubeover 7 years ago
yup, I referenced it in the helm chart
Mark Grube
Mark Grubeover 7 years ago
in the Deployment spec
Mark Grube
Mark Grubeover 7 years ago
if you are not using helm you can just set it in the deployment spec itself https://kubernetes.io/docs/concepts/containers/images/
Mark Grube
Mark Grubeover 7 years ago
cat <<EOF > pod.yaml
apiVersion: v1
kind: Pod
metadata:
  name: foo
  namespace: awesomeapps
spec:
  containers:
    - name: foo
      image: janedoe/awesomeapp:v1
  imagePullSecrets:
    - name: myregistrykey
EOF
Mark Grube
Mark Grubeover 7 years ago
here is an example for a pod from their documentation
Mark Grube
Mark Grubeover 7 years ago
myregistrykey would be the name of the secret you created in the namespace