Skip to content

GitLab

  • Menu
    • Projects Groups Snippets
      Help
Projects Groups Snippets
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in / Register
  • baobaxia-mucua baobaxia-mucua
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 16
    • Issues 16
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 2
    • Merge requests 2
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Packages & Registries
    • Packages & Registries
    • Package Registry
    • Infrastructure Registry
  • Analytics
    • Analytics
    • Value stream
    • Repository
  • Wiki
    • Wiki
  • External wiki
    • External wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • NPDD
  • baobaxia-mucuabaobaxia-mucua
  • Merge requests
  • !1

Closed
Created 3 years ago by Alice Bonafé@aliceOwner
  • Report abuse
Report abuse

Dockerfile agora faz tudo, ou quase, falta fazer café

  • Overview 0
  • Commits 10
  • Changes 2

Com as mudanças adicionadas ao Dockerfile, agora quando buildar a imagem, já criará a mucua e levantará o servidor da API.

Por padrão, o Dockerfile já possui as variáveis necessárias para configurar a mucua além de permitir passar argumentos ao processo de build, personalizando assim a mucua que será criada, por exemplo:

docker build -t bbx-fastapi --build-arg MUCUA='Voadora' . 
  • Alice Bonafé @alice added 1 commit 3 years ago

    added 1 commit

    • efbee389 - Faltou fechar o bloco

    Compare with previous version

    By batata frita on 2021-08-26T21:54:25 (imported from GitLab)

  • You're only seeing other activity in the feed. To add a comment, switch to one of the following options.
Please register or sign in to reply
Compare
  • master (base)

and
  • latest version
    efbee389
    10 commits, 3 years ago

2 files
+ 41
- 7

    Preferences

    File browser
    Compare changes
Docke‎rfile‎ +25 -6
READ‎ME.md‎ +16 -1
Dockerfile
+ 25
- 6
  • View file @ efbee389

  • Edit in single-file editor

  • Edit in Web IDE


FROM debian:bullseye
ARG BALAIO='Rede Mocambos Acervo'
ARG EMAIL='mocambola@mocambos.net'
ARG MOCAMBO='Casa de Cultura Tainã'
ARG MOCAMBOLA='mocambola'
ARG MUCUA='Abdias Nascimento'
ARG SENHA='livre'
RUN apt-get update
RUN apt-get install -y python3-pip git-annex
RUN apt-get update && apt-get install -y \
python3-pip \
git-annex
COPY requirements.txt /
COPY requirements/* /requirements/
Show 20 lines Show all unchanged lines Show 20 lines
COPY ./baobaxia /baobaxia
RUN mkdir -p data/bbx/balaios
# Gambiarra para manter o docker rodando..
ENTRYPOINT ["tail", "-f", "/dev/null"]
RUN git config --global user.email "$EMAIL"
RUN git config --global user.name "$MUCUA"
RUN criar_mucua --path='/data/bbx/balaios' \
--balaio "$BALAIO" \
--mucua "$MUCUA" \
--mocambo "$MOCAMBO" \
--mocambola "$MOCAMBOLA" \
--email "$EMAIL" \
--password "$SENHA" \
--smid_len 13 \
--slug_name_len 21 \
--slug_smid_len 5 \
--slug_sep "_"
ENTRYPOINT ["uvicorn", "baobaxia.acervo:api", "--host", "0.0.0.0", "--port", "80"]
README.md
+ 16
- 1
  • View file @ efbee389

  • Edit in single-file editor

  • Edit in Web IDE


Show all unchanged lines Show 20 lines
## Instalação com docker
Criar a imagem com:
Criar a imagem com dados padrões da Casa de Cultura Tainã:
```
sudo docker build -t bbx-fastapi .
```
Criar a imagem com dados personalizados:
```
sudo docker build -t bbx-fastapi \
--build-arg BALAIO='Nosso Balaio' \
--build-arg EMAIL='a-gente@email.net' \
--build-arg MOCAMBO='Comunidade' \
--build-arg MOCAMBOLA='mocambola' \
--build-arg MUCUA='Itinerante' \
--build-arg SENHA='tem que trocar' .
```
e iniciar com
```
sudo docker run --name xango1 -p 80:80 bbx-fastapi
```
Pronto, agora você já tem a API de Baobáxia rodando e possui uma mucua criada.
---
## Instalação com virtualenv e pip
Show 20 lines Show all unchanged lines
0 Assignees
None
Assign to
0 Reviewers
None
Request review from
Milestone
No milestone
None
None
Time tracking
No estimate or time spent
Labels
0
None
0
None
    Assign labels
  • Manage project labels

Lock merge request
Unlocked
1
1 participant
Alice Bonafé
Reference: npdd/baobaxia-mucua!1
Source branch: master

Menu

Projects Groups Snippets
Help

Data Center Comunitário Livre - DCCL