Reddit DevOps
268 subscribers
30.9K links
Reddit DevOps. #devops
Thanks @reddit2telegram and @r_channels
Download Telegram
Question; What are some simple DevOp rules all Web Apps and Websites should follow?

I.e.

1. never editing the production server directly
2. using certain GIT branches for X, Y and Z
3. etc.


I'd love to learn more about this stuff.

https://redd.it/gbn212
@r_devops
Swarmlet - A self-hosted, open-source Platform as a Service based on git and Docker Swarm

Hi r/devops ! I wrote a Heroku/Dokku-like tool for easy app deployment and Docker container orchestration when working with a personal server cluster (it also works fine on a single server).

[https://swarmlet.dev](https://swarmlet.dev/)

[https://github.com/swarmlet/swarmlet](https://github.com/swarmlet/swarmlet)

Swarmlet is a thin wrapper around [Docker Compose](https://docs.docker.com/compose/) and [Docker Swarm mode](https://docs.docker.com/engine/swarm/).
[Traefik](https://github.com/containous/traefik), [Consul](https://www.consul.io/), [Let's Encrypt](https://letsencrypt.org/), [Matamo](https://matomo.org/), [Swarmpit](https://swarmpit.io/) and [Swarmprom](https://github.com/stefanprodan/swarmprom) are included by default.
Swarmlet uses these to provide automatic SSL, load balancing, analytics and various metrics dashboards.

The project is WIP, please let me know if you have any comments or feedback!
Don't hesitate to contact me, this is a **learning project** (a few weeks ago I knew nothing about Docker Swarm mode).
I'm definitely no expert yet, so lots of things to improve.
If you're interested, I'd love to collaborate.

https://redd.it/gbfask
@r_devops
Looking to become a devops team lead

Hello everyone,



I'm thinking of becoming a devops team lead. What are your suggestions and how did you make the jump?



Thank you

https://redd.it/gbft2f
@r_devops
Getting started with Docker Compose - Video Demo and Companion Repo

Have a look at the video tutorial and clone the companion repo to follow along! This is aimed at beginners to Docker and Compose but those with some experience might find some tips in there as well.

https://www.youtube.com/watch?v=\_EV5jLtWX8k

https://redd.it/gbecsq
@r_devops
User Input in order to configure different configuration files for multiple containers

I was successfully able to create a `docker-compose.yml` for the Telegraf-InfluxDB-Grafana-Mosquitto Broker stack.

I need some understanding as to how can I request User input before spinning the containers.

Within the `telegraf.conf` which is a TOML file I need the user to map one-to-one information as follows:

```
sensor_name_1 = meta-data_1
sensor_name_2 = meta-data_2
```
This is part of the [enum processor for telegraf](https://github.com/influxdata/telegraf/tree/master/plugins/processors/enum)

I looked into Jsonnet, which currently has a PR regarding TOML unmerged. But I am not sure where will Jsonnet fit in this scenario?

What are other options that I can look into?

https://redd.it/gbeabo
@r_devops
Saving Your Linux Machine From Certain Death

Hi, /r/devops

Today I published my new article on how to troubleshoot and fix some common problems with Linux systems, like recovering root password or fixing unmountable filesystems and I think it might be useful for some of you here.

Here is a link:

https://medium.com/better-programming/save-your-linux-machine-from-certain-death-24ced335d969

https://redd.it/gbcwvs
@r_devops
Terraform AWS FIPS provider

Hey guys, this was a royal pain in the ass to type up and I figured you guys may find it helpful. I've had some compliance requirements and FIPS 140-2 validated encryption is a requirement. I went through the AWS docs and got every AWS FIPS endpoint into the AWS provider.

You can maybe modularize something like this but I haven't ever tried setting up a provider in a module so I'm not sure if that's possible.

Here's a blog link: https://blog.kwnetapps.com/terraform-aws-fips-provider/

Here's a link to the github repo: https://github.com/Kaydub00/terraform-aws-fips

Now, there's probably more to meeting these requirements for your org, but if you need to meet these requirements and you're using TF and AWS you'll need this. Granted I've never been asked by an auditor to see this stuff, you may get an auditor who knows their stuff.

https://redd.it/gc9lie
@r_devops
Can't link Git repo on Jenkins

Hello guys,

I'm trying to link my git repo to jenkins, and getting the following error.

**Failed to connect to repository : Error performing git command: C:\\Program Files\\Git ls-remote -h https://github.com/xxxxxxxxxxxxxx/xxxxxxxxx.git HEAD**

What am I missing here? I started leaning DevOps recently and still practicing few things. Please excuse me if it's just a silly doubt.

​

Namaste!

https://redd.it/gcacoy
@r_devops
Container environment variable

I'm running an ECS Fargate Task.

This is my Entrypoint script in the Dockerfile

startapplication.sh :

#!/bin/bash
set -e
java -jar test.jar --spring.profiles.active=${envparam}

and then I go to AWS ECS Fargate web console > Task Definition > Container definition > declare environment variable "envparam" and value "dev" there.


But ${envparam} in shell script is not resolving when container launches. What is the issue ?

https://redd.it/gc93ir
@r_devops
What are all the alternatives to Jenkins?

Current Technical stack: Python, Java, Scala and NodeJs
Please suggest a commercial and Easy to setup/maintain kind of alternatives.

https://redd.it/gc6ylv
@r_devops
Good tool for monitoring .net app/infrastucture on Azure

I've been using Zabbix in Linux for years and I'm now tasked with adding monitoring to a web app with a .net backend that is hosted in Azure. What are people using to monitor their .net/Azure apps? Ideally it would be opensource or not too expensive and support the standard system metrics such as CPU, mem, storage, I/O and then custom app metrics.

Thanks ahead of time

https://redd.it/gc71gh
@r_devops
Creating a premade work environment similar to Docker

Sorry if I am posting this in the wrong thread. So I just learned about Dockers and started getting them setup for my work projects and everything is working great. After learning about them I was wondering if there was something similar that could be implemented for our development team. So the issue we run into whenever we hire a new developer or get a computer upgrade is that we manually have to go through and install everything needed for these computers to be setup. Github, Putty, SSH Keys, Virtualenv, etc. Is there a way to do the same thing that Docker but in a regular format? By that I mean no need for Docker itself with containers since all our work computers are Windows based.

In simplest terms, I am looking to do something like Ninite but not as fancy as a UI just a script. I know I can do it through a bash script just wanted to check if there were other ways before I take that approach.

https://redd.it/gca7sy
@r_devops
recommendations for a good cloud service that can analyze data posted to it?

first of all, I'm just a programmer, not a dev op - so please keep that in mind, I don't really even know if this is the place to ask such a question so please point me to a better place if there is one.

I'm looking to send a web request possibly POST or GET, not really sure which one as possibly only one of them might work...

which will contain some text data, maybe json maybe xml - doesn't really matter, I can send either.

I then want to use some professionally hosted service that I just create an account with and they give me a url and I send the POST or GET to it and it then can parse this data and store it and, crucially, be able to make charts from it.. being able to send notifications based on the data would be nice too.. ability to use formulas as conditions would be great.

so I would then have a webpage I could navigate to to look at the chart of the data that is constantly being submitted

Can anyone give me some good suggestions? thanks

https://redd.it/gc7ztg
@r_devops
Do you help architect new applications?

What level of input do you have when it comes to influencing the architecture of new applications?

My team have little to no input on how new systems are designed.

This feels quite frustrating because the decisions taken by each application team have an obvious impact on my team when it comes to running them in production.

In addition to this I feel that some of the members of my team have a significantly better understanding and experience of architecture best practices than those who are actually making the decisions. Which to me seems like a waste of talent.

I guess if we were doing this right someone in Ops would be included in the early part of each new project? The reality seems to be we don’t know much about it until someone wants it deployed to a hosting environment.

Having a particular application team “hold the pager” isn’t really an option unfortunately.

Is this a common experience for anyone else here?

I’d be open to suggestions on how to change this but my hunch is that a large part of the problem is down to politics at a leadership level. It’s late and I need some sleep so I’ll leave it at that.

https://redd.it/gc4rc3
@r_devops
[Shifting to Devops]

Hi All I have a small question for you all DevOps here

I have now 6+ years experience in systems administrator and I'm looking to shift my career path definitively to DevOps.

I have experience with servers, load balancing, SaaS, python, PowerShell, bash.

​

The problem is that when I look for junior DevOps jobs they always ask for 1 or 2 years of experience with orchestration software (like ansible terraform, dockers etc.).

What's the natural way to gain that "experience" if you are applying for a junior position?

I think 1 or 2 years of experience should not be junior at that point anymore, should junior be an entry point for someone that has a solid of sysadmin/programming base and willing to learn?

​

Thank you for your time and help.

https://redd.it/gc4h5o
@r_devops
Switching from Software dev to dev-ops in Covid-19 World

I am a former application software developer with 20 years of experience looking to start a new career in DevOps. It's a tough world we live in now, but I am very eager to see how I can start as a junior DevOps guy as a former software dev. I have all the Udemy courses and have started my DevOps journey with learning CentOs Linux (come from Windows/.Net dev background) and would love to know in today's COvid-19 world how a newbie to DevOps could put his foot in the door; there are so many technologies its a bit overwhelming.

- Learn Linux /CentOS
- Learn Python well enough to write scripts
- Docker
- Kubernetes (Most my courses are Docker + Kubernetes, why?)
- AWS (or major Cloud platform of choice, I am choosing AWS , try to get DevOps cert)
- Learn Git in Depth

Any info about Ansible, Terraform, Jenkins or other stuff?

Looking for insight in what to learn and how to break in.. Thanks.

https://redd.it/gc2lo5
@r_devops
Packaging builds as RPMS as a deployment mechanism

More than a decade ago I setup an rpm build server just using scripts and pulling from subversion. Since then I have not had to chance to revisit using RPMS as a way to deploy my builds and have done what most folks do to publish artifacts via ssh and other ways using Jenkins.

Are there still folks here who go through the RPM way? I.e. build the final product as an RPM and deploy it that way and just copy the rpm to the repo? If yes I would love to hear your use cases.

https://redd.it/gc4e3h
@r_devops
CI/CD setup using Docker and Kubernetes

I am trying to set up a simple CI/CD workflow and I would like to represent both Docker and Kubernetes. Is my set up correct?

The simple set up is below, (You can skip the story and directly see my CI/CD workflow [image](https://imgur.com/a/xAt69Jh))

The developers' code is pushed into the Git; the build and test will happen from Maven and Jenkins for CI. Ansible as a deployment tool, we will write Ansible playbooks to deploy on AWS. We will introduce Artifactory as a repository manager, after the build process from Jenkins; the artifacts will be stored in the Artifactory. Ansible can communicate with Artifactory, take the artifacts and deploy them onto the Amazon EC2. The SonarQube can help in reviewing the code and will give static code analysis. We will then introduce Docker as a containerization tool. Just like the way we did on Amazon EC2, we will deploy the app on Docker container by creating a Docker file and Docker images. Once this setup is done, we will introduce Kubernetes to create a Kubernetes cluster, and by using Docker images, we will be able to deploy.

Is my set up correct? Am I missing something?

Please help and advice me to get this done.

https://redd.it/gc1r41
@r_devops
Terraform Cloud Thoughts

Hello,

For some time now, we've used CloudFormation to provision in AWS. However, I'd like to integrate Terraform for various reasons. I've created at least one project locally on my PC for doing some initial testing. I'm setting my sights on a team environment next.

From reading, I see we can use the Terraform command line in conjunction with a remote backend, probably S3 with a Dynamo for locking. However, I'm looking into Terraform Cloud, which seems to do most of what we are looking to do. As well, it also seems to do a CI/CD as well, hooking directly into our GitHub and our AWS environment.

We already use Azure DevOps some for making pipelines for our CloudFormation pushes. What are thoughts around using Terraform Cloud? In general, for what we are doing, does it seem like it is a best route to take? Or, since we have another pipeline tool that does not revolve around Terraform specifically, should we look at staying the course with Azure DevOps and implementing a remote backend that we'll maintain?

Pros, cons, and input from experience are all welcomed. I want to ensure I've considered all aspects before we decide on a direction.

Thanks!

https://redd.it/gbzff7
@r_devops
Forward site traffic to nginx docker

Hey all new to Docker here!

I have a scenario where I want to type in a domain name and have that go to my docker container which is running nginx and then have nginx serve up the web app. I need to use this as a test case for another platform I work on because I need url's to resolve properly with server configs. So for example www.mysite.com should go to nginx in my docker container. Wondering if this is possible? Thanks

https://redd.it/gbyrgm
@r_devops
DevOps job market and lifestyle in different international cities

I wanted to get your opinion on the city you live in:

* How easy is to find a DevOps Role?
* How enjoyable is the city you live in? Socially and otherwise
* What's an average salary in your city and how does it compare with how expensive everything is? In other words, what's your standard of life like there?

I live in London and while I don't hate it here, I am a little tired of it so I was considering other cities like Berlin, Madrid, HK, Zurich, Tokyo, San Francisco... which is why I would love to hear from you, especially if you have also lived in London and can compare it.

I will share my experience of London first, in case you are thinking of moving here:

In London there is an insane amount of work in DevOps, if you have a little experience and you convey yourself well in interviews you can get a job in a couple of weeks or even less. My LinkedIn is continuously buzzing with recruiters approaching me with opportunities, which admittedly some of them may be a bit crappy or a dead end, but many of them will land you an interview. If I put my CV in monster or any of these job search sites it gets even crazier; I get completely overloaded with recruiter calls and companies offering me jobs to interview for. I counted about 35 calls in a day once. This is not a testament of me being amazing or having the best CV in the world, it reflects the experience of many people who work here in DevOps type of roles.

I heard many engineers complain about recruiters being misleading and wasting your time, and I can agree with much of that but generally I think this is a good problem to have. It's good to have plenty of options and never have to stress about ever finding a job, even if not all jobs are dream jobs.

So in that sense London is great, however in terms of quality of life is another story. The pay in London isn't bad (the average is somewhere between 45 to 75K pounds, but when you consider how insanely expensive housing and transportation is, it's not such a great deal to live here. Even making a decent 65 or 70K a year, you can easily spend half of what you make after taxes in rent and related expenses if you don't want to live a million miles away from work or in a miserable flat, or have flatmates.

Also, even though there is a lot to do in London, I am not a big fan of the social dynamics in this city. For example when I worked in Madrid for a short contract people would constantly invite me out to hang out, to weekend parties and such, it just felt much more natural. For example when they asked "How are you?" it was a genuine question, not like the mechanical version you get in London. In London socialising always feels really forced, downing pints with colleagues after work and then go home. Almost every office I worked at always feels very impersonal too (saying hi to people in the kitchen often feels like nodding someone you met once on the street), after many years here I don't feel I have made many meaningful relationships in this place, but this may be entirely my opinion and experience on London.

So in a nutshell, London is great for work and career development, for quality of life is below average.

Would love to hear your opinions and experiences in this of other cities!

https://redd.it/gctdu7
@r_devops