grantae

Members
  • Content Count

    22
  • Joined

  • Last visited

  • Days Won

    2

Community Reputation

3 Neutral

About grantae

  • Rank
    Observer
  1. I would love this too. A master template that we could add devices (different tokens) into. It is super annoying to have to make the same change on 60 different dashboards or change one, delete all the other old ones, then clone them all again.
  2. Got to make up for lost time 😎
  3. Cool, I see it now. I gave you all the thumbs. No problem, I'm glad I could help you since you helped me so much.
  4. Yep, I see it for other users.
  5. Still looks the same. I checked in different browsers too.
  6. I hope I'm not blind but I don't see a thumbs up. I see the vote up answers, but after doing that a few times I don't think it was the right button lol.
  7. Thank you again for all your help. It really helped me out and was very educational. Is there a way to up-vote/give you kudos on this site?
  8. Is the variable loop always "it", or does the code know the variable is being made at that time? Also did we have to use ~/show running-config/ or was there a non-regex way to identify the string? Curious since regex is new to me so I had to Google the ~ thing. It said it forced a regex string? Just want to know more about it.
  9. Can confirm this removes the show running-config line: cli.before().eachLine{ if(!(it=~/show running-config/)){ println(it) } } Can you explain the it=~/show running-config/ part, so I understand what the code is doing? Is the code defining "it" as the regex string "show running-config", but we are println(it) so it isn't defined as "show running-config"? I know it is printing when "it" is not "show running-config" but not sure how it is doing that.
  10. OK, I found it. I now understand that the Config Check doesn't change the file it literally just does a diff ignoring the parts we told it to ignore to determine if it should save it or not. Since my file has "show running-config" in it would that mess anything up? Is the backup rollback process, just copy and paste the file into the device config or is there a fancy LM way to roll back where the file needs to be exact?
  11. Final Product: import com.santaba.agent.groovyapi.expect.Expect host = hostProps.get("system.hostname"); user = hostProps.get("config.user"); pass = hostProps.get("config.pass"); display = hostProps.get("system.displayname"); /* Define prompt to work for HOSTNAME/USERname# / <-Start ${display} <- display defined earlier \/ <- matches / ${user} <- user defined earlier \# <- matches # \s <- space / <-End */ prompt = /${display}\/${user}\#\s/ //Login and exp
  12. How do I check if the ConfigSource is actually running every hour? Where is the backup saved when it runs? I want to make sure the final product looks correct. Also thank you so much for all your help. I wouldn't have been able to do this without your help. It was a great learning experience.
  13. That seemed to work. Aside from some weirdness like ! and removing show running-config. I think I can play with the Config Checks to fix that. (They look like the address that issue, mostly.) When this script actually runs instead of "Test Script" does it use the Config Checks, but not in the test?
  14. Prompt: HOSTNAME/USERname# Breakdown of /${host}\/${user}\#\s/: / <-Start ${host} <- host defined earlier \/ <- matches / ${user} <- user defined earlier \# <- matches # \s <- space / <-End ---------------------- host = hostProps.get("system.hostname"); user = hostProps.get("config.user"); pass = hostProps.get("config.pass"); display = hostProps.get("system.displayname"); //prompt = /.+\#\s/ prompt = /${display}\/${user}\#\s/ Let me try this.
  15. Copied to a non-multi-instance and ran the script. Results: