6 months ago
Hello 👋🏻
I'm trying to edit my Filebeat configuration on my OpenSearch instance. My configuration is saved inside CONFIG environment variable and is copied when the containers starts. There are some modifications I can't save (I think it's because they are breaking the GraphQL request but I can't locate the problem).
Here is my actual configuration (working) :```yaml
filebeat.inputs:
type: httpendpoint enable: true listenaddress: 0.0.0.0
listenport: 8080 secret.header: FilebeatAuth secret.value: ${{AUTHSECRET}}
output.logstash:
hosts: ['${{Logstash.RAILWAYPRIVATEDOMAIN}}:5044']```
And here is the new configuration I'm trying to save (yes I'm just trying to enable debug logging 😄) :```yaml
logging.level: debug
logging.to_files: true
logging.files:
path: /var/log/filebeat
name: debug
keepfiles: 7
filebeat.inputs:
type: httpendpoint enable: true listenaddress: 0.0.0.0
listenport: 8080 secret.header: FilebeatAuth secret.value: ${{AUTHSECRET}}
output.logstash:
hosts: ['${{Logstash.RAILWAYPRIVATEDOMAIN}}:5044']```
Here is the error in the console :
https://backboard.railway.com/graphql/internal?q=stageEnvironmentChanges net::ERR_FAILED 403 (Forbidden)
Thanks for your help 🙂
7 Replies
6 months ago
188bf912-f6d5-473b-a04c-28fcc7d44154
Can you provide the build logs, which might have the exact info of the failure
6 months ago
The problem doesn't come from my service but from Railway API itself since I can't even save the variable. This error happens when I try to save my variable
Do you have a volume attached to the service, which would be used to store the logs
6 months ago
Hello,
The 403 status code does not originate from our API.
Instead, this is Cloudflare blocking the request, likely detecting something it thinks is malicious in that config.
Fortunately, the solution is simple, and involves better practices: save the configuration files into a repo, and have a Dockerfile set to copy them into the image, like this:
https://github.com/railwayapp-templates/elasticsearch/blob/main/Dockerfile#L8-L14
6 months ago
Ok thanks I will take a look 🙂
