-
Notifications
You must be signed in to change notification settings - Fork 1
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
Feature/BE11 #215
Feature/BE11 #215
Conversation
BElifb
commented
Oct 29, 2022
•
edited
Loading
edited
- DO NOT MERGE, I just needed to create pull request to test it.
- Created the YAML file for CICD workflow.
- The current workflow is supposed to be able to run the unit tests and build the DockerFile on every direct push or a pull request to master.
- With the current state of the repo, it seems like a really good idea to have some sort of staging/testing branch before we merge things to main. Waiting for feedback on this from the reviewers as well.
- You may also refer to issue BE-11: CI/CD Research and Implementation #209 for more detail.
We should cd into |
Agreed, we should create another remote branch named |
Added default working directory, hid the secret key.
|
Running Django tests without db connection: https://stackoverflow.com/questions/5917587/django-unit-tests-without-a-db Maybe this could be helpful. |
|
Workflow for creating and publishing a Docker image to Github Packages
|
|
|
|
|
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the efforts. I followed the necessary steps and checked if it's working properly. You are absolutely right on the issue that build: .
already builds the Dockerfile, so we don't need to call that action beforehand. I added new command to the docker-compose
file as a comment to let others know how to use it.
Also, I had some problems while making the configurations from terminal. So let me provide the necessary commands directly (so that everyone can follow):
After creating a token, open a terminal and write the following.
docker login ghcr.io --username <YOUR-USERNAME>
Your username stands for the username you are using for Github. For example, mine is KarahanS. Upon executing this command, it will prompt for a password - copy paste your token. Now, you are done with the authentication. As you stated above, one should execute the following line:
docker pull ghcr.io/bounswe/bounswe2022group8:pr-215
Everything looks good to me, you can merge the PR.
Hi @suzan-uskudarli @busraoguzoglu, we are trying to add a new feature that will enable everyone (at least from our team) to pull the necessary Docker image for backend from Github Packages (as if it's a public image out there) and compose it with the docker-compose file in milliseconds without needing to build it again as it will be done automatically in CI/CD. |