Skip to content

Instantly share code, notes, and snippets.

View JavierMartinz's full-sized avatar

Javier Martínez JavierMartinz

View GitHub Profile
@JavierMartinz
JavierMartinz / 1.scopes.js
Created November 24, 2020 14:01 — forked from marciobarrios/1.scopes.js
Practical frontend interview
(function() {
var a = b = 5;
})();
console.log(b);
// 1. What will be printed on the console?
// 2. Rewrite the code to return the same result but with the variable declarations separated
// 3. Enable strict mode to explicitly reference the scope
@servers([ 'remote' => 'server.example.com'])
@setup
if ( ! isset($repo) )
{
throw new Exception('--repo must be specified');
}
if ( ! isset($base_dir) )
{
server {
listen 80;
server_name sixpack-server.myserver.com;
return 301 https://$host$request_uri;
}
server {
listen 443 ssl;
server_name sixpack-server.myserver.com;
ssl_certificate /etc/nginx/ssl/sixpack-server.myserver.com.chained.crt;
ssl_certificate_key /etc/nginx/ssl/sixpack-server.myserver.com.key;
#!/usr/bin/env bash
echo ">>> Starting Install Script"
# Update
sudo apt-get update
# Install MySQL without prompt
sudo debconf-set-selections <<< 'mysql-server mysql-server/root_password password root'
sudo debconf-set-selections <<< 'mysql-server mysql-server/root_password_again password root'