Reddit DevOps
274 subscribers
65 photos
32.1K links
Reddit DevOps. #devops
Thanks @reddit2telegram and @r_channels
Download Telegram
Redis diskless replication: What, how, why and the caveats

[deepsource.io/blog/redis-diskless-replication/](https://deepsource.io/blog/redis-diskless-replication/)

This excerpt aims to address the working and potential of diskless replication in production environments.

https://redd.it/g43u44
@r_devops
Learning DevOps on the cloud

Brief context. Stuck overseas for work with very limited resources in terms of a physical computer. Dell laptop running WSL2. Dual boot with Ubuntu had far too many issues. Should have a fair amount of time to work on DevOps skills as well as some more DB and software engineering tasks.

Any thoughts over which platform like Digital Ocean, AWS, Linode would be the most cost effective and allow me to workon things like:

Ansible, Graffana, Terraform, Docker, Git (for ansible I'm assuming I need to spin up various servers/droplets, etc to make any realistic workflow. )

And from the coding side I'd like to work more on reddis, mongo, OpenCV/Tensorflow.

Thanks for any assistance.

https://redd.it/g43i1x
@r_devops
linuxacademy hands on labs experience not great so far

I have completed 2 labs so far, one is AWS S3 introduction, and another lab on Linux task where I have to set up auto email notification via ssh login. During both labs, I found there are sections of guide where it is out of date with how the programs functions, or lack instructions. On both occasions I had to figure out the general direction of what the guide ask me to do, then figure out the new way to do it. The video included in the hands on lab is also laughingly out of date, as the current AWS web UI look nothing like it anymore.

Great if this is by design to train people to find the right answers, not so great as a step by step hands on follow exercise. I think the site need to keep their hands on labs updated.

https://redd.it/g3xtx7
@r_devops
Kubernetes RBAC Demystified

Want to share a really cool capability added to Kubevious. Makes consuming Kubernetes RBAC (Role, ClusterRole, Binding, ClusterBinding) so much easier by just seeing what permissions are set on the application level without the need of querying bunch of objects and tracing labels.

Also, with a single glance can identify if there is some workload within the namespace that has access to API resources beyond the namespace.

[https://youtu.be/0Gd6VRTigoE](https://youtu.be/0Gd6VRTigoE)

https://redd.it/g3zzxs
@r_devops
Docker-compose in production: Viable?

Hello,

We have made a transition from vagrant to docker-compose for our local development, and we are quite happy with the result. We have 10 dockerized services, communicating neatly and working perfectly locally, all behind a Traefik router.

Now, we would like to move from our current bare-metal deployment and use our containers in our staging/production servers as well.
We are not interested in service replication just yet, we just want a solution that can be deployed easily and that mirrors our local experience. It seems that docker-compose can effectively be used in production as well, but is there any downside to it? Should we use Docker Swarm with a single machine instead? Use K8s?
We use DigitalOcean as a cloud provider.

Thank you.

https://redd.it/g3w69h
@r_devops
Vault on AWS - A Terraform Project for Secrets Management Anywhere

Hey r/rdevops,

I put together a Terraform project that automates a secure deployment of HashiCorp's Vault on AWS. After deploying this project you'll get a URL that you can then start managing secrets with through the Vault CLI or HTTP API. There's a lot of configurable options in the project that will let you scope the URL to specific IP ranges or even just keep it completely private and only available to other AWS VPCs.

[Vault on AWS Github Repo](https://github.com/jcolemorrison/vault-on-aws)

https://redd.it/g3t3c8
@r_devops
How do you handle concurrent changes in your IaC repo that target different environments?

A colleague of mine asked me a question the other day for which I didn't have a good answer, and I'm wondering how you all handle similar situations.

We're using Terraform to do some deployments, and we've got currently got things set up for 2 environments, staging and prod. If you start making some configuration changes to test in staging, but then need to make a hotfix for prod (without also merging in those changes for staging), how do you handle this case? To be clear, we're talking about small changes here, like configuration tweaks; for bigger changes, we spin up separate, temporary testing environments.

I know that, ideally, you want to have all environments use a single branch, and use variables to customize the deployment for each environment. But if you need to keep `master` clean for potential hotfixes, how would you push changes to staging? In practical use, do you have a branch or subfolder for each environment?

I suppose we could use a feature flags approach and have a bunch of ternaries in the actual resources, but I feel like that would muck things up quickly.

The same question applies to modules that your root Terraform is using. If your module needs to publish a new hotfix version for prod, but you want to test some changes in the module for staging, what do you do? If you create a feature branch in the module for the staging changes, you then run into the problem in your root repo that you can't use a single branch / folder again, since you'd have differing sources for the module between prod and staging.

https://redd.it/g3xbe2
@r_devops
How to sync app store/play store updates with server deploys that contain a backward-incompatible change?

Hello, I suppose this is the right subreddit to ask this question?

---

I maintain an app that runs on both ios and android and communicates to a server.

---

I am using automated CI/CD deploys, for both the server and ios/android apps.

The server deploys are instant (after docker build) because I own and control my VPS.

However, the app stores generally take a few days to publish the app.

Especially in apple's case, we routinely encounter speed bumps.

---

So how do I make sure that the server doesn't get deployed before the app is available to the public, especially when I have made a backward-incompatible change to the API?

https://redd.it/g3uxzt
@r_devops
Examples how to use Pulumi fo AWS

I am interested in using Pulumi (Python interface) but can't find good docs how to use it . E.g. how to create network (VPC, subnets, NAT gateways etc.) in AWS with it?

Could somebody share some usable docs? Any AWS related and Python Pulumi.

Posted on Pulumi site looks pretty basic and all of them uses default VPC.

https://redd.it/g3uopo
@r_devops
Stuck with no way back

Hello everyone, trying to create multi LAMP stack with vagrant and basically , I am stuck and nothing is working :D Any tutorials you could suggest for the multi machine ansible setup?

​

Project here:

It's messy because my brain is fried [https://github.com/RausisM/tryingtosurvive](https://github.com/RausisM/tryingtosurvive)

https://redd.it/g4spjm
@r_devops
Cisco Prime, pythons Nornir, or Ansible for network config mgmt

Hi guys, I am a network engineer who has been using python libraries for simple network config changes or show commands. The libraries I have used in production are netmiko and paramiko both with multi-threading when I need to run a script on multiple devices faster.

I have used ansible In a virtual environment but not production. I’m not to strong in Linux at the moment so I use ansible in a virtual Ubuntu environment so I don’t break my production.

I am currently learning Nornir and liking it more than ansible.

My job wants me to automate network configs back ups/ schedule them. They don’t want to buy solarwinds NCM and want me to try using our current Cisco Prime software. I don’t really like it and prefer NCM. Is it worth using Cisco Prime and learning it. Because I would rather go the either the Ansible or Nornir route and I feels it has more flexibility and it’s open source.

I plan to make a web api flask or dgango so that others in my Dept can use the python scripts without having to know the backend.

What do you guys think? Learn Prime and do the config mgmt/scheduling with it or continue with the python based scripting. Also which is more recommended right now Nornir or ansible. I am biased on which one so would like opinions from those that have been down this road already.

https://redd.it/g4vnz4
@r_devops
Slack actions to a private server

Hi I am new to devops and want to do simple tasks via slack, problem is my server is in a private subnet.

​

I am able to send notifications to slack via an internet gateway, but can't do actions towards a notification i.e service restart, logrotate, approve and decline jenkins deployment

​

My idea is to poll messages via crontab with a curl that sends keeps monitoring a channel for new chat messages, but implementation would be messy and I know would cause some type of overhead

​

I slightly understand that all polling actions have overhead, but hope anyone has a suggestion on how to do this more 'gracefully'

https://redd.it/g4urdi
@r_devops
General experience with datadog log agent performance?

Curious if anyone could speak to the how performance the datadog agent is for gathering system logs. The agent appears to be written in python. Looking to move .5 terabytes of logs/host.

https://redd.it/g4zcuj
@r_devops
How-to build a Docker image(using Github Actions) and run it using Azure DevOps [Article]

Hello.
Wrote two articles about using CI/CD for working with Docker:
* [Github part](https://github.com/groovy-sky/azure/tree/master/iac-02#introduction)
* [Azure DevOps part](https://github.com/groovy-sky/azure/tree/master/iac-03#introduction)

https://redd.it/g4y5nw
@r_devops
s3cr3t: a supercharged S3 inverse proxy. Feedback is highly appreciated!

Link to Github: [https://github.com/axl89/s3cr3t](https://github.com/axl89/s3cr3t)

​

After the good people of NGINX released a lot of free resources because of the current situation, I ran into the **ngx\_http\_secure\_link\_module** module ([link](https://nginx.org/en/docs/http/ngx_http_secure_link_module.html)), which existence was unknown to me.

After playing with it a little bit, an idea clicked inside my head to develop an easy "Download server" with an S3 bucket as the backend with 3 basic restrictions:

* Client IP address
* URI
* Expiration time

I found this development super interesting and fun, and I'd love to hear from you. Let me know your thoughts and feel free to contribute! :)

https://redd.it/g4ziaz
@r_devops
Places to find DevOps work, preferably in management or leadership?

Looking for a new opportunity. Besides Linkedin, and the common boards (indeed, ZipRecruiter, Dice, etc) is there another site I’m missing to find good opportunities?

https://redd.it/g4wvjn
@r_devops
Mixing declarative infrastructure plus deploy scripts... suggestions or alternatives?

I have an application that has 1 image but several (over 20) different ECS services per environment. The services mostly share a common set of environment variables and secrets, with some small differences due to each service starting up a different process, using a different DB, etc.

I tag the image with the commit SHA. I do not want to use \`latest\`.

I currently manage the infrastructure (ALBs, Task Definitions, Services, Roles, etc.) in Terraform, and deploy by updating the Task Definition and Service with the API. However this means that even though I use a script to tell Terraform what the current deploy is, the state is old and it requests an update.

I'm looking for a better way to do this. It seems wrong to be managing the task definition state in two places (Terraform and deploy script). I like having something like Terraform state to keep track of my resources so I can be declarative vs. writing standup and teardown scripts. I want to, for example, have a resource removed when I remove it from code, not by running a cleanup script.

As mentioned, I'm using ECS and Terraform right now, but I see this issue when I'm looking at tools like CDK, Pulumi, and Kubernetes as well. How are people managing this difference between declaring infrastructure but deploying via scripts?

https://redd.it/g52xvc
@r_devops
Direction to move to improve on Docker based personal cloud VPS

Hi everyone,

I'm running a little VPS with Docker to host, among others, nextcloud, gitea, caddy webserver, bitwarden password container, syncthing service, ... all proxied through a traefik container. For most of the containers I'm using docker-compose files with docker swarm in a single-node setup. It's all working nicely so far, but I feel that I'm not doing it optimally yet. For some services, that I would like to try out, a docker image is not readily available and building a proper docker image using docker files can be a hassle because one has to worry about how the image is layered etc, instead of just booting up a VM and install it like on a bare-metal server. Other services, like bigbluebutton, don't like being deployed in containers at all.

I'm wondering therefore if I should look into microvms like firecracker or other means of separating my services from each other (which is from my point of view the biggest advantage of using containers / vms at all). At the same time I also don't want to loose handy integration of a container runtime with my reverse proxy service, that automatically generates rules for newly started containers. So given that docker is getting less relevant as orchestration tool due to kubernetes, perhaps I should look into single-node kubernetes setups instead?

I hope you somehow got a feel of my predicament and I welcome any (justified) recommendation in which direction I should go next.

https://redd.it/g52lyc
@r_devops
Considering creating an automation tool - looking for volunteers to interview for market research

I'm a software developer and I have an idea for a product targeted at development teams. I want to do my due diligence and validate that there is indeed demand for the product. Would anyone be willing to take part in a \~30 minute interview to help me out?

Specifically, I would need people who are familiar with the automated steps that occur on their company's repositories (eg. build pipeline, dependabot)

If you fit the above description, please reply or message me. I would absolutely be willing to return the favor in any way I can help (eg. offer the product to you for free if/when it launches, participate usability interviews, etc.)

https://redd.it/g52a3v
@r_devops