FAQ
Hello fellow salt addicts,

What are the best practises on wget'ing files.
Is the simple cmd.run still the way to go?

I would like to get a state like:

file:
  - remote
  - source: my/remote/source.file
  - md5: somemd5filethatwillmakethestatefailifnotrun

Is something like this in the works or objectives? If so, where can
I follow the status of it?

--
Regards,
Alfredo Palhares

--
You received this message because you are subscribed to the Google Groups "Salt-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to salt-users+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Search Discussions

  • Clute, Darrel at Aug 4, 2014 at 4:25 pm
    Alfredo,

    What you are looking to do is already supported by Salt. The file state
    can use a source of salt, ftp, http, https, and swift was added but I'd
    have to check versions to see if it is shipping in GA code. Here is a
    sample of what you are looking to do over HTTP, using a static MD5sum.

    file.managed:
       - source: http://server/remote/source.file
       - source_hash: dd831f5ef123ed2f025b39321b5fc714

    And specifying a hash string file, which could contain one or more hash
    strings.

    file.managed:
       - source: http://server/remote/source.file
       - source_hash: http://server/remote/source.hash

    More information here:
    http://docs.saltstack.com/en/latest/ref/states/all/salt.states.file.html


    Sincerely,

    Darrel Clute

    On Mon, Aug 4, 2014 at 8:45 AM, Alfredo Palhares wrote:

    Hello fellow salt addicts,

    What are the best practises on wget'ing files.
    Is the simple cmd.run still the way to go?

    I would like to get a state like:

    file:
    - remote
    - source: my/remote/source.file
    - md5: somemd5filethatwillmakethestatefailifnotrun

    Is something like this in the works or objectives? If so, where can
    I follow the status of it?

    --
    Regards,
    Alfredo Palhares

    --
    You received this message because you are subscribed to the Google Groups
    "Salt-users" group.
    To unsubscribe from this group and stop receiving emails from it, send an
    email to salt-users+unsubscribe@googlegroups.com.
    For more options, visit https://groups.google.com/d/optout.
    --
    You received this message because you are subscribed to the Google Groups "Salt-users" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to salt-users+unsubscribe@googlegroups.com.
    For more options, visit https://groups.google.com/d/optout.
  • Alfredo Palhares at Aug 6, 2014 at 9:52 am
    Hello Darrel,

    What you are looking to do is already supported by Salt. The file state
    can use a source of salt, ftp, http, https, and swift was added but I'd
    have to check versions to see if it is shipping in GA code. Here is a
    sample of what you are looking to do over HTTP, using a static MD5sum.

    file.managed:
    - source: http://server/remote/source.file
    - source_hash: dd831f5ef123ed2f025b39321b5fc714
    This is exactly what I am looking for thanks, some days ago I discovered
    this. execpt that it needs to have the type of hash specified:


    file.managed:
       - source: http://server/remote/source.file
       - source_hash: md5=dd831f5ef123ed2f025b39321b5fc714

    Thank you so much for the help.

    --
    Regards,
    Alfredo Palhares

    --
    You received this message because you are subscribed to the Google Groups "Salt-users" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to salt-users+unsubscribe@googlegroups.com.
    For more options, visit https://groups.google.com/d/optout.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupsalt-users @
postedAug 4, '14 at 2:45p
activeAug 6, '14 at 9:52a
posts3
users2

2 users in discussion

Alfredo Palhares: 2 posts Clute, Darrel: 1 post

People

Translate

site design / logo © 2022 Grokbase