add ganache fixes to nodejs and yarn. update requirements.yml, add two install methods for ganache, fixes to remix

This commit is contained in:
Bryan Black 2022-10-27 21:59:13 -07:00
parent 8077c51cf7
commit 6bfbc0a68a
8 changed files with 53 additions and 9 deletions

View file

@ -1,11 +1,12 @@
--- ---
- hosts: vagrant - hosts: vagrant
vars: vars:
yarn_clean_install: false docker_users:
yarn_version: latest - ziion
become: true become: true
roles: roles:
- common - common
- geerlingguy.docker - geerlingguy.docker
- truffle - truffle
- ganache
- remix

View file

@ -8,7 +8,7 @@
pkg: pkg:
- curl - curl
- name: Remove node - name: Remove nodejs
become_user: root become_user: root
become: true become: true
apt: apt:
@ -18,12 +18,12 @@
pkg: pkg:
- nodejs - nodejs
- name: add node apt repository - name: add nodejs apt repository
become_user: root become_user: root
become: true become: true
ansible.builtin.shell: "curl -fsSL https://deb.nodesource.com/setup_lts.x | sudo -E bash - " ansible.builtin.shell: "curl -fsSL https://deb.nodesource.com/setup_lts.x | sudo -E bash - "
- name: Install node - name: Install nodejs
become_user: root become_user: root
become: true become: true
apt: apt:
@ -32,3 +32,9 @@
cache_valid_time: 604800 cache_valid_time: 604800
pkg: pkg:
- nodejs - nodejs
- name:
become_user: root
become: true
ansible.builtin.shell: "corepack enable"

View file

@ -0,0 +1,8 @@
- name: Create ganache
community.docker.docker_container:
name: ganache
image: trufflesuite/ganache:v7.1.0
state: started
restart: true
ports:
- "127.0.0.1:8545:8545" # discuss if this should be bind all gitlab.com/reel/ziion-tools/-/issues/4

View file

@ -0,0 +1,7 @@
- name: Install ganache
community.general.npm:
name: ganache
version: '7.1.0'
path: /usr/local/ganache
global: true
state: present

View file

@ -0,0 +1,7 @@
---
#- import_tasks: install-via-npm.yml
# tags: install-via-npm
- import_tasks: install-via-docker.yml
tags: install-via-docker

View file

@ -0,0 +1,9 @@
- name: Create remix-ide
community.docker.docker_container:
name: remix-ide
image: remixproject/remix-ide
state: started
restart: true
ports:
# Publish container port 80 as host port 8080
- "127.0.0.1:8080:80"

View file

@ -1,9 +1,8 @@
--- ---
# ansible-galaxy install -r roles/requirements.yml # ansible-galaxy install -r roles/requirements.yml
collections:
- community.docker
- src: fubarhouse.yarn
# version: latest
name: fubarhouse.yarn
- src: geerlingguy.docker - src: geerlingguy.docker
name: geerlingguy.docker name: geerlingguy.docker

View file

@ -0,0 +1,7 @@
- name: Install truffle
community.general.npm:
name: truffle
version: '5.5.14'
path: /usr/local/truffle
global: true
state: present