Skip to content

Instantly share code, notes, and snippets.

View sjha4's full-sized avatar

Samir Jha sjha4

View GitHub Profile
cd forklift/
vi boxes.yaml #check the dev boxes included
vagrant up centos7-devl1
#WAIT..........................
vagrant ssh centos7-devl1
cd /usr/share/katello-installer-base/
mv katello /tmp/
yum install git tig -y
git clone https://github.com/Katello/puppet-katello.git
ls
@sjha4
sjha4 / Mount vagrant machine
Last active March 21, 2018 19:47
Mount vagrant machine
#Mounting Command Fedora
sshfs -o nonempty vagrant@192.168.121.42:/home/vagrant/ ~/mnt
1. Vagrant up a client m/c
2. Ssh into the m/c
3. sudo yum install -y http://fedorapeople.org/groups/katello/releases/yum/nightly/client/el5/x86_64/katello-client-repos-latest.rpm
4. sudo yum -y install http://dl.fedoraproject.org/pub/epel/epel-release-latest-5.noarch.rpm
5. On the host:
sudo yum install subscription-manager
6.In foreman, create an activation key.
@sjha4
sjha4 / restore smart proxy configs
Created August 1, 2017 17:02 — forked from jlsherrill/restore smart proxy configs
restore and restore smart proxy configs certs
rake -- config -k ssl_ca_file -v /etc/pki/katello/certs/katello-default-ca.crt
rake -- config -k ssl_certificate -v /etc/pki/katello/certs/$(hostname)-foreman-client.crt
rake -- config -k ssl_priv_key -v /etc/pki/katello/private/$(hostname)-foreman-client.key
http://file.rdu.redhat.com/~rjerrido/manifests/
Internals:
1. Command> 2. Scenario>
Runner:
Checks: Assertion
Procedures: ex: SQL DUmp, Pulp migrate etc. (Code to perform changes)
Repoter
Add subcommand in some place
Command > Scenario
@sjha4
sjha4 / Example
Last active June 26, 2018 17:05
Recurring logic
recLog = ForemanTasks::RecurringLogic.new_from_cronline("*/10 * * * *")
recLog.start(::Actions::Katello::Repository::Sync, ::Katello::Repository.last)

If you see the image in 1 st comment, you will see the subscription has an end date of 2018-06-29.

When I add this subscription to an allocation, the end date changes to 2019-06-27 (2nd image)

I created the pool using the ethel site and the manifest through access staging.

in config/settings.yaml :webpack_dev_server: true

In one tab:

rails s -b '0.0.0.0'

In a 2nd tab:

gpg: /home/sajha/.gnupg/trustdb.gpg: trustdb created
gpg: key 10668686 marked as ultimately trusted
public and secret key created and signed.
gpg: checking the trustdb
gpg: 3 marginal(s) needed, 1 complete(s) needed, PGP trust model
gpg: depth: 0 valid: 1 signed: 0 trust: 0-, 0q, 0n, 0m, 0f, 1u
gpg: next trustdb check due at 2020-01-08
pub 2048R/10668686 2018-07-17 [expires: 2020-01-08]
Key fingerprint = AA10 E360 D73B FB80 106C F08A 38E0 0D46 1066 8686