Mercurial > hg > config
annotate bin/ubuntu_updated.sh @ 827:a5a339b7fd82
python 3.5
author | Jeff Hammel <k0scist@gmail.com> |
---|---|
date | Sun, 19 Feb 2017 17:48:52 -0800 |
parents | 570ace9ed7c2 |
children |
rev | line source |
---|---|
364 | 1 #!/bin/bash |
2 | |
822
570ace9ed7c2
make my life a little easier
Jeff Hammel <k0scist@gmail.com>
parents:
364
diff
changeset
|
3 set -e |
570ace9ed7c2
make my life a little easier
Jeff Hammel <k0scist@gmail.com>
parents:
364
diff
changeset
|
4 |
570ace9ed7c2
make my life a little easier
Jeff Hammel <k0scist@gmail.com>
parents:
364
diff
changeset
|
5 # script to update ubuntu |
570ace9ed7c2
make my life a little easier
Jeff Hammel <k0scist@gmail.com>
parents:
364
diff
changeset
|
6 # Ref: |
570ace9ed7c2
make my life a little easier
Jeff Hammel <k0scist@gmail.com>
parents:
364
diff
changeset
|
7 # http://mixeduperic.com/ubuntu/how-to-keep-your-ubuntu-server-updated-with-patches-and-security-fixes-using-the-command-line |
570ace9ed7c2
make my life a little easier
Jeff Hammel <k0scist@gmail.com>
parents:
364
diff
changeset
|
8 |
364 | 9 |
822
570ace9ed7c2
make my life a little easier
Jeff Hammel <k0scist@gmail.com>
parents:
364
diff
changeset
|
10 if sudo apt-get update -y |
364 | 11 then |
822
570ace9ed7c2
make my life a little easier
Jeff Hammel <k0scist@gmail.com>
parents:
364
diff
changeset
|
12 # -s = dry run |
570ace9ed7c2
make my life a little easier
Jeff Hammel <k0scist@gmail.com>
parents:
364
diff
changeset
|
13 # sudo apt-get -u -s -y upgrade |
570ace9ed7c2
make my life a little easier
Jeff Hammel <k0scist@gmail.com>
parents:
364
diff
changeset
|
14 |
570ace9ed7c2
make my life a little easier
Jeff Hammel <k0scist@gmail.com>
parents:
364
diff
changeset
|
15 sudo apt-get -u -y upgrade |
570ace9ed7c2
make my life a little easier
Jeff Hammel <k0scist@gmail.com>
parents:
364
diff
changeset
|
16 |
570ace9ed7c2
make my life a little easier
Jeff Hammel <k0scist@gmail.com>
parents:
364
diff
changeset
|
17 # TODO: sudo apt-get -u -s dist-upgrade |
570ace9ed7c2
make my life a little easier
Jeff Hammel <k0scist@gmail.com>
parents:
364
diff
changeset
|
18 |
364 | 19 fi |
822
570ace9ed7c2
make my life a little easier
Jeff Hammel <k0scist@gmail.com>
parents:
364
diff
changeset
|
20 |
570ace9ed7c2
make my life a little easier
Jeff Hammel <k0scist@gmail.com>
parents:
364
diff
changeset
|
21 # cleanup |
570ace9ed7c2
make my life a little easier
Jeff Hammel <k0scist@gmail.com>
parents:
364
diff
changeset
|
22 sudo apt -y autoremove |