I have some files in an Amazon S3 bucket, and I'm using SaltStack to copy all of those files to a directory on a minion. Unfortunately, SaltStack doesn't have the abilty to copy an entire directory from S3 (yet), so I've resorted to using the awscli.It works almost perfectly. cachedout merged 2 commits into saltstack: develop from lomeroe: fix_s3_large_file_download May 31, 2016. Merged Fix s3 large file download #33599. cachedout merged 2 commits into saltstack: Correct the docstrings formatting in pkgbuild modules and state (saltstack#34194 If IAM roles are not used you need to specify them either in a pillar file or in the minion's config file: salt.states.boto_s3_bucket.absent from the bucket. This configuration parameter enables the bucket owner (only) to specify that the person requesting the download will be charged for the download. Tagging. A dictionary of tags that Description of Issue/Question I have a simple state to download a binary file into my home directory from S3. I have an IAM role for my EC2 instance that provides full access to the S3 bucket. Manually running salt-call s3.get mys3bucket
The state file we created wants to pull the MySQL root password from the pillar system using the mysql:root_pw key. This is actually a nested key, meaning that root_pw is a child of the mysql key. With this in mind, we can choose a password for our MySQL root user and set it in the file like this: SaltStack Infrastructure: Configuring Salt
22 Aug 2018 download files from S3 using the file.managed states this only works considering ** path '/var/cache/salt/minion/files/base/s3/tested.sls' to Salt state for fetching a file from an S3 bucket. Place s3_file.py in /srv/salt/[ENV]/_states/ - s3_file.py. Download ZIP. Salt state for fetching a file from an S3 bucket. ret['result'] = True. ret['comment'] = 'System already in the correct state'. Elle is a Course Author at Linux Academy and Cloud Assessments with a focus on DevOps and Linux. She's a SaltStack Certified Engineer, and particularly Common Salt execution modulesCommon Salt state modulesUsing Salt statesUsing pillarManaging Salt via the CLISalt configurationSalt key managementSalt Salt States can aggressively manipulate files on a system. HTTPS and HTTP are supported as well as downloading directly from Amazon S3 compatible URLs
I wrote a python/boto script for launching our instances that shells our to salt-key --gen-keys and cp's the key to the masters key dir and puts the keys in s3 bucket that the minion can download. This allows the minion to salt-call to the master but the master can't reach the minion.
salt.states.file.managed takes source_hash as an argument to verify a downloaded file. This blocks me from using file.managed for a file on an online server I don't have control over. The file also Something like the example on s3 modules, which I would turn into a state looks like: than a google search of "saltstack s3" should probably go somewhere besides the s3 modules page? I've been going around and around trying to find a simple way to download a file from an S3 bucket. If I've gone down the wrong path, please let me know. I have salt-api up and running on the salt master, and i wanted to know if salt has a command to download a file and store it somewhere. I did a bit of research and actually i will do like this : create a command dowload_file on the salt-master that goes to the library and downloads other commands. will trigger this via salt-api via runners. This page contains instructions to download and install the 2016.3 release of SaltStack. Bootstrap works across many platforms and is the easiest way to get started. If you cannot use Bootstrap or if you prefer packages, click the tab for your platform. Latest branch release: 2016.3.8 (October 9, 2017)
This page contains instructions to download and install the 2016.3 release of SaltStack. Bootstrap works across many platforms and is the easiest way to get started. If you cannot use Bootstrap or if you prefer packages, click the tab for your platform. Latest branch release: 2016.3.8 (October 9, 2017)
Now download the saltstack windows minion (slave) software for the servers to manage from below url: SaltStack Windows Installation. Install the saltstack windows minion in client node with default settings and update below details while installing. IP address of master and FQDN of client node.
12 Nov 2018 You can download openrc file from Openstack dashboard and salt-run state.orchestrate orchestrate url: s3+http://bucket-name/folder-name. 4 Aug 2014 A comparison of Salt and Ansible, evaluated by porting an infrastructure away from Puppet. Salt's state system has states, pillars and grains. while in Ansible you must use the s3 module to download a file to a temporary 17 Feb 2014 Apparently the concept of a “state” is pretty important to Salt, but even after reading much
" >> /var/log/salt/buildlog.html file.managed: - name: I SSH to the node; I download and install Salt (using one-liner bootstrap script) (page 35 of this helped: https://speakerd.s3.amazonaws.com/presentations/ Salt.state.file docs incorrectly state S3 URLs are usable by the source parameter #15151 highlyunavailable opened this issue Aug 21, 2014 · 10 comments Labels salt.states.file.absent (name, **kwargs) ¶ Make sure that the named file or directory is absent. If it exists, it will be deleted. This will work to reverse any of the functions in the file state module. If a directory is supplied, it will be recursively deleted. name. The path which should be deleted salt.modules.s3¶ Connection module for Amazon S3. configuration. This module accepts explicit s3 credentials but can also utilize IAM roles assigned to the instance through Instance Profiles. Dynamic credentials are then automatically obtained from AWS API and no further configuration is necessary. More Information available at:
System power state S4, the hibernate state, is the lowest-powered sleeping state and has the longest wake-up latency. To reduce power consumption to a minimum, the hardware powers off all devices. Operating system context, however, is maintained in a hibernate file (an image of memory) that the system writes to disk before entering the S4 state.
There is this neat state module function called file.recurse, it functions kind like rsync, you pass a directory on the master and one on the minion, and it will make the one on the minion like the one on the master, except that it will not recurse file permissions, so any executable files you will have to make executable again with file.managed. Now download the saltstack windows minion (slave) software for the servers to manage from below url: SaltStack Windows Installation. Install the saltstack windows minion in client node with default settings and update below details while installing. IP address of master and FQDN of client node.