Code Monkey home page Code Monkey logo

deployment-tool's People

Contributors

biaspro avatar danigm avatar darccio avatar edulix avatar endika avatar findeton avatar leio10 avatar ruescasd avatar virako avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

deployment-tool's Issues

No package matching 'node' is available

When I execute:
time sudo ansible-playbook -i inventory playbook.yml

I receive next error:
TASK [Packages, Installing packages] *******************************************
failed: [localhost] (item=[u'git', u'htop', u'curl', u'postgresql-9.4', u'postgresql-9.4-repmgr', u'mercurial', u'nginx', u'supervisor', u'node', u'libffi-dev', u'virtualenvwrapper', u'libjpeg8-dev', u'libpq-dev=9.4*', u'libpq5=9.4*', u'python-psycopg2', u'python3-pip', u'python3', u'python-setuptools', u'build-essential', u'python-dev', u'vim', u'libgmp-dev', u'make', u'm4', u'p7zip-full']) => {"failed": true, "item": ["git", "htop", "curl", "postgresql-9.4", "postgresql-9.4-repmgr", "mercurial", "nginx", "supervisor", "node", "libffi-dev", "virtualenvwrapper", "libjpeg8-dev", "libpq-dev=9.4*", "libpq5=9.4*", "python-psycopg2", "python3-pip", "python3", "python-setuptools", "build-essential", "python-dev", "vim", "libgmp-dev", "make", "m4", "p7zip-full"], "msg": "No package matching 'node' is available"}

[FIX][NEXT] Config files unreadable

When executed vagrant provision in this part https://github.com/agoravoting/agora-dev-box/blob/next/agora-elections/main.yml#L14

'templates' folder not exist. I execute code in manual mode

cp /vagrant/agora-elections/templates/application.local.conf /home/agoraelections/agora-elections/conf/application.local.conf
chmod 0644  /home/agoraelections/agora-elections/conf/application.local.conf
chown agoraelections:  /home/agoraelections/agora-elections/conf/application.local.conf

and repear for test.local.conf file

Error connecting authorities

Hi,
We are following the tutorial on production deployment and when trying to connect the authorities, we get the following error when running 'eotest':
`> Starting server on port 8000

using the following authorities:

  1. auth1.zaragozaencomun.com (this is us, acting as orchestra director)
  2. auth2.zaragozaencomun.com

Creating election 7824
Traceback (most recent call last):
File "/usr/bin/eotest.py", line 490, in
main(sys.argv[1:])
File "/usr/bin/eotest.py", line 485, in main
eval(command + "(args)")
File "", line 1, in
File "/usr/bin/eotest.py", line 452, in full
pkFile = create(args)
File "/usr/bin/eotest.py", line 361, in create
startElection(electionId, startUrl, startData)
File "/usr/bin/eotest.py", line 279, in startElection
r = session.request('post', url, data=json.dumps(data), verify=CALIST, cert=(CERT, KEY))
File "/home/eorchestra/venv/local/lib/python2.7/site-packages/requests/sessions.py", line 508, in request
resp = self.send(prep, **send_kwargs)
File "/home/eorchestra/venv/local/lib/python2.7/site-packages/requests/sessions.py", line 618, in send
r = adapter.send(request, **kwargs)
File "/home/eorchestra/venv/local/lib/python2.7/site-packages/requests/adapters.py", line 508, in send
raise ConnectionError(e, request=request)
requests.exceptions.ConnectionError: HTTPSConnectionPool(host='auth1.zaragozaencomun.com', port=5000):Max retries exceeded with url: /public_api/election (Caused by NewConnectionError('<urllib3.connection.VerifiedHTTPSConnection object at 0x7fa30a171490>: Failed to establish a new connection: [Errno 113] No route to host',))
`
We try to regenerate certs unsuccessfully obtaining same error.
Any tip?

Error vagrant provision

Hi everyone, im having an issue while executing vagrant provision comand, it do everything correctly until:

$ vagrant provision
...
TASK [EOrchestra, installing extra pip packages] *******************************
ok: [default] => (item=setuptools) => {"changed": false, "cmd": "/home/eorchestra/venv/bin/pip install setuptools", "item": "setuptools", "name": "setuptools", "requirements": null, "state": "present", "stderr": "", "stdout": "New python executable in /home/eorchestra/venv/bin/python2\nAlso creating executable in /home/eorchestra/venv/bin/python\nInstalling setuptools, pip...done.\nRunning virtualenv with interpreter /usr/bin/python2\nRequirement already satisfied (use --upgrade to upgrade): setuptools in /home/eorchestra/venv/lib/python2.7/site-packages\nCleaning up...\n", "stdout_lines": ["New python executable in /home/eorchestra/venv/bin/python2", "Also creating executable in /home/eorchestra/venv/bin/python", "Installing setuptools, pip...done.", "Running virtualenv with interpreter /usr/bin/python2", "Requirement already satisfied (use --upgrade to upgrade): setuptools in /home/eorchestra/venv/lib/python2.7/site-packages", "Cleaning up..."], "version": null, "virtualenv": "/home/eorchestra/venv"}
.
.
.
.
failed: [default] (item=requests[security]) => {"cmd": "/home/eorchestra/venv/bin/pip install requests[security]", "failed": true, "item": "requests[security]", "msg": "stdout: Downloading/unpacking requests[security]\nDownloading/unpacking urllib3<1.23,>=1.21.1 (from requests[security])\nDownloading/unpacking certifi>=2017.4.17 (from requests[security])\nDownloading/unpacking chardet<3.1.0,>=3.0.2 (from requests[security])\nDownloading/unpacking idna<2.7,>=2.5 (from requests[security])\nDownloading/unpacking pyOpenSSL>=0.14 (from requests[security])\nDownloading/unpacking cryptography>=1.3.4 (from requests[security])\n Running setup.py (path:/tmp/pip-build-d47kGh/cryptography/setup.py) egg_info for package cryptography\n Traceback (most recent call last):\n File "", line 17, in \n File "/tmp/pip-build-d47kGh/cryptography/setup.py", line 28, in \n "cryptography requires setuptools 18.5 or newer, please upgrade to a "\n RuntimeError: cryptography requires setuptools 18.5 or newer, please upgrade to a newer version of setuptools\n Complete output from command python setup.py egg_info:\n Traceback (most recent call last):\n\n File "", line 17, in \n\n File "/tmp/pip-build-d47kGh/cryptography/setup.py", line 28, in \n\n "cryptography requires setuptools 18.5 or newer, please upgrade to a "\n\nRuntimeError: cryptography requires setuptools 18.5 or newer, please upgrade to a newer version of setuptools\n\n----------------------------------------\nCleaning up...\nCommand python setup.py egg_info failed with error code 1 in /tmp/pip-build-d47kGh/cryptography\nStoring debug log for failure in /home/eorchestra/.pip/pip.log\n"}

Basically says: "RuntimeError: cryptography requires setuptools 18.5 or newer, please upgrade to a newer version of setuptools"

But it is already installed:

$ easy_install --version
setuptools 39.0.1 from /usr/local/lib/python2.7/dist-packages (Python 2.7)

$ pip list
adium-theme-ubuntu (0.3.4)
ansible (2.1.6.0)
astroid (1.6.3)
backports.functools-lru-cache (1.5)
beautifulsoup4 (4.4.1)
boto (2.38.0)
chardet (2.3.0)
configparser (3.5.0)
cryptography (1.2.3)
duplicity (0.7.6)
ecdsa (0.13)
enum34 (1.1.6)
futures (3.2.0)
html5lib (0.999)
httplib2 (0.9.1)
idna (2.0)
ipaddress (1.0.16)
isort (4.3.4)
Jinja2 (2.8)
lazy-object-proxy (1.3.1)
lockfile (0.12.2)
lxml (3.5.0)
MarkupSafe (0.23)
mccabe (0.6.1)
ndg-httpsclient (0.4.0)
numpy (1.11.0)
paramiko (1.16.0)
pip (9.0.3)
pyasn1 (0.1.9)
pycrypto (2.6.1)
pycurl (7.43.0)
pygobject (3.20.0)
pylint (1.8.4)
pyOpenSSL (0.15.1)
python-apt (1.1.0b1+ubuntu0.16.4.1)
python-cloudfiles (1.7.10)
pyxdg (0.25)
PyYAML (3.11)
requests (2.9.1)
setuptools (39.0.1)
singledispatch (3.4.0.3)
six (1.10.0)
unity-lens-photos (1.0)
urllib3 (1.13.1)
wheel (0.31.0)
wrapt (1.10.11)

Connecting the authorities step Error

We are following the tutorial on the deployment on the development box literally and when trying to connect the authorities, we get this error, we are working on the Next branch as suggested with the new version of the system as was published a few days ago, we get the following error when running 'eotest':

using the following authorities:

  1. nvotes.com (this is us, acting as orchestra director)
  2. nvotes.com

Creating election 3682
Traceback (most recent call last):
File "/usr/bin/eotest.py", line 490, in
main(sys.argv[1:])
File "/usr/bin/eotest.py", line 485, in main
eval(command + "(args)")
File "", line 1, in
File "/usr/bin/eotest.py", line 452, in full
pkFile = create(args)
File "/usr/bin/eotest.py", line 361, in create
startElection(electionId, startUrl, startData)
File "/usr/bin/eotest.py", line 279, in startElection
r = session.request('post', url, data=json.dumps(data), verify=CALIST, cert=(CERT, KEY))
File "/home/eorchestra/venv/local/lib/python2.7/site-packages/requests/sessions.py", line 488, in request
resp = self.send(prep, **send_kwargs)
File "/home/eorchestra/venv/local/lib/python2.7/site-packages/requests/sessions.py", line 609, in send
r = adapter.send(request, **kwargs)
File "/home/eorchestra/venv/local/lib/python2.7/site-packages/requests/adapters.py", line 487, in send
raise ConnectionError(e, request=request)
requests.exceptions.ConnectionError: HTTPSConnectionPool(host='nvotes.com', port=5000): Max retries exceeded with url: /public_api/election (Caused by NewConnectionError('<requests.packages.urllib3.connection.VerifiedHTTPSConnection object at 0x7f687e027610>: Failed to establish a new connection: [Errno 110] Connection timed out',))
Connection to 127.0.0.1 closed.

I have revised a similar issue but the problem appears to be different. Probably related to the packages, but that is only a guess.

Deployment instruction not work on the `Test the connection between the authorities` step

Hi,
I follow the dev deployment instruction,

But my try failed on the Test the connection between the authorities step by this error:

> Creating election 2846
Traceback (most recent call last):
  File "/usr/bin/eotest.py", line 475, in <module>
    main(sys.argv[1:])
  File "/usr/bin/eotest.py", line 470, in main
    eval(command + "(args)")
  File "<string>", line 1, in <module>
  File "/usr/bin/eotest.py", line 437, in full
    pkFile = create(args)
  File "/usr/bin/eotest.py", line 346, in create
    startElection(electionId, startUrl, startData)
  File "/usr/bin/eotest.py", line 268, in startElection
    r = requests.post(url, data=json.dumps(data), verify=False, cert=(CERT, KEY))
  File "/home/eorchestra/venv/local/lib/python2.7/site-packages/requests/api.py", line 111, in post
    return request('post', url, data=data, json=json, **kwargs)
  File "/home/eorchestra/venv/local/lib/python2.7/site-packages/requests/api.py", line 57, in request
    return session.request(method=method, url=url, **kwargs)
  File "/home/eorchestra/venv/local/lib/python2.7/site-packages/requests/sessions.py", line 475, in request
    resp = self.send(prep, **send_kwargs)
  File "/home/eorchestra/venv/local/lib/python2.7/site-packages/requests/sessions.py", line 585, in send
    r = adapter.send(request, **kwargs)
  File "/home/eorchestra/venv/local/lib/python2.7/site-packages/requests/adapters.py", line 465, in send
    raise ProxyError(e, request=request)
requests.exceptions.ProxyError: HTTPSConnectionPool(host='agoravoting.com', port=5000): Max retries exceeded with url: /public_api/election (Caused by ProxyError('Cannot connect to proxy.', error('Tunnel connection failed: 403 Forbidden',)))
Connection to 127.0.0.1 closed.

I don't change any configuration, just follow the instruction step by step.
I also read the deployment troubleshooting, but i have no idea how to fix this.

Unable to deploy via 'complete-deployment'

https://github.com/agoravoting/agora-dev-box/blob/master/doc/complete-deployment.md

I was able to reach Agora server part 1

After copying the ymls, I have run vagrant provision

I first had problems with the AgoraElections, restarting supervisor task but after adjusting the sleep time it worked.

Then got stuck at the AgoraCoreView, building task. It kept failing saying that build.sh could not be found.
However, I then ssh'd in to the box and executed the build.sh manually.
I then commented out the AgoraCoreView, building task and tried again but it then broke on a later task.

I think the provisioning needs checking. Either the guide is outdated or perhaps the provisioning steps.

I'd appreciate some assistance in getting up and running...

Error on agora1 deploy TASK [AgoraElections, activator clean & stage]

When I execute
time sudo ansible-playbook -i inventory playbook.yml -vvv
I receive a incomprehesible error on TASK [AgoraElections, activator clean & stage].
I try to execute manually /home/agoraelections/activator-1.2.12-minimal/activator clean;
This is message I obtain with user agoraelections:

Unable to open the docs in your web browser.  To open them manually navigate to:
http://typesafe.com/activator/docs
 Did not detect an activator project in this directory.
 - activator
 Load an existing project (has to be executed from the project directory)
 or print this help message if no project is found

 Sub-commands
 - activator ui
 Open the project in the UI if executed from an existing project
 directory, otherwise open a project-creation UI.

 - activator new [project-name] [template-name]
 Create a new project, prompting for project-name if missing and helping you
 find a template if template-name is not provided.

 - activator list-templates
 Fetch the latest template list and print it to the console.

Java error on election-orchestra deploy

When i execute on auth1 and auth2:
time sudo ansible-playbook -i inventory playbook.yml
I get a error:

TASK [EOrchestra, vfork init random device] ************************************
fatal: [localhost]: FAILED! => {"changed": true, "cmd": "bash -l -c \"source /home/eorchestra/.vfork_env && vog -rndinit RandomDevice /dev/urandom\"", "delta": "0:00:00.235648", "end": "2017-06-26 12:42:13.241989", "failed": true, "rc": 1, "start": "2017-06-26 12:42:13.006341", "stderr": "Exception in thread \"main\" java.lang.UnsupportedClassVersionError: vfork/ui/gen/GeneratorTool : Unsupported major.minor version 52.0\n\tat java.lang.ClassLoader.defineClass1(Native Method)\n\tat java.lang.ClassLoader.defineClass(ClassLoader.java:803)\n\tat java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)\n\tat java.net.URLClassLoader.defineClass(URLClassLoader.java:442)\n\tat java.net.URLClassLoader.access$100(URLClassLoader.java:64)\n\tat java.net.URLClassLoader$1.run(URLClassLoader.java:354)\n\tat java.net.URLClassLoader$1.run(URLClassLoader.java:348)\n\tat java.security.AccessController.doPrivileged(Native Method)\n\tat java.net.URLClassLoader.findClass(URLClassLoader.java:347)\n\tat java.lang.ClassLoader.loadClass(ClassLoader.java:425)\n\tat sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:312)\n\tat java.lang.ClassLoader.loadClass(ClassLoader.java:358)\n\tat sun.launcher.LauncherHelper.checkAndLoadMain(LauncherHelper.java:482)", "stdout": "", "stdout_lines": [], "warnings": []}

Despite Im using oracle-java8-installer.

Can you help me?

Fallo vagrant provision en Agora server

Siguiendo la guía para el despliegue de Agora Voting (devel_deployment.md) funciona correctamente hasta el provision de agora server. En este paso, Agora server (part 1), cuando ejecuto el comando vagrant provision me lanza el siguiente error:

agoravoting error

Las siguientes versiones son las que he probado con el mismo resultado:

  • Vagrant: 1.8.1 y 1.8.7
  • Ansible: 2.1.0 y 2.1.1
  • Virtualbox: 5.0.24 y 5.1.10

Saludos.

infinite loop when creating election

Good morning. I've been trying to install agora following the instructions. At this moment I'm stuck with election creation. The election itself is written into the database however I can't start the it. The browser log shows that when I press the 'Create election' the api call create is invoked and it returs the following json:

{"date":"2018-05-04 10:26:56.791","payload":"ok"}

After this call it seems to enter into an infinite loop asking for election data and election stats. Seems that it's waiting for something to happen.

/elections/api/election/41

{"date":"2018-05-04 10:26:57.816","payload":{"id":41,"configuration":{"id":41,"layout":"simple","director":"aut1.aspgems.com","authorities":["aut2.aspgems.com"],"title":"New election","description":"","questions":[{"description":"","layout":"accordion","max":1,"min":1,"num_winners":1,"title":"New question 0","tally_type":"plurality-at-large","answer_total_votes_percentage":"over-total-valid-votes","answers":[{"id":0,"category":"","details":"","sort_order":0,"urls":[],"text":"Yes"}],"extra_options":{"shuffle_categories":true,"shuffle_all_options":true,"shuffle_category_list":[],"show_points":false}}],"start_date":"2015-01-27T16:00:00.001","end_date":"2015-01-27T16:00:00.001","presentation":{"share_text":[{"network":"Twitter","button_text":"","social_message":"I have just voted in election __URL__, you can too! #nvotes"},{"network":"Facebook","button_text":"","social_message":"__URL__"}],"theme":"default","urls":[],"theme_css":""},"real":false,"extra_data":"{}","virtual":false,"virtualSubelections":[],"logo_url":""},"state":"registered","startDate":"2015-01-27T16:00:00.001","endDate":"2015-01-27T16:00:00.001","real":false,"virtual":false,"logo_url":""}}

and /elections/api/election/41/stats

{"date":"2018-05-04 10:26:57.899","payload":{"totalVotes":0,"votes":0,"days":[]}}

[NEXT] AgoraGui, config setup fail in deployment system

Provisoning Agora server show the next fail:

TASK: [AgoraGui, config setup] *******************************************************************
fatal: [default] => {'msg': "AnsibleUndefinedVariable: One or more undefined variables: 'dict object' has no attribute 'name'", 'failed': True}
fatal: [default] => {'msg': "AnsibleUndefinedVariable: One or more undefined variables: 'dict object' has no attribute 'name'", 'failed': True}
FATAL: all hosts have already failed -- aborting

Process fails when trying to install virtualenv

Good morning.

I've problems when trying to install virtualenv:

failed: [default] (item={u'url': u'http://es.archive.ubuntu.com/ubuntu/pool/universe/p/python-virtualenv/virtualenv_1.11.6+ds-1_all.deb', u'pkg': u'virtualenv_1.11.6+
ds-1_all.deb', u'sha256sum': u'1784c739a8f59c70faf2759bb27e96fe7dc231f8f98f9351fb64fc613927a260'}) => {"changed": false, "dest": "/tmp/virtualenv_1.11.6+ds-1_all.deb"
, "item": {"pkg": "virtualenv_1.11.6+ds-1_all.deb", "sha256sum": "1784c739a8f59c70faf2759bb27e96fe7dc231f8f98f9351fb64fc613927a260", "url": "http://es.archive.ubuntu.
com/ubuntu/pool/universe/p/python-virtualenv/virtualenv_1.11.6+ds-1_all.deb"}, "msg": "Request failed", "response": "HTTP Error 404: Not Found", "state": "absent", "s
tatus_code": 404, "url": "http://es.archive.ubuntu.com/ubuntu/pool/universe/p/python-virtualenv/virtualenv_1.11.6+ds-1_all.deb"}

Any clue about what might be happening? Any other method to install agora? I find it pretty difficult and obscure.

No public key on connecting authorities

When we try to connecting authorities, auth1 no receive public key
I have private ips in /etc/hosts

> Starting server on port 8000

using the following authorities:
 1. auth1.zaragozaencomun.com (this is us, acting as orchestra director)
 2. auth2.zaragozaencomun.com


> Creating election 1343
/home/eorchestra/venv/local/lib/python2.7/site-packages/urllib3/util/ssl_.py:339: SNIMissingWarning: An HTTPS request has been made, but the SNI (Subject Name Indication) extension to TLS is not available on this platform. This may cause the server to present an incorrect TLS certificate, which can cause validation failures. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings
  SNIMissingWarning
/home/eorchestra/venv/local/lib/python2.7/site-packages/urllib3/util/ssl_.py:137: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings
  InsecurePlatformWarning
> <Response [202]>
* Timeout waiting for public key
No public key, exiting..

Error de Redirección

Buenas tardes,
He comprobado visitando vuestra página que hay una comportamiento extraño en la redirección con la pagina de inicio. Cuando pulso el botón entrar me redirige a la pantalla de Contacta con nosotros. ¿Esto es así? Cuando revisamos el funcionamiento de la aplicación anteriormente, el hacer click en Entrar nos redirigía al login.
image

image

Espero vuestra respuesta, pues estamos viendo el funcionamiento del portal para la realización de pruebas de interfaz gráfica para la asignatura de Evolución y Gestión de la configuración de la US.

Gracias, Un Saludo!

Playbook no encontrado

En la documentación de cómo desplegar un entorno de producción, en la sección 'Configure agora2 as a slave' se indica que se ejecute el comando:

agora@agora2:~/agora-dev-box/ $ cp doc/production/playbook.slave.yml playbook.yml

El caso es que ese playbook no existe en el repositorio.

Saludos

inconsistent deployment instructions

Deployment instructions say that 4 machines with at least 3gb of ram are required. However, checking the config file for agora servers just java requires at least 4 gigs:

java:
# maximum size of heap memory in Megabytes (int). Default: 4000. Your total
# RAM + SWAP needs to be bigger than this. If you are going to do very
# big tallies (hundred of thousands of votes or millions), you will need to
# change this to something bigger.
max_heap_memory_usage: 4000

What is the minimum amount of ram required to run a server considering not only java but all other pieces requirements?

config.master.json is not up to date

the file doc/production/config.master.yml is different then config.yml from root
for example the parameter cache_expiration_seconds is missing. Please review

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.