Important: Before using git over ssh, make sure your remote host fingerprint exists in "~/.ssh/known_hosts" file. To avoid requiring password authentication, it is also possible to pass private keys to use explicitly.
https://github.com/saltstack/salt.git:
git.latest:
- rev: develop
- target: /tmp/salt
New in version 2014.7.0.
Manage a git config setting for a user or repository
Local config example:
mylocalrepo:
git.config:
- name: user.email
- value: fester@bestertester.net
- repo: file://my/path/to/repo
Global config example:
mylocalrepo:
git.config:
- name: user.name
- value: Esther Bestertester
- user: ebestertester
- is_global: True
Make sure the repository is cloned to the given directory and is up to date
Name of the user performing repository management operations
Deprecated since version 0.17.0.
Name of the user performing repository management operations
New in version 0.17.0.
Note
Clashing ID declarations can be avoided when including different branches from the same git repository in the same sls file by using the name declaration. The example below checks out the gh-pages and gh-pages-prod branches from the same repository into separate directories. The example also sets up the ssh_known_hosts ssh key required to perform the git checkout.
gitlab.example.com:
ssh_known_hosts:
- present
- user: root
- enc: ecdsa
- fingerprint: 4e:94:b0:54:c1:5b:29:a2:70:0e:e1:a3:51:ee:ee:e3
git-website-staging:
git.latest:
- name: git@gitlab.example.com:user/website.git
- rev: gh-pages
- target: /usr/share/nginx/staging
- identity: /root/.ssh/website_id_rsa
- require:
- pkg: git
- ssh_known_hosts: gitlab.example.com
git-website-prod:
git.latest:
- name: git@gitlab.example.com:user/website.git
- rev: gh-pages-prod
- target: /usr/share/nginx/prod
- identity: /root/.ssh/website_id_rsa
- require:
- pkg: git
- ssh_known_hosts: gitlab.example.com
Execute the onlyif and unless logic. Return a result dict if: * onlyif failed (onlyif != 0) * unless succeeded (unless == 0) else return True
Make sure the repository is present in the given directory
Name of the user performing repository management operations
Deprecated since version 0.17.0.
Name of the user performing repository management operations
New in version 0.17.0.
Docs for previous releases are available on salt.rtfd.org.
Latest Salt release: 2014.1.13
Try the shiny new release candidate of Salt, v2014.7.0rc6! More info here.
22.27.34. salt.states.glusterfs
Upcoming SaltStack events, webinars and local meet ups and user groups.