3 * Some parts of the infrastructure will not be touched, although I plan
4 on documenting them. Specifically, we will be keeping:
6 - parallel-find.pl, and the resulting
7 /mit/scripts/sec-tools/store/scriptslist
9 - The current install scripts will be kept in place, sans changes
10 necessary to make them use Git install of copying the script over.
11 Porting these scripts to Python and making them modular would be
12 nice, but is priority. For the long term, seeing this scripts
13 be packaged with rest of our code would be optimal.
15 * The new procedure for generating an update is as follows:
17 1. Have the Git repository and working copy for the project on hand.
19 2. Download the new tarball
21 3. Extract the tarball over the working copy
23 4. Check if there are any special update procedures, and update the
24 .scripts/update shell script as necessary (this means that any
25 application specific update logic will be kept with the actual
26 source code. The language of this update script will vary
27 depending on context.)
29 X. Check for empty directories and add stub files as necessary
30 (use preserve-empty-dir)
32 5. Commit your changes, and tag as v1.2.3-scripts
34 6. Run the "dry-run script", which uses Git commands to check how many
35 working copies apply the change cleanly, and writes out a logfile
36 with the working copies that don't apply cleanly.
38 7. Run the "limited run" script, which applies the update to our
39 test-bed, and lets us check the basic functionality of the update.
41 8. Run the "deploy" script, which applies the update to all working
42 copies possible, and sends mail to users to whom the working copy
43 did not apply cleanly. (It also frobs .scripts/version)
45 Note: The last three scripts will need to be implemented, with an
48 * How to migrate an old autoinstaller to the new autoinstaller
50 - Find the oldest tarball/patch set for the application that still
51 is in use and upgradable.
53 - Untar, apply patch, place in a directory and git init
55 - Create the .scripts directory and populate it with the interesting
56 information (see below)
58 * The repository for a given application will contain the following files:
60 - The actual application's files, as from the official tarball
62 - A .scripts directory, which contains the following information:
64 * .scripts/update shell script (with the +x bit set appropriately),
65 which performs the commands necessary to update a script. This can
68 * .scripts/version which contains the version last autoinstalled
69 (as distinct from the actual version the script is) (This will
70 be auto-generated and should not be versioned)
72 * .scripts/real-version (+x) which checks the source code to find the
73 actual version of the application
75 * .scripts/.htaccess to prevent this directory from being accessed
78 - Because there will be no .gitignore file, you *must not* run
79 `git add .` on an actual running copy of the application.
80 `git add -u .` will generally be safe.
82 * The migration process shall be as such:
86 2. git add remote origin /foo
88 3. whatever the merge frob is
94 6. Setup .scripts/version (probably pipe the output of real-version)
96 * We will not add special code to handle .htaccess; thus the kernel patch
97 for allowing Apache access to .htaccess sent to scripts-team@mit.edu
98 must be handled first.
100 * The autoupgrade shall be the process of:
103 git commit -m 'automatically generated backup'
104 git pull /mit/scripts/deploy/wordpress.git master
105 if [ $? ne 0 ]; then git reset --hard; echo 'conflicts during upgrade'; fi
108 * Make install-statistics generate nice pretty graphs of installs by date
109 (more histograms, will need to check actual .scripts-version files.)