This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Based on http://reinh.com/blog/2009/03/02/a-git-workflow-for-agile-teams.html | |
# Start working on new feature/fix | |
git checkout -b <feature/fix branch name> | |
# On a regular basis, rebase against upstream | |
git fetch origin master | |
git rebase origin/master | |
# When feature/fix is finished, rebase and squash commits into fewer |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git config --global core.editor "mate -w" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class user_larstobi { | |
$user = "larstobi" | |
group { "$user": | |
ensure => present, | |
allowdupe => false, | |
} | |
user { "$user": | |
comment => "Lars Tobias Skjong-Borsting", | |
gid => "$user", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
file { | |
"/var/spool/gitolite": | |
ensure => directory, | |
owner => "git", | |
group => "git"; | |
"admin.pub": | |
ensure => present, | |
path => "/var/spool/gitolite/admin.pub", | |
content => "ssh-rsa AAAAB3NzaC1...bmhLcxczOQ== admin@example.net"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
For instance Puppet server will not start under RHEL SELinux. Try to start it, then run the following script. Continue this cycle until it starts. It will probably work for different SELinux challenges as well. | |
The script requires: | |
$yum install policycoreutils-python | |
cd /tmp && \ | |
cat /var/log/audit/audit.log | audit2allow -m puppetmaster > puppetmaster.te && \ | |
checkmodule -M -m puppetmaster.te -o puppetmaster.mod && \ | |
semodule_package -m puppetmaster.mod -o puppetmaster.pp && \ | |
semodule -i puppetmaster.pp |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
restorecon -R -v /home | |
Source: http://blog.natesilva.com/post/9618889334/in-centos-linux-6-0-you-cant-ssh-using |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Display certs for a server | |
openssl s_client -showcerts -connect <host.domain>:<port> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git checkout -n new_branch | |
git push heroku +HEAD:master | |
git push -f heroku HEAD:master | |
Source: http://stackoverflow.com/questions/2971550/how-to-push-different-local-git-branches-to-heroku-master |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Gjenskape produksjon: | |
Backup av staging og prod database: | |
heroku pgbackups:capture --remote staging | |
heroku pgbackups:capture --remote production | |
Clean staging-database: | |
heroku pg:reset DATABASE_URL --remote staging |
OlderNewer