Questions tagged [conditional]

54 questions
0
votes
1 answer

Rebuilding a file if files have changed

I'm having a hard time wrapping my head around this. It seems trivial, but I'm not getting it. I have two files. If either of those two files changes, I want to rebuild one of them. Essentially: if file a changes or file b changes then file…
0
votes
1 answer

Discerning which GNU screen window is being used in a shell script

Using a shell script, how can you tell if a screen is running using shell scripts? For example, using pseudocode: IF (screen.screenname.running == TRUE) or something like that.
Gray Adams
  • 165
  • 7
0
votes
2 answers

Varnish and Browser Exceptions

I currently run a website behind a Varnish server, It contains a few browser conditions for Internet Explorer 6. Unfortunately Varnish is caching the first version it serves without taking into account the conditions. Is there any way I can…
mnml
  • 337
  • 1
  • 7
  • 21
0
votes
1 answer

Apache 2.2, changing DocumentRoot depending on the HTTP auth credentials provided by client

Is this even possible? Say I have a server, devbox.local, which has several HTTP auth users: alan, bill, carl. What I'm trying to do is tell Apache to use a different DocumentRoot depending on who is logged in at the time. So user alan might see a…
TimE
0
votes
1 answer

How to set up conditional redirects on an Application Load Balancer for an Elastic Beanstalk environment?

I have two Docker-based single-instance Elastic Beanstalk environments (one for staging and one for production). I'd like to migrate the (Elastic Beanstalk) application to sit behind a load balancer (primarily to take advantage of AWS Certificate…
0
votes
0 answers

Azure Application Proxy conditional access with linked applications

Linked applications, using AAD pre authentication, are no longer selectable options for my Conditional Access Policies. Early last week, I was able to add my internal linked applications to conditional access policies, now all of the sudden they do…
0
votes
1 answer

How to redirect register output for failed hosts in ansible using assert or any ways

- name: Check the VolumeGroup has 5gb space assert: that: ansible_lvm.vgs.VG00.free_g|int >= 5 fail_msg: 'VG has no free space' success_msg: "{{ ansible_lvm.vgs.rhel.free_g }}" register: vg00 - name: Line in file shell: echo -e "{{…
0
votes
1 answer

How can I add multiple conditions to a location-block conditional in NGINX configuration, or otherwise get same desired result?

Initial disclosure: I'm new to nginx and struggling to understand its configuration principles; I have read a fair amount of the docs (including 'If Is Evil'), but still lack comprehension of many aspects. I intend to implement an api gateway in the…
-3
votes
1 answer

Function, that check previous command

i want to write fucntion, that check previous command. Succes or not. My code: #!/bin/bash function check_previous { RESULT=$? if [ $RESULT -eq 0 ]; then echo "success" else echo "failed" fi } echo…
Valeriu
  • 1
  • 2
1 2 3
4