Skip to content
Snippets Groups Projects
Commit d8cfd102 authored by Noe Nieto's avatar Noe Nieto :speech_balloon:
Browse files

Unforgivable grammar mistakes (MR !13)

parent c2f52c64
No related branches found
No related tags found
1 merge request!14Replacement MR for defunct MR13
This commit is part of merge request !14. Comments created here will be created in the context of that merge request.
#! /bin/sh #! /bin/sh
echo Shipwright commands: echo "Shipwright commands:"
ls -w1 "$HOME/.local/ldh_developer/bin" ls -w1 "$HOME/.local/ldh_developer/bin"
echo echo
...@@ -55,7 +55,7 @@ def only_if_box_exist(func): ...@@ -55,7 +55,7 @@ def only_if_box_exist(func):
if vagrant_wd.exists(): if vagrant_wd.exists():
func(*args, **kwargs) func(*args, **kwargs)
else: else:
print("Error: no vm managed by shipwrigth has the hostname '{}'".format(hostname)) print("Error: no vm managed by Shipwright has the hostname '{}'".format(hostname))
exit(1) exit(1)
return wrapper return wrapper
...@@ -120,7 +120,7 @@ def vm_create(hostname, ram, cpus, provider, token): ...@@ -120,7 +120,7 @@ def vm_create(hostname, ram, cpus, provider, token):
print("Creating ssh key required by Vagrant's Digital Ocean plugin ...") print("Creating ssh key required by Vagrant's Digital Ocean plugin ...")
DO_SSH_KEY_PATH.mkdir(parents=True, exist_ok=True) DO_SSH_KEY_PATH.mkdir(parents=True, exist_ok=True)
os.chmod(DO_SSH_KEY_PATH, stat.S_IRWXU) os.chmod(DO_SSH_KEY_PATH, stat.S_IRWXU)
subprocess.run(['ssh-keygen', '-f', 'id_rsa', '-t', 'rsa', '-C', 'Created automatically by shipwrigth', '-N', ''], cwd=DO_SSH_KEY_PATH) subprocess.run(['ssh-keygen', '-f', 'id_rsa', '-t', 'rsa', '-C', 'Created automatically by Shipwright', '-N', ''], cwd=DO_SSH_KEY_PATH)
vagrant_template = open(HERE.joinpath('digital_ocean.tpl'), 'r').read() vagrant_template = open(HERE.joinpath('digital_ocean.tpl'), 'r').read()
with vagrant_wd.joinpath('Vagrantfile').open(mode='w') as vfile: with vagrant_wd.joinpath('Vagrantfile').open(mode='w') as vfile:
...@@ -251,7 +251,7 @@ if __name__ == '__main__': ...@@ -251,7 +251,7 @@ if __name__ == '__main__':
sub_parser.add_argument('hostname', help='This is the hostname for the new the box') sub_parser.add_argument('hostname', help='This is the hostname for the new the box')
sub_parser.add_argument('--ram', help='Hoy much RAM for this box (default is 512MB for libvirt and 1GB for digital ocean.)', default=512) sub_parser.add_argument('--ram', help='Hoy much RAM for this box (default is 512MB for libvirt and 1GB for digital ocean.)', default=512)
sub_parser.add_argument('--cpus', help='Hoy many CPUs for this box (default is 1)', default=1) sub_parser.add_argument('--cpus', help='Hoy many CPUs for this box (default is 1)', default=1)
sub_parser.add_argument('--provider', help='Tells shipwrigth which vagrant provider to use. Default is libvirt', default='libvirt') sub_parser.add_argument('--provider', help='Tells Shipwright which vagrant provider to use. Default is libvirt', default='libvirt')
sub_parser.add_argument('--token', help="This is your personal access token for Digital Ocean's API") sub_parser.add_argument('--token', help="This is your personal access token for Digital Ocean's API")
sub_args = sub_parser.parse_args(sys.argv[2:]) sub_args = sub_parser.parse_args(sys.argv[2:])
if sub_args.provider == 'digital_ocean' and sub_args.token is None: if sub_args.provider == 'digital_ocean' and sub_args.token is None:
......
...@@ -33,5 +33,5 @@ echo "Installing application from PyPI..." ...@@ -33,5 +33,5 @@ echo "Installing application from PyPI..."
# pipx install \ # pipx install \
# example # example
echo "Latest shipwright dependencies installed." echo "Latest Shipwright dependencies installed."
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment