Live data from Hacker News

Ask HN: Developer PC setup automations for company owned devices

news.ycombinator.com

31–40 of 51 posts

Re: Ask HN: Developer PC setup automations for company owned devices

#31
For software developers, `asdf`[0] and dockerized projects goes a long way. For provisioning the environment variables needed for development, HashiCorp's `vault`[1] can make that pretty simple. Combine that with `direnv` to have it load the value dynamically with:

```

# .envrc

API_KEY=$(vault kv get -field=API_KEY secret/projectA/dev)

```

I also wanted to experiment using `pass`[2] instead, but messing with GPG keyrings and the like is unwieldy and not too user-friendly. It's what I use for personal projects since Vault is overkill.

[0] https://github.com/asdf-vm/asdf

[1] https://github.com/hashicorp/vault

[2] https://www.passwordstore.org/

Re: Ask HN: Developer PC setup automations for company owned devices

#33
post #27

I would take "Now some people ask for an automation to get a "pre-installed" laptop" as a lack of " developers preferences". Personally I dislike Git, and haven't found a git UI I like, so throw whatever you want on there. I am not going to like it, but not because I want something else. Since you support a range of OSes I assume you would go with a cross platform editor IntelliJ, VSCode or something. Both are fine,…

> Personally I dislike Git, and haven't found a git UI I like, so throw whatever you want on there. I am not going to like it, but not because I want something else. I might be a bit off topic here, but if you haven't tried Lazygit yet, I can't recommend it enough.

Lazygit is fantastic. For a GUI I highly recommend sublime merge.

Re: Ask HN: Developer PC setup automations for company owned devices

#34

For software developers, `asdf`[0] and dockerized projects goes a long way. For provisioning the environment variables needed for development, HashiCorp's `vault`[1] can make that pretty simple. Combine that with `direnv` to have it load the value dynamically with: ``` # .envrc API_KEY=$(vault kv get -field=API_KEY secret/projectA/dev) ``` I also wanted to experiment using `pass`[2] instead, but messing with GPG keyr…

I believe there is `pass-age` https://github.com/FiloSottile/passage ... unifies to `ssh` keys as the key material.

https://github.com/FiloSottile/age

``` RECIPIENT can be an age public key generated by age-keygen ("age1...") or an SSH public key ("ssh-ed25519 AAAA...", "ssh-rsa AAAA..."). ```

Re: Ask HN: Developer PC setup automations for company owned devices

#35

After corporate IT gives out a MacBook, we run a local-only Ansible script I wrote. It sets .zshrc, .zshenv, and .zshenv-private for tokens etc. It also uses Homebrew to install a bunch of packages, then creates various config files. It works well. Developer setup time went from days to less than 2 hours (corporate VPN is slow) Edited to add: Workflow is: 1. Install homebrew, xcode command line tools, Ansible, and th…

I've never used Ansible. Is it worth using for just this workflow? I'm asking coming from a baseline of just having a Git-versioned shell script which has lines like

    brew install coreutils
and whathaveyou.

Re: Ask HN: Developer PC setup automations for company owned devices

#36

In my experience: 1. There's very rarely a one-size-fits-all solution, in terms of what people need. Oh sure, if everyone needs a VPN then you should install the VPN and suchlike. If there's mandatory corporate security software, add that as well. But will they need docker? Will they need virtualbox? Will they need VS Code? CLion? PyCharm? IntelliJ? Do they need Java installed? Which version of Java? Will they need A…

And then, in Windows, you likely want WSL, and you will likely need a mix of some tools in windows, some in linux and some in both. It can definitely get messy. That doesn't even count developer tool preferences.

I created a relatively long set of install instructions for Windows+WSL[1] a couple years ago and it's already outdated in a few areas. I mean most should be able to figure it out, but it just really varies a lot. Even with WinGet, Chocolatey, etc. Windows is just the odd duck here. Doubled with the Linux/WSL bits.

Linux is probably the easiest to script out, second would be mac imo, but need multiple steps with homebrew, etc.

1. https://github.com/tracker1/personal/blob/main/developer-set...

Re: Ask HN: Developer PC setup automations for company owned devices

#37

I would take "Now some people ask for an automation to get a "pre-installed" laptop" as a lack of " developers preferences". Personally I dislike Git, and haven't found a git UI I like, so throw whatever you want on there. I am not going to like it, but not because I want something else. Since you support a range of OSes I assume you would go with a cross platform editor IntelliJ, VSCode or something. Both are fine,…

I like git okay... mostly use the CLI for it. I do use the VS Code integrations sometimes though. A big part of why I like VS Code is the integrated terminal though.

Re: Ask HN: Developer PC setup automations for company owned devices

#38
post #21

I usually live in WSL2 on Windows running on company provided laptop. Each time the laptop has to be replaced (failure or age) I struggled to get my "home" back up so a couple of years ago I took a full day to setup my so-called "dot files repo". My goal was to be able to install any debian-based distro and run a single script, non-interactive, that would get me up and running. All that I needed to do was to clone co…

I have similar in a backup directory on my NAS. Works pretty well in general for getting my home directory up and good.

WSL, I usually have to make a few adjustments, mostly so that I can use the git credential manager installed in windows from Linux git.

Re: Ask HN: Developer PC setup automations for company owned devices

#39

IT here. Devs need to manage their own. We hook it into AD/AAD, EDR and Office 365. Dev enviroments THEY setup as THEY are developers. If then cant install some stuff can they even dev?

Setting up the environment for development, especially for onboarding, is a crucial operations step that allows the devs to stand on the shoulders of giants. If you're asking them to test in prod ( not providing a local test environment for component testing ) or reinvent the wheel ( and get the wheel type right... should I build a bicycle wheel or a railcar wheel? ) then the first week of a new hire is spent trying…

Depends on the size/scale of the larger org and the developer team in question. There's a lot of variance even in internal corporate tool teams as to what gets used. Are you supporting an older .Net Winforms app, or are you supporting a React/next application or a Java Spring app? The tools you need and use will be very different.

Is it really worth trying to automate everything for a team of 3 devs on a given project? Should this just be done by the devs on the project if that's the desired outcome?

Re: Ask HN: Developer PC setup automations for company owned devices

#40

After corporate IT gives out a MacBook, we run a local-only Ansible script I wrote. It sets .zshrc, .zshenv, and .zshenv-private for tokens etc. It also uses Homebrew to install a bunch of packages, then creates various config files. It works well. Developer setup time went from days to less than 2 hours (corporate VPN is slow) Edited to add: Workflow is: 1. Install homebrew, xcode command line tools, Ansible, and th…

I've never used Ansible. Is it worth using for just this workflow? I'm asking coming from a baseline of just having a Git-versioned shell script which has lines like brew install coreutils and whathaveyou.

You get the nice stuff that Ansible brings, like adding specific lines to .zshrc, templates, etc. I found it easier than my usually-beloved shell scripts because I didn't need to think about the mechanism, just the result.

For example, brew install coreutils would use the community.general.homebrew module: https://docs.ansible.com/ansible/latest/collections/communit... <-- you can see from that page that each module has lots of examples, which makes it pretty easy to go from requirements to Ansible script.

Post reply on HN