Skip to content
This repository has been archived by the owner on Feb 23, 2020. It is now read-only.

#142 Renew devops configs #195

Merged
merged 2 commits into from Jun 15, 2018
Merged

#142 Renew devops configs #195

merged 2 commits into from Jun 15, 2018

Conversation

duker33
Copy link
Contributor

@duker33 duker33 commented Jun 8, 2018

Closes #142

@duker33 duker33 self-assigned this Jun 8, 2018
docker/Makefile Outdated
build: static
$(dc) build stb-python
$(dc) build app
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

dc -> dcb

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

build: static -> build: build-static

Copy link
Contributor Author

@duker33 duker33 Jun 8, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TO-DO

docker/Makefile Outdated
$(dc) up -d stb-python
$(d) run --rm --volumes-from stb-python --workdir=/usr/app/src -it coala/base coala
$(dc) up -d app
$(d) run --rm --volumes-from app --workdir=/usr/app/src -it coala/base coala
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be nice to move/use the coala as service to docker-compose

Copy link
Contributor Author

@duker33 duker33 Jun 8, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TO-DO

docker/Makefile Outdated
$(dc) exec stb-python python manage.py migrate
$(dc) exec app python manage.py migrate

fixtures:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

load-fixtures will be more clearly

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@artemiy312 ,
we have conflict with short vs clear commands.
I think commands should be short for the first. And clear for the second.
We type them much more often, then remember.
We all use Linux command ls, but not show-files.

New teammates will dig into Makefile anyway: with short or not commands.
So, i propose to leave short names of the commands, but add some doc for them in Makefile. We'll do it at fidals/shopelectro#303

&& python manage.py loaddata stroyprombeton/fixtures/dump.json \
"

prices:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

generate-prices will be more clearly

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@artemiy312 , let's leave prices, because we already have django command with the same name

docker/Makefile Outdated
$(MAKE) build-static
# Create admin user with login/pass: admin/asdfjkl;
# Launch "collectstatic" not in static recipe because ManifestStaticStorage writes to db
$(dc) exec app bash -c "\
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe we should reuse existing receipts instead of it, what do you think?

$(MAKE) migrate
$(MAKE) load-fixtures
$(MAKE) collectstatic

Copy link
Contributor Author

@duker33 duker33 Jun 8, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TO-DO

@@ -0,0 +1,5 @@
# Identify the dependencies folder
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It must be ignored by git

@@ -0,0 +1,6 @@
# Exposed ports
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It must be ignored by git

FROM python:slim

RUN apt-get update \
# wget is needed for working with ftp
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We do not work with ftp

Copy link
Contributor Author

@duker33 duker33 Jun 8, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TO-DO

# wget is needed for working with ftp
# git is needed for pip
&& apt-get install --no-install-recommends --no-install-suggests -y \
wget git make wkhtmltopdf xvfb gettext
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

seems it will be enoughwkhtmltopdf xvfb gettext

Copy link
Contributor Author

@duker33 duker33 Jun 8, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@artemiy312 , git and make are required too

@@ -0,0 +1,8 @@
FROM fidals/se:dev
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fidals/se:dev -> fidals/stb:dev

Copy link
Contributor Author

@duker33 duker33 Jun 8, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TO-DO

@duker33 duker33 added the discuss issue needs to finish discussion before start working label Jun 8, 2018
duker33 referenced this pull request in fidals/shopelectro Jun 8, 2018
@duker33
Copy link
Contributor Author

duker33 commented Jun 8, 2018

@artemiy312 , refactored drone.yml too. Pay attention to it plz

Copy link
Contributor

@ArtemijRodionov ArtemijRodionov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Few comment about Dockerfile for python

docker/Makefile Outdated
# for serv env
deploy-dev:
$(MAKE) create-env
# $(MAKE) create-config
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems it should be uncommented

Copy link
Contributor Author

@duker33 duker33 Jun 14, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it depends on the task. I'll add comment

TODO

RUN apt-get update \
# git is needed for pip
&& apt-get install --no-install-recommends --no-install-suggests -y \
git make wkhtmltopdf xvfb gettext
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We do not use git and make anywhere, so we should remove it.

Copy link
Contributor Author

@duker33 duker33 Jun 14, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@artemiy312 ,

> # git is needed for pip

Removed it.

# git is needed for pip
&& apt-get install --no-install-recommends --no-install-suggests -y \
git make wkhtmltopdf xvfb gettext
&& apt-get remove --purge -y git \
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This line should be removed as above

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done.

@duker33 duker33 changed the title #142 Draft for devops configs renew #142 Renew devops configs Jun 14, 2018
@duker33 duker33 removed the discuss issue needs to finish discussion before start working label Jun 14, 2018
- Review#2 fix. Annotate commented string
- Review#2 fix. Rm git install from dockerfile.dev
- Fix forgotten env vars. Rm pdd task in favor of se#345
- Resurrect#1 gulp build
- Launch tests #1
- Fix forgotten drone file
- Review#1 fixes
- Devops configs renew
@duker33 duker33 merged commit 025bae7 into master Jun 15, 2018
@duker33 duker33 deleted the 142_copy_local_env branch June 15, 2018 15:43
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants