![]() It should tell you you can't again because of permissions. Let's try deleting that brian user we added. If you haven't watched any of Sarah's courses they're amazing. Sudo is Sarah Drasner's adorable dog who I just love. To get out of being root, just hit CTRL+D or run exit. It's like using a flamethrower to start a grill: you can do it but there's a good shot you're taking the house down with you. It also means that if you fat finger a command and accidentally type something wrong, you really can burn down the house. When you do things as root, it means usually that only root in the future will be able to modify and delete files it makes. What we did, sudo su is usually not what you want to do. Try running useradd brian and you'll see you run it with no problem. Now we have ultimate power: the superuser has no restrictions on what it can do. ![]() We'll talk about sudo in a sec but su is switch user. This is because only the superuser can add new users. ![]() Try useradd brian (or change brian for whatever you want the name of the new user to be.) You 'll see something saying "Permission denied". For example, a user cannot create a new user. Ubuntu is a user and can only do things that a normal user can do. That way if they run amok, either accidentally or maliciously, the amount of damage they can cause is as minimal as possible. Why? Linux generally adheres to the principle of least power: we want programs to be given the least amount of power possible to complete their tasks. You'll notice programs like man and mail have their own users to keep their permissions separate from yours. Right now I have 20ish users on my system. This will print out all of the currently registered users on your computer. Run cat /etc/passwd (notice it's passwd, not password). Let's see what users are already on your machine. The user will have access to various files and not others. A user is what you'd expect: a user of the system. This is useful in case you're not sure who is running some program. If you're using Multipass, it will likely say "ubuntu". Many of the users of the system aren't even meant to be actual human users many programs will create their own users and groups to keep themselves separate from userspace. You have an account (in our case, ubuntu is the name of the user by default for Multipass) but there are always multiple users of a Linux system. (Don't want to use Rails generators in case of a Clojure/Node app.Linux is inherently a multi user system. bootstrap directory based on the requested arch. Would really like a way to cd to a Rails/Lein app and run a command to generate a.No requirement of Ruby, so no Capistrano.Don't try to abstract away from Ubuntu & CentOS like Chef & Puppet do.Generate boilerplate scripts that are designed to be thrown away and regenerated for each provisioning event.Generate boilerplate scripts that are designed to be easily updated by the developer.A simple-to-run, idempotent script for Ubuntu installation and another for CentOS.it's better to provision a new server from scratch than make lots of little config changes then you can just hot-swap from the old to the new with a DNS change.instead of maintaining servers for long periods of time, we should periodically just provision new servers.servers are cheap to provision now giving cloud services.The old provision script is mostly for historical purposes anyway. Let's cook like people really cook - adapting the recipe to what you've got at hand, the time you've got, and the folks who are coming to dinner.Įasily generate boilerplate scripts for every provisioning event. Chef or Puppet), let's expose the ingredients. Instead of having a hard-coded and difficult to change provisioning recipe with all the parts hidden (i.e. In other words, a provisioning event this month could be very different than a provisioning event next month. Provisioning a server to host your software is a "rubber-meets-road" experience that bridges these two moving targets together. Your application is always changing, growing, expanding. Operating systems and the software packages they provide are always changing, being updated, being tweaked. A collection of recipes for creating servers suitable for Rails, Node, & Clojure apps.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |