Skip to content

Commit

Permalink
Merge pull request #18 from rubencabrera/semantic-release
Browse files Browse the repository at this point in the history
Auto semantic release
  • Loading branch information
rubencabrera authored Sep 13, 2019
2 parents fd3f9ad + 882dbd0 commit 15a0250
Show file tree
Hide file tree
Showing 5 changed files with 82 additions and 23 deletions.
29 changes: 20 additions & 9 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,25 @@ env:
global:
- secure: TDAVU5ZV+gR6SfUFTHay+l7/EY6La2HfPfA4lV5pyn+B1xdufLBnzxK89OGyxFDjNUUwsvwmA1iKRODj23Qktd38Ixt+JxfBmPoJkgE7qdDxFKS2KSPsKT/dYqyI8Z/Ja0xi45HItoRlIO7VoyaPI4QkaWH9PdG1SZe7rPUbAhfi703pt74gJwOUwXAPT+ltmgRW3X9D3NH4UwcLDZdc24p0muQfa5+3Tyo0BwpPDZq3XyaUmaanHVdNqOcrEtWVdst6HyyyV458MMc58mH0UE/NcZgGWjHV7GXjMl9OXINA0+nV//jOkhSmrWSPXAhOPdlmNNg9bWFuIwI7UzVWQ+tUEfzDj1xamXniRECVwuD7/oU+wAswHcWj2/p5iUQ4aMf6pfxe/ECgvMC8HdzXzafwEJ9cIYsH32REq203eNNL6E/Gk7i5iY75f4XcAjMwop0X6khqg1V3APkPrOnt5uOvz5dmykMS306OKe6ZcO0XiNuM6Gn4yVtfZ59wLxTCJn6PJpEHQB20DNI4NN/Y528ESqRDrHOKl8rJuPRbTspfjxB7HrmL3EW5ynZ+IL2WDfC9e+S1+1jtgylEF1swCgpqg+qpfHpZLdwKZysLg+p3buVBAMDhWG5icF7V3cR6ACsjFNXbl98jk20EfLdO4bO1aJJz2OcVMYf5BuU8ZsE=
- secure: o235uaW/z0gHhXFI46MeMpfsjVoVJTClm3N7X8Fcv3qfHC4euxNWvRSkOrh11ZqC6tHjH3LLb5IV4HmGiPShjCcSXuxlOiTQeVciNihsjLybule6kmypO8TJWuJPi3DHVBr/naUBnIyUzA2vDedJ0Va3pzSU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+YBzzPA9Cma7/x80Z13QZNhT7VCV0ZjdDGpyIuEhkhmFCXscgRvOaLzKZWe5uyNpRdxeUFPXTlnimKg/amrrPL3ls6xoixkA5XyIrYJuL4/eXPGE=
services:
- docker
script:
- docker build -t "${TRAVIS_REPO_SLUG}:${TRAVIS_BRANCH}" .
deploy:
provider: script
skip_cleanup: true
script: ./.travis/docker_push.bash
on:
tags: true
branch: 12
jobs:
include:
- stage: build docker image
name: Test build docker image
script:
- docker build -t "${TRAVIS_REPO_SLUG}:${TRAVIS_BRANCH}" .
- stage: test
script: docker run "${TRAVIS_REPO_SLUG}:${TRAVIS_BRANCH}" /opt/odoo/odoo-bin --version
- stage: deploy
provider: script
skip_cleanup: true
script:
- nvm install lts/*
- npx semantic-release
on:
tags: true
branch: 12

# ver package.json a medias de https://revelry.co/semantic-release/
2 changes: 2 additions & 0 deletions .travis/docker_push.bash
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
#! /bin/bash

set -e

echo "$DOCKER_PASSWORD" | docker login --username "$DOCKER_LOGIN" --password-stdin
docker push "${TRAVIS_REPO_SLUG}:${TRAVIS_BRANCH}";
45 changes: 42 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,30 @@ many are specific to local regulations and contradict themselves.

For localisation, I am currently using Spain. If deemed useful, new
branches and tags for images could be created for other countries,
[open an issue](https://github.com/rubencabrera/odoo-docker/issues/new) if you need that, it's an easy win but I haven't
[open an issue][issue-link] if you need that, it's an easy win but I haven't
had to do it.

# Environment variables
# Usage

## Requirements

You will need Docker and docker compose ([install docs][compose-install]).

This repo includes docker compose files you can use to run Odoo completely
on containers, mounting volumes for persistent data.

Regarding resources, will vary heavily depending on the number of users and
data, but a bare minimum with not much guarantees will be 1GB of RAM. It will
be uch better with something above 4GB.

## Running with docker-compose

Run `docker-compose up` in the root path.

## Environment variables

Odoo uses a config file that is a bit of a pain with a docker
container. This images allows you to pass those config values in
container. This images allow you to pass those config values in
environment variables. Here's a list of the available ones, you can
find them documented in the official Odoo documentation with the
same name in lower case:
Expand Down Expand Up @@ -73,3 +90,25 @@ same name in lower case:
| `XMLRPC_PORT` | `8069` |
| `XMLRPCS` | `True` |
| `XMLRPCS_PORT` | `8071` |


# Getting help

If you need help of have questions, [open an issue][issue-link] or get in
contact. Please bear in mind this is not my current job and this image is
working well enough for my needs, so I haven't alloted time to maintain it,
but I'll do my best to help, especially if it's affecting your product.


# Ayuda en español

Si necesitas ayuda en español usando esta imagen de Odoo o con algún tema
relacionado, [abre un Issue][issue-link] o ponte en contacto conmigo.

Por favor, ten en cuenta que este no es mi trabajo actualmente y que esta
imagen funciona lo bastante bien como para no requerir mi tiempo, puede que
tarde más de lo que esperas si tu problema es complicado, pero haré lo posible
por ayudar.

[issue-link]: https://github.com/rubencabrera/odoo-docker/issues/new
[compose-install]: https://docs.docker.com/compose/install/]
25 changes: 15 additions & 10 deletions contrib/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
# Se necesita docker y docker-compose. Ejecutar con:
# Compose file suitable for local development.
# Run with:
# docker-compose -f docker-compose.yml up
# Se iniciará un contenedor con postgresql y otro con odoo.
# Para evitar conflictos con el puerto en local si ya hay postgres
# se usa el 5433 en lugar del estándar 5432 de postgresql.
# Will start a container with odoo and another one with postgres exposed
# on port 5433 (in case you have a local postgres already running).
# Also mounts a volume in your machine's /opt/odooo-docker/opt path mounted
# where the container's code is. The projects are cloned there, so you can
# use git to manage each container's repo branches.
---
version: '3.1'
services:
Expand All @@ -13,29 +16,31 @@ services:
- POSTGRES_USER=odoo
ports:
- "5433:5432"
restart: always
volumes:
- data_storage:/var/lib/postgresql/data
odoo12:
container_name: odoo12
depends_on:
- db
environment:
- ADMIN_PASSWD=FIXME
- DB_FILTER=False
image: "rubencabrera/odoo-docker:12.0.4"
ports:
- "8169:8069"
- "8171:8071"
- "8172:8072"
environment:
- ADMIN_PASSWD=FIXME
- DB_FILTER=False
restart: always
volumes:
- odoo12_data:/var/lib/odoo
- codigo:/opt
- odoo12_data:/var/lib/odoo
volumes:
data_storage:
odoo12_data:
codigo:
driver: local
driver_opts:
o: bind
type: none
device: /opt/odoo-docker/opt # This is where the code will live.
data_storage:
odoo12_data:
4 changes: 3 additions & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,13 @@
version: '3.1'
services:
db:
image: postgres:9.6
environment:
- POSTGRES_PASSWORD=odoo
- POSTGRES_USER=odoo
image: postgres:9.6
ports:
- "5433:5432"
restart: always
volumes:
- data_storage:/var/lib/postgresql/data
odoo12:
Expand All @@ -24,6 +25,7 @@ services:
- "8069:8069"
- "8071:8071"
- "8072:8072"
restart: always
volumes:
- odoo_data:/var/lib/odoo
volumes:
Expand Down

0 comments on commit 15a0250

Please sign in to comment.