Forum Discussion
Thomas_Gobet
Nimbostratus
Hi,
In your iRule you have to use HTTP_RESPONSE event to match traffic coming from your webserver.
Your iRule will be like that :
when HTTP_REQUEST {
if { [string tolower [HTTP::host]] equals "vserver.domain.com"} {
HTTP::header replace Host "poolmem1.domain.com"
}
}
when HTTP_RESPONSE {
if { [string tolower [HTTP::host]] equals "poolmem1.domain.com"} {
HTTP::header replace Host "vserver.domain.com"
}
}
Luis_Pablo_1189
Dec 18, 2013Nimbostratus
Hi Thomas,
thanks for your answer. I tried to create the iRule, but I got this error:
error: /Common/iRule_Portal_SAP_DevCentral1:7: error: [command is not valid in current event context (HTTP_RESPONSE)][HTTP::host]
Any clue?
Luis