Why am I getting “message”: “Network error communicating with endpoint” when running gunicorn in the...
Elements that can bond to themselves?
Why did C use the -> operator instead of reusing the . operator?
Was there a Viking Exchange as well as a Columbian one?
How to pronounce 'c++' in Spanish
I preordered a game on my Xbox while on the home screen of my friend's account. Which of us owns the game?
Can someone publish a story that happened to you?
Can I criticise the more senior developers around me for not writing clean code?
Can an Area of Effect spell cast outside a Prismatic Wall extend inside it?
Is it idiomatic to construct against `this`
Was there a shared-world project before "Thieves World"?
Mistake in years of experience in resume?
What's the polite way to say "I need to urinate"?
Check if a string is entirely made of the same substring
Does tea made with boiling water cool faster than tea made with boiled (but still hot) water?
How do I deal with a coworker that keeps asking to make small superficial changes to a report, and it is seriously triggering my anxiety?
Discriminated by senior researcher because of my ethnicity
Who was the lone kid in the line of people at the lake at the end of Avengers: Endgame?
Implications of cigar-shaped bodies having rings?
Can SQL Server create collisions in system generated constraint names?
Overlay of two functions leaves gaps
How to have a sharp product image?
Dynamic SOQL query relationship with field visibility for Users
A Note on N!
Coordinate my way to the name of the (video) game
Why am I getting “message”: “Network error communicating with endpoint” when running gunicorn in the background?
$XAUTHORITY in systemdRun sudo script at startup under 15.04 using 'systemd'How to convert this custom upstart job to systemd?SSL error only when running on systemdWhy does my systemd service shut down immediately after running?Unable to install docker - invoke-rc.d: initscript docker, action “start” failedWhy does systemd stop my service but not restart it?services failing to start - control process exited with error codesamba not starting from systemctl: timeoutubuntu snmpd ignores /etc/default/snmpd
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty{ margin-bottom:0;
}
I am trying to serve my API with gunicorn on an ubuntu 18 EC2 instance so I created a .service then used the systemctl command to enable, start and check the status of the service.
Everything seems fine it displays as active (running) but I get this response when trying to hit my endpoint with postman.
{
"message": "Network error communicating with endpoint"
}
So then I tried starting gunicorn directly from the terminal using the same command as in my .service file and when I hit the endpoint with postman it works fine. This is my .service file.
[Unit]
Description=Start up script for gunicorn
Requires=my_project.socket
After=network.target
[Service]
Restart=always
User=ubuntu
WorkingDirectory=/home/ubuntu/my_project
ExecStart=/home/ubuntu/my_project/venv36/bin/gunicorn -w 1 -b 0.0.0.0:8080 wsgi:application
Type=simple
[Install]
WantedBy=multi-user.target
networking server systemd
add a comment |
I am trying to serve my API with gunicorn on an ubuntu 18 EC2 instance so I created a .service then used the systemctl command to enable, start and check the status of the service.
Everything seems fine it displays as active (running) but I get this response when trying to hit my endpoint with postman.
{
"message": "Network error communicating with endpoint"
}
So then I tried starting gunicorn directly from the terminal using the same command as in my .service file and when I hit the endpoint with postman it works fine. This is my .service file.
[Unit]
Description=Start up script for gunicorn
Requires=my_project.socket
After=network.target
[Service]
Restart=always
User=ubuntu
WorkingDirectory=/home/ubuntu/my_project
ExecStart=/home/ubuntu/my_project/venv36/bin/gunicorn -w 1 -b 0.0.0.0:8080 wsgi:application
Type=simple
[Install]
WantedBy=multi-user.target
networking server systemd
add a comment |
I am trying to serve my API with gunicorn on an ubuntu 18 EC2 instance so I created a .service then used the systemctl command to enable, start and check the status of the service.
Everything seems fine it displays as active (running) but I get this response when trying to hit my endpoint with postman.
{
"message": "Network error communicating with endpoint"
}
So then I tried starting gunicorn directly from the terminal using the same command as in my .service file and when I hit the endpoint with postman it works fine. This is my .service file.
[Unit]
Description=Start up script for gunicorn
Requires=my_project.socket
After=network.target
[Service]
Restart=always
User=ubuntu
WorkingDirectory=/home/ubuntu/my_project
ExecStart=/home/ubuntu/my_project/venv36/bin/gunicorn -w 1 -b 0.0.0.0:8080 wsgi:application
Type=simple
[Install]
WantedBy=multi-user.target
networking server systemd
I am trying to serve my API with gunicorn on an ubuntu 18 EC2 instance so I created a .service then used the systemctl command to enable, start and check the status of the service.
Everything seems fine it displays as active (running) but I get this response when trying to hit my endpoint with postman.
{
"message": "Network error communicating with endpoint"
}
So then I tried starting gunicorn directly from the terminal using the same command as in my .service file and when I hit the endpoint with postman it works fine. This is my .service file.
[Unit]
Description=Start up script for gunicorn
Requires=my_project.socket
After=network.target
[Service]
Restart=always
User=ubuntu
WorkingDirectory=/home/ubuntu/my_project
ExecStart=/home/ubuntu/my_project/venv36/bin/gunicorn -w 1 -b 0.0.0.0:8080 wsgi:application
Type=simple
[Install]
WantedBy=multi-user.target
networking server systemd
networking server systemd
asked 14 hours ago
Connor McCannConnor McCann
212
212
add a comment |
add a comment |
0
active
oldest
votes
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "89"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1138285%2fwhy-am-i-getting-message-network-error-communicating-with-endpoint-when-run%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
0
active
oldest
votes
0
active
oldest
votes
active
oldest
votes
active
oldest
votes
Thanks for contributing an answer to Ask Ubuntu!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1138285%2fwhy-am-i-getting-message-network-error-communicating-with-endpoint-when-run%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown