New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Automation of deployment #917
Comments
We might also want to deploy a branch from a fork. |
@narayanaditya95 We can pass repo URL in the HTTP request to the endpoint. Why do you think that it's not as easy as hitting an endpoint? |
Or I can give you both credentials and instructions how to proceed when deploying on amy-dev. :-) |
Can you write a shell script that does the entire deployment, leaving us
in a workable state if anything goes wrong along the way?
|
Yeah, why didn't I thought about it earlier. :) The deployment script proposed by @gvwilson would be very useful. It'd be very nice if I could just execute something like that: ssh amy-dev deploy https://github.com/swcarpentry/amy/tree/develop |
Unfortunately it'll take some time for me to do such a script because the amy-dev is running Django dev server on tmux session -- the easiest thing to set up. |
@pbanaszkiewicz, could you write down instructions how to deploy and give me credentials to login into AMY? Once you do this, I can write the script. Or we can even defer writing the script if the deployment procedure is easy and quick enough. |
@pbanaszkiewicz, could you give me credentials to amy-dev and a quick&dirty instruction on deployment? In next few days, I'll probably do a demo of what I've done this summer, and that's a chance for me to learn the deployment process. |
@chrismedrela @narayanaditya95 please email me your SSH public keys and I'll add you to the server. The update procedure: $ ssh address
$ tmux attach # or just "tmux" if it's not running
# tmux is session manager, it should run in two panes side by side, one pane has normal terminal prompt and the other one has devserver running
# use ctrl+b,o (that means press ctrl+b, release, then press o) to switch active pane
# use ctrl+b,d to deactivate tmux (close & run in background)
# use ctrl+b," to create a new vertical pane (if you accidentally closed one)
# use ctrl+b,% to create a new horizontal pane
I hope I didn't forget anything. |
@pbanaszkiewicz please ping me when we can deploy to amy-dev. |
You can now (I'm still waiting for @narayanaditya95 public key). |
I'd like to consider using a software-automation tool like Ansible for easy software deployment. |
The Ansible playbooks were created for AMY, and will be used for future server deployment over at https://amy.carpentries.org/. EDIT: the playbooks are hosted at sysadmins repository, not available publicly. |
So far, every time a contributor wants to deploy something to amy-dev, that person needs to hassle @pbanaszkiewicz and wait while he makes deploy. That has three drawbacks:
I'm wondering if we could automate this process. This could looks like this:
nginx
could be configured to execute deployment script when we hit the server with specific HTTP request (let's sayamy-dev.software-carpentry.org/deploy
). In that case, the script pullsamy-dev
branch and deploys it. The output of the script could be returned as the HTTP response, so if the deployment fails, you can tell why.@gvwilson, @narayanaditya95, @pbanaszkiewicz, any opinions?
The text was updated successfully, but these errors were encountered: