Skip to content

Commit

Permalink
test manip1
Browse files Browse the repository at this point in the history
  • Loading branch information
kreynoldsf5 committed May 1, 2024
1 parent baba839 commit a82a951
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 18 deletions.
4 changes: 2 additions & 2 deletions labapp/app/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -325,8 +325,8 @@ def manip1():
if not ns:
raise LabException("Ephemeral NS not set")
base_url = app.config['base_url']
url = f"https://{ns}.{base_url}/"
r_data = cloudapp_fetch(s, url, 5, 'info[path]', '/')
url = f"https://{ns}.{base_url}/aws/raw"
r_data = cloudapp_fetch(s, url, 5, 'info', '{"path": "/"}')
return jsonify(status='success', data=r_data)
except (LabException, requests.RequestException, ValueError) as e:
return jsonify(status='fail', error=str(e))
Expand Down
14 changes: 5 additions & 9 deletions labapp/app/markdown/manipulation.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

Since web traffic has been traversing proxies, engineers have needed to alter HTTP content for increased observability ([XFF](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Forwarded-For)), performance ([cache-control](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Cache-Control)), or other reasons ([JWT](https://en.wikipedia.org/wiki/JSON_Web_Token)).
"Proxy Pass" functionality has been part of web servers since the early Apache days.
Adding, removing, or altering HTTP Headers is tablestakes for ADCs, CDNs, and software-based load balancers.
Adding, removing, and altering Headers are tablestakes for ADCs, CDNs, and software-based load balancers.
F5 XC App Connect enables this functionality granularly on routes or broadly on the load balancer.


Expand All @@ -21,10 +21,10 @@ Configure a path <strong>prefix rewrite</strong> to remove part of the request p
<ul class="list-group">
<li class="list-group-item">
<img src="/static/lb-icon.png" width="auto" height="50px"> &nbsp; &nbsp;
Keep your routing rules from the previous exercise in place.
Keep your configuration from the previous exercise in place.
</li>
<li class="list-group-item">
<img src="/static/lb-icon.png" width="auto" height="50px"> &nbsp; &nbsp;
<img src="/static/route-icon.png" width="auto" height="50px"> &nbsp; &nbsp;
Requests to "<u>https://<i>eph-ns</i>.mcn-lab.f5demos.com<strong>/aws/raw</strong></u>" need to arrive at the origin with a path of "<strong>/raw</strong></u>"
</li>
</ul>
Expand Down Expand Up @@ -63,16 +63,12 @@ Since questions on this functionality are often asked on [F5 DevCentral](https:/
<button class="btn btn-primary" type="button" data-bs-toggle="collapse" data-bs-target="#multiCollapseExample2" aria-expanded="false" aria-controls="multiCollapseExample2">Rewrite Hint</button>
</p>
<div class="row">

<div class="collapse multi-collapse" id="multiCollapseExample1" data-bs-parent="#hints">
<div class="">
<div class="collapse multi-collapse" id="multiCollapseExample1" data-bs-parent="#hints">
<img src="/static/rewrite1.png" width="800px" height="auto" alt="temp">
</div>
</div>

<div class="collapse multi-collapse" id="multiCollapseExample2" data-bs-parent="#hints">
<div class="">
<img src="/static/rewrite2.png" width="800px" height="auto" alt="temp">
<img src="/static/rewrite2.png" width="500px" height="auto" alt="temp">
</div>
</div>
</div>
Expand Down
5 changes: 2 additions & 3 deletions labapp/app/markdown/overview.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,8 @@ For testing, you can access an endpoint of each cloud app from your browser.
<img src="/static/aws.png" height="100px" width="auto" class="rounded"/>
</a>
<a href="https://azure-cloud-app.mcn-lab.f5demos.com/pretty" target="_blank">
<img src="/static/azure.png" height="100px" width="auto" class="rounded"/>
</a>
</p>
<img src="/static/azure.png" height="100px" width="auto" class="rounded"/>
</a></p>



Expand Down
8 changes: 4 additions & 4 deletions labapp/app/markdown/route.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@ Build routing rules and configure your load balancer to route traffic between th
Reuse the origin pools from the previous exercise
</li>
<li class="list-group-item">
<img src="/static/lb-icon.png" width="auto" height="50px"> &nbsp; &nbsp;
<img src="/static/route-icon.png" width="auto" height="50px"> &nbsp; &nbsp;
Route requests to "<u>https://<i>eph-ns</i>.mcn-lab.f5demos.com/<strong>aws</strong></u>" to the AWS cloud app.
</li>
<li class="list-group-item">
<img src="/static/lb-icon.png" width="auto" height="50px"> &nbsp; &nbsp;
<img src="/static/route-icon.png" width="auto" height="50px"> &nbsp; &nbsp;
Route requests to "<u>https://<i>eph-ns</i>.mcn-lab.f5demos.com/<strong>azure</strong></u>" to the Azure cloud app.
</li>
</ul>
Expand Down Expand Up @@ -76,11 +76,11 @@ Build rules to route traffic between the two cloud apps based on an arbitrary HT

<ul class="list-group">
<li class="list-group-item">
<img src="/static/lb-icon.png" width="auto" height="50px"> &nbsp; &nbsp;
<img src="/static/route-icon.png" width="auto" height="50px"> &nbsp; &nbsp;
Route requests with an "<strong>X-MCN-Lab: aws</strong>" header to the AWS cloud app.
</li>
<li class="list-group-item">
<img src="/static/lb-icon.png" width="auto" height="50px"> &nbsp; &nbsp;
<img src="/static/route-icon.png" width="auto" height="50px"> &nbsp; &nbsp;
Route requests with an "<strong>X-MCN-Lab: azure</strong>" header to the Azure cloud app.
</li>
</ul>
Expand Down
Binary file added labapp/app/static/rewrite1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added labapp/app/static/rewrite2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit a82a951

Please sign in to comment.